03-22-2011 04:48 PM
After an incident where a client had been disabled but no one noticed, I need to produce a report through OpsCenter that lists all currently disabled NetBackup clients (v7.x new feature).
I was hoping there would be a canned report already but it doesn't seem so.
Anyone done this already?
Thanks.
03-31-2011 01:32 AM
Hi
Yeah I suggested this back in November:
https://www-secure.symantec.com/connect/idea/opscenter-report-suggestion
This doesn't sound difficult to produce as currenttly its not easy to identify current offline clients.
03-31-2011 03:17 PM
I worked out a very quick and dirty way on my RHEL media server;
It seems a number of files get created/modified under /usr/openv/netbackup/db/client/*/ called OA_*
It appears as if this file is used to flag online and offline clients. If it's OA_0 the client is enabled; if it's OA_unix-time value then it's disabled.
I wrote a very quick and dirty script which I can call from crontab. Seems to work for me; use as you see fit. Of course; completely unsupported.
#!/bin/sh
# E-mail a quick report of Disabled Clients
#
TMPFILE="/tmp/nbu-disabled.tmp"
EMAIL=someonewhocares@domain.whevever
if [ -s $TMPFILE ]
then
/bin/rm -rf $TMPFILE
fi
if [ `find /usr/openv/netbackup/db/client/*/OA_* | grep -vi "OA_0" | tee $TMPFILE | wc -l` -gt 0 ]
then
more $TMPFILE | cut -d/ -f7 | mail $EMAIL -s "NBU Disabled Clients"
fi
exit 0