This post is more than 5 years old

1 Rookie

 • 

39 Posts

7561

September 25th, 2014 03:00

How to delete networker resources [Storage node]

Hi,

My networker server is connecting with VTL which is a mirror of prod. VTL and i recovered networker configuration + data with disaster recovery procedure.

After completing this procedure,i see duplicate copy of storage node [screenshot attached] which contains the same liberary as first node contains.

Is there any way to delete duplicate storage node?

Any suggestion would be highly appriciated.

Thanks in advance,

Aman

1 Attachment

2.4K Posts

September 25th, 2014 05:00

The issue is that you have managed to keep more than one resource file of the same resource.

NetWorker should not do this by itself but in general, such is possible - I remember that i have run into such issue years ago.

Howe to overcome that? - not so easy as you do not know which resource you want to keep.

The following procedure might help:

  - Run a backup of the current resource directory

  - Search through /nsr/res/nsrdb for files containing the string "type: nsr storage node"

  - Type each file and decide which one you want to rename/delete.

  - Rename the resource file.

  - Restart the NetWorker services

... worst case, you got a copy of the whiole directory where you can recover from.

268 Posts

September 25th, 2014 04:00

Use nsradmin to delete the duplicate storage node.

# nsradmin -d nsrdb

> print type: nsr storage node

> delete

4 Operator

 • 

1.3K Posts

September 25th, 2014 04:00

Iman,

You could delete all the devices that are configured under the storage node in question, once that is done NetWorker will allow you to delete the desired storage node resource.

1 Rookie

 • 

39 Posts

September 25th, 2014 04:00

Hi Prajith,

I tried but it deleted the both node because name is same. is it possible to rename first node and delete 2nd storage node ?

Thanks!!

Aman

2 Intern

 • 

14.3K Posts

September 25th, 2014 04:00

You can also keep it and forget about it.  I'm not sure why you have two resources with same name as that should not be the case, but if one had to go I would remove resources under first and then remove it from DB while NW is offline. However, I would suggest you leave this to support which should see why this happened in the first place which to me is still a mystery from all I have read so far.

1 Rookie

 • 

39 Posts

September 25th, 2014 05:00

Hi Crvelin, thanks for response.

Well, i knew the reason already why i have 2 storage node but at the moment, challenge is to remove one storage node. could you please describe your actions in terms of step by step commands? if you can.

ofcourse , i must admit that it is a mystery because my rebuild/DR procedure is complex and scripted in such a way where i have to check so many things before proceding , moreover i cannot describe whole procedure, therefore i asked exact question about removal of storage node.

Thanks !!

Aman

2 Intern

 • 

14.3K Posts

September 25th, 2014 05:00

OK, so you complicate something

Anyway, if you feel you know what you are doing, do following:

- see which one you wish to remove

- make sure resources under that storage node resource are gone

- stop NW and make copy of /nsr/res (just in case something goes wrong)

- do something like: grep 'type: NSR Storage Node' /nsr/res/nsrdb/*/*

- above will give you list of NSR storage node resources (you should have two) - now you have to figure out which one is wrong

If this is DR and you did copy restored res into res, I can imagine some duplicates may have happened. 

2 Intern

 • 

14.3K Posts

September 25th, 2014 06:00

Device busy is returned by OS itself meaning there was some kind of lock yet.  You can see the lock with lsof or fuser (where later can be used to break all locks as well).

1 Rookie

 • 

39 Posts

September 25th, 2014 06:00

You are right, actually my DR script couldn't remove /nsr/res/* directory [reason : device busy] - any idea how i can remove [rm -rf /nsr/res/* completely?

Finally problem is resolved.

as you said i renamed the resouce file help me to resolve this problem.

before:

/nsr/res/nsrdb/01/510092090000000002df9d4d000000000a2b231b:type: NSR Storage Node;
/nsr/res/nsrdb/01/5b00692700000000248e21540a4fdc34:type: NSR Storage Node;

###############################################

After:

/nsr/res/nsrdb/01/5b00692700000000248e21540a4fdc34:type: NSR Storage Node;
/nsr/res/nsrdb/dbg/510092090000000002df9d4d000000000a2b231b.ori:type: NSR Storage Node;

interesting thing is - after renaming the resource file, application changed the position of renamed resource to dbg directory.

Thanks a lot !!!

Aman

2.4K Posts

September 25th, 2014 09:00

Good point - i forgot that the filename and the resource id are 'somehow' connected.

This is how corrupt resources will be isolated.

No Events found!

Top