Video Screencast Help
Symantec to Separate Into Two Focused, Industry-Leading Technology Companies. Learn more.
Backup and Recovery Community Blog

Find Your NBU Client Patch Levels

Created: 23 Sep 2011
AlanTLR's picture
0 0 Votes
Login to vote

        One of the challenges I face as an administrator is coordinating upgrades (especially minor upgrades) to hosts that I don't own.  Somehow, I have to communicate that the NetBackup level isn't up to date.  I can easily find out what level the client is by running a 'bpgetconfig', but I'm all about automation and ownership.  I think that an admin should own his machine and I don't want to micromanage.  So I can create a simple script that I can use as the basis for an automated notification about a hosts' NetBackup level.

        The script below is a quick and dirty one I wrote a long time ago that gathers all the client versions, along with the Operating Systems (as entered into the database).  Using this information, I can apply them against either a database or a flat file that maps the hostname and/or OS type with the owner's email and send a notification.


if [ $# -lt 1 ]; then
  for i in `bppllist -l -allpolicies | grep CLIENT | awk '{print $2}' | sort -u`
    printf "$i: "
    bpgetconfig -s $i -A -L | egrep "Patch|Release" |awk '{printf "%s ",$4,$5}'
    printf "\n"
    printf "$1: "
    bpgetconfig -s $1 -A -L | egrep "Patch|Release" |awk '{printf "%s ",$4,$5}'
    printf "\n"

        As I said before, it's quick and dirty, but it will give output of the servers and their NBU versions that you can use in either a report or just for notifications.  It does take some time, but give it a try.  You may want to look at the output of bpgetconfig and possibly select other columns you may want to display, besides $4 and $5.

        Sample output below:

/usr/local/bin $ sudo ./nbu-os-patch.ksh
host1: Windows2000 6.5
host2: SunOS 6.5.5
host3: Linux 7.1
host4: Linux 7.1
host5: SunOS 6.5.5
host6: cannot connect on socket


Try and enjoy!