BookmarkSubscribeRSS Feed
miguelcalzada
Fluorite | Level 6

Hello there,

 

Some users had disconnection problems caused by network, and some of the metadata objects they were working on got locked, and neither them or the administrator can delete, rename or modify anything about them.

 

They don't let you choose the Delete option from the SAS Management Console, and when you try to rename it, it shows a locked message. You can find proof of both of those things on the attachments for one table that has that problem, and another folder (not in the same route) has this same problem as well.

 

We have tried to repair the Metadata in the Metadata Manager, but it didn't work, and recovering a Metadata backup from some time ago is not an option.

 

Any help will be appreciated.

 

Thank you everyone!

1 REPLY 1
Kalind_Patel
Lapis Lazuli | Level 10

There's an option called OMI_UNLOCK_FORCE in Metadata update procedures, you can use that option to unlock the locked table, here's a sample code,

But, I strongly recommend to take the Metadata Backup first before you execute this SAS Code,

Here's the sample code for SAS 9.4:

options metaserver='YOUR_METADATA_SERVER'
metaport=8561
metaprotocol='bridge'
metauser='sasadm@saspw'
metapass='PASSWORD_FOR_SASADM'
metarepository='Foundation'
;

options ls=max ps=max noquotelenmax ;
proc metadata
in='<GetMetadata>
    	<Metadata>
        <PhysicalTable Id="INSERT_YOUR_PHYSICAL_TABLE's_ID_HERE" />
    	</Metadata>
    		<NS>SAS</NS>
    	<Flags>262144</Flags>
    	<Options>
    	</Options>
    </GetMetadata>' 
verbose;
run;

Make sure you change metaserver, metapass and most importantly "PhysicalTable Id" value in this code,

You can get PhysicalTable's Id from you error message itself:

2020-03-13_20-09-24.png

 

 After running this code, the Table should be unlocked.

 

For your reference: https://documentation.sas.com/?docsetId=omaref&docsetTarget=n0jz5u1b73d8czn1wil2biqcusr5.htm&docsetV...

suga badge.PNGThe SAS Users Group for Administrators (SUGA) is open to all SAS administrators and architects who install, update, manage or maintain a SAS deployment. 

Join SUGA 

Get Started with SAS Information Catalog in SAS Viya

SAS technical trainer Erin Winters shows you how to explore assets, create new data discovery agents, schedule data discovery agents, and much more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 1 reply
  • 904 views
  • 1 like
  • 2 in conversation