Networker

Re: [Networker] Can I restore *just* directives?

2008-07-17 12:44:15
Subject: Re: [Networker] Can I restore *just* directives?
From: Will Aymond <Wilbur.Aymond AT SHELL DOT COM>
To: NETWORKER AT LISTSERV.TEMPLE DOT EDU
Date: Thu, 17 Jul 2008 11:26:16 -0500
I'm sure someone's going to hate me for giving away the keys to the kingdom 
with this one.. :-)

Here's an nsradmin trick that will make some of you cry because you haven't 
used it before...

>From an earlier message it appears you still have the old networker server 
>running. Here's what you do:

1. On your old server, create a file with only one line "print type:nsr 
directive;" (without the quotes)
2. nsradmin -i filename > secondfilename
3. Copy this file to the new server.
4. Edit this file (hopefully vi, but any editor will do)
5. Change all occurrences of "type:" to "create type:" (again without the 
quotes) and save the file.
6. nsradmin -i secondfilename
7. Grab your favorite tasty beverage

What's so great about doing it this way as opposed to copying DB files (which 
will probably work too)? It should be completely supported by EMC as this is 
just a function of nsradmin, whereas moving around DB files really shouldn't be 
supported.

This trick also works for transferring hundreds of clients from one server to 
another (I know, I've done this), but may require a little more editing of the 
secondfilename file. (Removing the lines with unique ids). -Just do a practice 
run from within nsradmin to create one and you'll see what fields are required.

Oh yeah, one fair warning... before you go off and decide to never use the GUI 
again, remember "With great power comes great responsibility".. i.e. if you 
screw up, by editing thousands of clients, you have to fix that screw-up. 

Happy Hunting,
 -Will


-----Original Message-----
From: EMC NetWorker discussion [mailto:NETWORKER AT LISTSERV.TEMPLE DOT EDU]On
Behalf Of Howard Martin
Sent: Thursday, July 17, 2008 7:37 AM
To: NETWORKER AT LISTSERV.TEMPLE DOT EDU
Subject: Re: [Networker] Can I restore *just* directives?


you could recover the /nsr/res/nsrdb directories to a temp. location, then 
grep for "NSR directive" in the files this should show all the files that 
contain directives.
If you have no file name clashes you might be able to copy them in to the 
new nsr/res/nsrdb restart Networker and see if it is happy (copy the new 
nsrdb first of course). - Never tried it but it might work.
Otherwise you can use the contentents of the files to paste into the GUI 
or via nsradmin.

On Thu, 17 Jul 2008 08:22:20 -0400, MIchael Leone 
<Michael.Leone AT PHA.PHILA DOT GOV> wrote:

>My NetWorker server somehow becames do incredibly corrupt, that even a
>mmrecov didn't help (I think it's actuallly an OS issue, as my server
>would slow down so much that NW woulld lose connectivity to itself, the
>console would shut down, a couple times it even rebooted. Anyway ....). So
>I have completely rebuilt my NW server, manually adding clients, jobs,
>etc.
>
>I used to have a set of directives, that would ignore certain open files
>(temp files, locks, etc). Unfortunately, during my attempts at fixing, I
>had to mmrecov my old server with an older tape, and they all got written
>over. But I have other bootstrap tapes from before the corruption started,
>that should have the directives on them.
>
>SO my question - how can I retrieve *just* the directives from my old
>bootstrap tape? I don't trust the validity of the mm database (hence my
>clean break, and re-install, and Tech Support concurred), but I really
>don't feel like re-entering all the directives. So is there any way to
>restore just the directives, and re-direct them to a new directory?
>
>Thanks
>
>--
>Michael Leone
>Network Administrator, ISM
>Philadelphia Housing Authority
>2500 Jackson St
>Philadelphia, PA 19145
>Tel:  215-684-4180
>Cell: 215-252-0143
><mailto:michael.leone AT pha.phila DOT gov>
>
>To sign off this list, send email to listserv AT listserv.temple DOT edu and 
type "signoff networker" in the body of the email. Please write to 
networker-request AT listserv.temple DOT edu if you have any problems with this 
list. You can access the archives at 
http://listserv.temple.edu/archives/networker.html or
>via RSS at http://listserv.temple.edu/cgi-bin/wa?RSS&L=NETWORKER

To sign off this list, send email to listserv AT listserv.temple DOT edu and 
type "signoff networker" in the body of the email. Please write to 
networker-request AT listserv.temple DOT edu if you have any problems with this 
list. You can access the archives at 
http://listserv.temple.edu/archives/networker.html or
via RSS at http://listserv.temple.edu/cgi-bin/wa?RSS&L=NETWORKER

To sign off this list, send email to listserv AT listserv.temple DOT edu and 
type "signoff networker" in the body of the email. Please write to 
networker-request AT listserv.temple DOT edu if you have any problems with this 
list. You can access the archives at 
http://listserv.temple.edu/archives/networker.html or
via RSS at http://listserv.temple.edu/cgi-bin/wa?RSS&L=NETWORKER