Networker

Re: [Networker] Moving Config

2004-07-21 14:18:04
Subject: Re: [Networker] Moving Config
From: "Ungaro, Matt" <mjungaro AT CAPITOLINDEMNITY DOT COM>
To: NETWORKER AT LISTMAIL.TEMPLE DOT EDU
Date: Wed, 21 Jul 2004 13:19:36 -0500
Thanks Darren, that definitely helps. And I hope you got the syntax correct,
also. :)
-----Original Message-----
From: Legato NetWorker discussion
[mailto:NETWORKER AT LISTMAIL.TEMPLE DOT EDU]On Behalf Of Darren Dunham
Sent: Wednesday, July 21, 2004 1:16 PM
To: NETWORKER AT LISTMAIL.TEMPLE DOT EDU
Subject: Re: [Networker] Moving Config


>
> Would you have any PERL/shell script like this handy? I'm in a bit of a
> crunch, and since I'm unaware how to do this myself, it would take an
> extremely long time to write myself. If you don't have anything written
> already, how do I properly query nsradmin for that info, then reinsert it
at
> the other side (On the 6.1.2 server)?

Nope.  Haven't needed it in a while, and it was probably pretty custom.

The basic steps are to ask nsradmin for what you need, munge as
necessary, then create new objects on the other side.

If it's simple enough, and you're not familiar with doing things in
scripts, it might even be easier to just do some of it in an editor.

# cat grab_clients
show name;save set;group;schedule;browse policy;retention policy;directive
print type:nsr client


The above file is just an example.  Your environment might need to
record other attributes (like remote access or parallelism).  Add
anything that wouldn't be default to the 'show' line

# nsradmin -i grab_clients > output

Here you'll have the basic output showing all the clients and their
information.  Now you need to munge that file, minimally adding a
'create' line with the correct "type" above every entry.  For instance
where you have an output like this...

               name: client1;
              group: Default;

               name: otherclient;
              group: operations;

Make it look instead like...

create type: nsr client;
               name: client1;
              group: Default;

create type: nsr client;
               name: otherclient;
              group: operations;

With many editors, it should be trivial to insert that line on top of
all the entries (or to remove one or two entrys, or to do a
search&replace if you're modifying a pool name or something)...

Then run..

# nsradmin -i client_list

That should create them.

I hope I didn't mess up any syntax there...

--
Darren Dunham                                           ddunham AT taos DOT com
Senior Technical Consultant         TAOS            http://www.taos.com/
Got some Dr Pepper?                           San Francisco, CA bay area
         < This line left intentionally blank to confuse you. >

--
Note: To sign off this list, send a "signoff networker" command via email
to listserv AT listmail.temple DOT edu or visit the list's Web site at
http://listmail.temple.edu/archives/networker.html where you can
also view and post messages to the list.
=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=

--
Note: To sign off this list, send a "signoff networker" command via email
to listserv AT listmail.temple DOT edu or visit the list's Web site at
http://listmail.temple.edu/archives/networker.html where you can
also view and post messages to the list.
=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=

<Prev in Thread] Current Thread [Next in Thread>