Networker

[Networker] nsradmin scripting

2009-11-09 19:15:29
Subject: [Networker] nsradmin scripting
From: Jeff Allison <stigger05 AT GMAIL DOT COM>
To: NETWORKER AT LISTSERV.TEMPLE DOT EDU
Date: Tue, 10 Nov 2009 11:13:19 +1100
I'm obviously missing something here...

I have a script to change the backup command

#!/bin/bash
nsradmin -i - <<EOF
. type: NSR client; name: maitprodsql1; group:SQLLogs; save set:
"MSSQL$TESTSQL2005:DR_TEST_DB_Test1"
update backup command: "nsrsqlsv"
EOF

which gives me this output

[root@maitop2 /]# 30mins.sh
Current query set
no resources to update!

And doesn't make the change...

If I run the lines manually

I get this

[root@maitop2 /]# nsradmin
NetWorker administration program.
Use the "help" command for help, "visual" for full-screen mode.
nsradmin> . type: NSR client; name: maitprodsql1; group:SQLLogs; save
set: "MSSQL$TESTSQL2005:DR_TEST_DB_Test1"
Current query set
nsradmin> update backup command: "nsrsqlsv"
              backup command: nsrsqlsv;
Update? y
updated resource id 1.90.7.11.0.0.0.0.0.0.0.0.74.204.18.70.10.150.8.164(258)
nsradmin>

>From what I can see nsradmin requires a confirmation which I cannot
provide in the script, is this a show stopper of have I missed
something...

Regards

Jeff

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

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