Veritas-bu

[Veritas-bu] vmupdate + scripting?

2002-09-23 14:22:24
Subject: [Veritas-bu] vmupdate + scripting?
From: CBallowe AT usg DOT com (Ballowe, Charles)
Date: Mon, 23 Sep 2002 13:22:24 -0500
we have some scripts in cron that kick off jobs and ran into a problem 
with one of them this weekend.

at the beginning of the script, it runs 
"vmupdate -rn 0 -rt tld -mt dlt2 -use_barcode_rules" to update the robot
inventory. This weekend the vmupdate ran but output:

Update failed: could not add new media ID 'DNU904' into slot 3
Insert media failed:
media ID not unique in database (34)

at the end of it's output. I've seen similar things before, when doing some
things manually, and re-running vmupdate has always fixed it. The problem is
when this happens the available media list becomes quite empty and all the
jobs that try to run fail.

I'd like to put some logic in my script to check for this, but I can't
re-create
the problem reliably enough to test things. Can anybody tell me if vmupdate
will
set a return code that I can test for, or if the error that it put there is
on
stdout or stderr such that I could grep for it or something? Other
suggestions?
'vmquery -w -rn 0 | wc -l' maybe? Unfortunatly, I have no clue what state
things
were in, because the next cron job that did a vmupdate fixed things and I
didn't
notice my pager vibrating in another room until it was too late to
investigate.

Charles Ballowe                                /"\
Unix System Administrator                      \ /     ASCII Ribbon Campaign
cballowe AT usg DOT com                                X      Against HTML Mail
x3896                                          / \


<Prev in Thread] Current Thread [Next in Thread>
  • [Veritas-bu] vmupdate + scripting?, Ballowe, Charles <=