changalrai

updated

16 years ago

C

changalrai

1 Rookie

•

100 Posts

0

5025

September 13th, 2010 15:00

Shell script and Perl scripts using nsradmin.

HI All,

To get Networker configuration details we are using shell scripts.

Example:

printf "show name;schedule;group;save set;backup command;comment\n print type:nsr client;name: \n" | /usr/sbin/nsradmin -i- -s

But for same command how to write in Perl script

Please suggest me, its very urgent.

Please advice me what to do.

Thanks in Advance.

  • rovinabi

    55 Posts

    2019

    0

    Posted September 15th, 2010 22:00

    Well here what you can use,

    open (CONFIG, "printf \"show name;schedule;group;save set;backup command;comment\n print type:nsr client;name: \n\" | /usr/sbin/nsradmin -i- -s |")  or die $!;

    While( )

    {

         print $_."\n";

    }

    HTH,

    Rovin D'Souza.

  • coganb

    736 Posts

    2019

    0

    Posted September 14th, 2010 05:00

    Hi,

    This discussion might give you some help - there's a link to a perl script in there.

    https://community.emc.com/message/495433

    It doesn't do what you are looking for but you might be able to learn from it to develop what you need.

    -Bobby

  • changalrai

    1 Rookie

    •

    100 Posts

    2019

    0

    Posted September 14th, 2010 14:00

    Hi all,

    my questions is how to pull Networker configuration information through Perl scripting, if anybody have an example please provide me its great help.

    question: pull the list of networker client list on networker server.

    Thanks in avance.  

  • saleesh1

    128 Posts

    2019

    0

    Posted September 15th, 2010 05:00

    You can call the same query from perl and get the output in a perl variable.

    for eg:

    $clientinfo=`printf "show name;schedule;group;save set;backup command;comment\n print type:nsr client;name: \n" | /usr/sbin/nsradmin -i- -s $server`;

  • yzabary

    18 Posts

    2019

    0

    Posted September 26th, 2010 12:00

      I have been using this great tool written in perl mentioned in http://www.adsm.org/lists/html/Networker/2004-05/msg00145.html.