Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

script for client version and patch level (bpgetconfig)

Status
Not open for further replies.

backupgrl

MIS
May 5, 2005
4
CA
Trying to create a script to find out client version and patch level. Problem is when it runs it keeps prompting for "press any key to continue..." How do I get it to just keep going?

Here's the script:
#!/user/bin/ksh
bpplclients.exe -allunique -l|awk '{print $2}' > /tmp/clients.txt
while read line
do
bpgetconfig.exe -M $line VERSIONINFO CLIENT_NAME >> /tmp/version.txt

done < /tmp/clients.txt

Here's the output from ksh -x:
+ bpplclients.exe -allunique -l
+ awk {print $2}
+ > /tmp/clients.txt
+ < /tmp/clients.txt
+ read line
+ bpgetconfig.exe -M TSW40020 VERSIONINFO CLIENT_NAME
+ >> /tmp/version.txt
Press any key to exit . . .
 

for i in `bpplclients -allunique -noheader | awk '{print $3}'`
do
echo $i, `bpgetconfig -s $i -l | awk -F";" '{print $8,","$5}'` >>verlist.txt
done

# Output of bpgetconfig -s
# 1 = Client/Master
# 2 = NetBackup Client Platform
# 3 = NetBackup Client Protocol Level
# 4 = Product
# 5 = Version Name
# 6 = Version Number
# 7 = NetBackup Installation Path
# 8 = Client OS/Release


snip from outfile
_____

eros001, WindowsNET 5 ,5.0GA
fauquier-bkup,
faxhost2, Windows2000 5 ,5.0GA
floyd-bkup, SunOS 5.10 ,5.0GA
glaive01, WindowsXP 5 ,4.5GA
glaive02,
goviq, Windows2000 5 ,4.5GA
hanover-bkup, SunOS 5.8 ,5.0GA
hms-ex1, WindowsNET 5 ,5.0GA
loghost, ,3.4GA
hms-ex2, WindowsNET 5 ,5.0GA
_____

end snip

 
Thanks for the suggestion. But I am still being prompted for "press any key to exit" this happens after each client. I would like to automate this as we have 300+ clients.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top