Re: [Veritas-bu] Images On Media

2009-11-25 Thread A Darren Dunham
On Mon, Nov 23, 2009 at 07:00:03PM -0600, Ed Wilts wrote:
> There are ways to preview the restore to tell you which tapes are needed but
> why bother with a preview - you either need the restore or you don't.

I would like it on occasion because I might have a bin already recalled,
and the file I need could be on several sets of backups, one of which is
already on site.  I'd like to ask the question "do the files I need
exist in the set of tapes I have?"  This happens rarely enough that I
just try to guestimate based on dates and poking around with
bpimagelist.  But with an easy way to get the set of needed tapes out of
a CLI preview, I'd probably script it.

-- 
Darren
___
Veritas-bu maillist  -  Veritas-bu@mailman.eng.auburn.edu
http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu


Re: [Veritas-bu] Images On Media

2009-11-24 Thread Larry Fahnoe
Will,

One way to answer your question is with "bpimagelist -media"; read the man
page for an explanation of the options.  If you provide the appropriate
qualifiers (client, dates, etc.) to focus the search, you find what media
would potentially be needed for the restore.  Ed's advice is better in that
kicking off the restore is likely to require fewer tapes as the restore may
specify down to files while bpimagelist doesn't allow that.

Ed omits a few of the details on the mechanics of watching for jobs needing
media, suspending and alerting.  The attached script shows a means of doing
that.  It should be seasoned to taste and then called from cron on 5 minute
intervals.

--Larry

On Mon, Nov 23, 2009 at 7:00 PM, Ed Wilts  wrote:

> On Mon, Nov 23, 2009 at 4:43 PM, Will Tucker  wrote:
>
>>
>> I'm curious as to what everyone is using for the "Images on Media"
>> process?  If you need to do a restore outside of the "tape reports" window,
>> how do you determine which tapes are requested from Iron Mountain or
>> whatever off-site provider you use to perform the restores?
>>
>
> Our standard way is to kick off a restore, let it determine which tapes are
> needed, suspend the restore, call back tapes, and then resume the restore.
> This usually works well but you have to be careful if there any images on
> DSSUs that could get deleted between the initial restore and when it's
> resumed.
>
> There are ways to preview the restore to tell you which tapes are needed
> but why bother with a preview - you either need the restore or you don't.
>
> .../Ed
>
> Ed Wilts, RHCE, BCFP, BCSD, SCSP, SCSE
> ewi...@ewilts.org
>
>
> ___
> Veritas-bu maillist  -  Veritas-bu@mailman.eng.auburn.edu
> http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu
>
>


-- 
Larry Fahnoe, Fahnoe Technology Consulting, fah...@fahnoetech.com
952/925-0744  Minneapolis, Minnesota   www.FahnoeTech.com
#!/usr/bin/sh

PATH=$PATH:/usr/local/bin:/usr/openv/netbackup/bin/admincmd:/usr/openv/volmgr/bin
addr=someone.who.ca...@yourcompany.com
TEMP1=/var/tmp/check-pending-1.$$
TEMP2=/var/tmp/check-pending-2.$$
TEMP3=/var/tmp/check-pending-3.$$
TRYLOGS=/usr/openv/netbackup/db/jobs/trylogs

cleanup() {
[ -f $TEMP1 ] && rm -f $TEMP1
[ -f $TEMP2 ] && rm -f $TEMP2
[ -f $TEMP3 ] && rm -f $TEMP3
}

trap cleanup TERM EXIT

# Get current time, figure out hi and low minutes to test against
# (assumes this is run on 5 minute intervals)
H=`date +'%H'`
M=`date +'%M'`
if [ $M -eq 0 ]
then
M=60
H=`expr $H - 1`
[ $H -eq -1 ] && H=23
fi
lo=`expr $M - 6`
hi=`expr $M + 1`

# Check for pending tape requests
vmoprcmd -dp pr > $TEMP1

# PENDING REQUESTS
#
#ReqId  UserRecMID  ExtMID  Density  ModeTime   Barcode   VolGroup
#383399 003591  hcartRead13:27  003591
OFFSITE_LTO

# For each request, extract the time and barcode, then see if it
# happened within the last window.  Then check the active or suspended
# restore jobs to see what media is required.  If there are tapes that
# are off-site, report which vault they live in along with any other
# tapes required for the restore jobs.

perl -ne 'if (m|(\d+:\d+\s+\d+)|) {print "$1\n";}' $TEMP1 | while read time 
media
do
  h=`echo $time | awk -F: '{ print $1 }'`
  m=`echo $time | awk -F: '{ print $2 }'`
  if [ $m -eq 0 ]
  then
  m=60
  h=`expr $h - 1`
  [ $h -eq -1 ] && h=23
  fi
  if [ $h -eq $H ]
  then
if [ $m -gt $lo -a $m -lt $hi ]
then
  echo "Current restore jobs:" > $TEMP2
  bpdbjobs | egrep -i 'restore.*(active|suspended)' | tee -a $TEMP2 | awk 
'{print $1}' | while read jobID
  do
awk '/MEDIA_ID_NEEDED/ {print $NF, '$jobID'}' $TRYLOGS/${jobID}.t
  done | sort | uniq > $TEMP1

  echo "" >> $TEMP2
  echo "Tapes needed for restores:" >> $TEMP2
  cat $TEMP1 | while read media jobID
  do
if vmquery -m $media | grep -i 'robot type:.*none' > /dev/null 2>&1
then
touch $TEMP3
vault=`vmquery -m $media | grep -i 'vault name:' | awk '{print 
$NF}'`
echo $media \(job $jobID\) is off-site at $vault >> $TEMP2
echo Suspending job $jobID >> $TEMP2
bpdbjobs -suspend $jobID
else
echo $media \(job $jobID\) >> $TEMP2
fi
  done

  if [ -f $TEMP3 ]
  then
mailx -r $ADDR -s "NetBackup vault tapes needed" $ADDR < $TEMP2
  fi
fi
  fi
done
___
Veritas-bu maillist  -  Veritas-bu@mailman.eng.auburn.edu
http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu


Re: [Veritas-bu] Images On Media

2009-11-24 Thread Ed Wilts
On Mon, Nov 23, 2009 at 4:43 PM, Will Tucker  wrote:

>
> I'm curious as to what everyone is using for the "Images on Media" process?
>  If you need to do a restore outside of the "tape reports" window, how do
> you determine which tapes are requested from Iron Mountain or whatever
> off-site provider you use to perform the restores?
>

Our standard way is to kick off a restore, let it determine which tapes are
needed, suspend the restore, call back tapes, and then resume the restore.
This usually works well but you have to be careful if there any images on
DSSUs that could get deleted between the initial restore and when it's
resumed.

There are ways to preview the restore to tell you which tapes are needed but
why bother with a preview - you either need the restore or you don't.

.../Ed

Ed Wilts, RHCE, BCFP, BCSD, SCSP, SCSE
ewi...@ewilts.org
___
Veritas-bu maillist  -  Veritas-bu@mailman.eng.auburn.edu
http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu


Re: [Veritas-bu] Images On Media

2009-11-23 Thread judy_hinchcliffe
Not clear on what you are stating.

"tape report" like in vault?

And what do you mean bye the images on media PROCESS?  
 
Not clear on how you are doing it.

My tapes are sent off by date,  if I need to do a restore I call back
the tapes for that date ( after I verify in the BAR that the file(s)
exists on tapes for that date) ( and I did a preview to know what tape
numbers I would need), I just call them back and do the restore.

-Original Message-
From: veritas-bu-boun...@mailman.eng.auburn.edu
[mailto:veritas-bu-boun...@mailman.eng.auburn.edu] On Behalf Of Will
Tucker
Sent: Monday, November 23, 2009 4:43 PM
To: veritas-bu@mailman.eng.auburn.edu
Subject: [Veritas-bu] Images On Media

Good afternoon everyone.

I'm curious as to what everyone is using for the "Images on Media"
process?  If you need to do a restore outside of the "tape reports"
window, how do you determine which tapes are requested from Iron
Mountain or whatever off-site provider you use to perform the restores?




Will Tucker | Storage Administrator
Enterprise Technology Services
Manhattan Associates, Inc.
Direct +1 678.597.6644
Mobile +1 770.590.5404
wtuc...@manh.com
http://www.manh.com/ 
_ 
The Supply Chain People(tm)
Manhattan Associates

___
Veritas-bu maillist  -  Veritas-bu@mailman.eng.auburn.edu
http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu


___
Veritas-bu maillist  -  Veritas-bu@mailman.eng.auburn.edu
http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu


RE: [Veritas-bu] Images on media question

2006-01-31 Thread WEAVER, Simon
Title: Message



Jim
Think 
you are right, believe it still stays in the volume pool it was assigned to 
:-)
 
 
Simon 
WeaverTechnical SupportWindows Domain Administrator 
EADS 
AstriumTel: 02392-708598 
Email: 
[EMAIL PROTECTED] 

  
  -Original Message-From: Jim Peppas 
  [mailto:[EMAIL PROTECTED] Sent: 31 January 2006 08:39To: 
  [EMAIL PROTECTED]; [EMAIL PROTECTED]; 
  veritas-bu@mailman.eng.auburn.eduSubject: RE: [Veritas-bu] Images 
  on media question
  Hi.
   
  Failed backups do not occupy VAILD space on tapes. When a 
  new backup runs and appends to a tape which was used with a failed backup, 
  Netbackup will position the tape to the end of the last VALID image on the 
  tape, thus overwriting the invalid image. 
   
  If the tape was blank (in the scratch pool) , it 
  will be placed in the policie's volume pool, but after the backup has failed, 
  the "Date Assigned" value of the tape will be blank. I don't recall if the 
  tape will return to the scratchpool, but I don't think so.
   
  Regards,
  Jim
  
  
  From: [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED] On Behalf Of 
  [EMAIL PROTECTED]Sent: Tuesday, January 31, 2006 12:14 
  AMTo: [EMAIL PROTECTED]; 
  veritas-bu@mailman.eng.auburn.eduSubject: RE: [Veritas-bu] Images 
  on media question
  
  Anything other than an error code 0 or 1 is a failed backup; failed 
  backups do not create any valid images.  The attempt, though, may still 
  occupy tape space until any other successful images on that tape are expired 
  & the entire tape is reusable.
   
  There may be a delay in the time when a tape's images are expired and 
  the tape becomes reusable.
   
  Look 
  at the "bpexpdate -deassignempty" command to speed the process.  It also 
  accepts a mediaid if you want to limit its effect.  The command is safe, 
  not deleting any valid images.  It's just a cleanup 
  command.
   
  -M
  
-Original Message-From: 
[EMAIL PROTECTED] 
[mailto:[EMAIL PROTECTED]On Behalf Of Tim 
MartinoSent: Monday, January 30, 2006 1:29 PMTo: 
veritas-bu@mailman.eng.auburn.eduSubject: [Veritas-bu] Images on 
media question

Running NetBackup 4.5 
FP3.
 
A weekend Fullback loaded 4 
different tapes according to the Activity Monitor.  The backup failed 
due to no available media.  Running the Images on Media Report for 
these tapes, I see no images for the failed backup.  

 
1.  I am not sure if the 
GUI is the best determinant of this.
 
2.  Since the backup 
failed, does that mean the images that were backed up are no longer on the 
media?
 
Thanks in 
advance.
 
-Tim 
Martino

This email is for the intended addressee only.
If you have received it in error then you must not use, retain, disseminate or otherwise deal with it.
Please notify the sender by return email.
The views of the author may not necessarily constitute the views of EADS Astrium Limited.
Nothing in this email shall bind EADS Astrium Limited in any contract or obligation.

EADS Astrium Limited, Registered in England and Wales No. 2449259
Registered Office: Gunnels Wood Road, Stevenage, Hertfordshire, SG1 2AS, England


RE: [Veritas-bu] Images on media question

2006-01-31 Thread Jim Peppas



Hi.
 
Failed backups do not occupy VAILD space on tapes. When a 
new backup runs and appends to a tape which was used with a failed backup, 
Netbackup will position the tape to the end of the last VALID image on the tape, 
thus overwriting the invalid image. 
 
If the tape was blank (in the scratch pool) , it will 
be placed in the policie's volume pool, but after the backup has failed, the 
"Date Assigned" value of the tape will be blank. I don't recall if the tape will 
return to the scratchpool, but I don't think so.
 
Regards,
Jim


From: [EMAIL PROTECTED] 
[mailto:[EMAIL PROTECTED] On Behalf Of 
[EMAIL PROTECTED]Sent: Tuesday, January 31, 2006 12:14 
AMTo: [EMAIL PROTECTED]; 
veritas-bu@mailman.eng.auburn.eduSubject: RE: [Veritas-bu] Images on 
media question

Anything other than an error code 0 or 1 is a failed backup; failed 
backups do not create any valid images.  The attempt, though, may still 
occupy tape space until any other successful images on that tape are expired 
& the entire tape is reusable.
 
There 
may be a delay in the time when a tape's images are expired and the tape becomes 
reusable.
 
Look 
at the "bpexpdate -deassignempty" command to speed the process.  It also 
accepts a mediaid if you want to limit its effect.  The command is safe, 
not deleting any valid images.  It's just a cleanup 
command.
 
-M

  -Original Message-From: 
  [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED]On Behalf Of Tim 
  MartinoSent: Monday, January 30, 2006 1:29 PMTo: 
  veritas-bu@mailman.eng.auburn.eduSubject: [Veritas-bu] Images on 
  media question
  
  Running NetBackup 4.5 
  FP3.
   
  A weekend Fullback loaded 4 
  different tapes according to the Activity Monitor.  The backup failed due 
  to no available media.  Running the Images on Media Report for these 
  tapes, I see no images for the failed backup.  
  
   
  1.  I am not sure if the GUI 
  is the best determinant of this.
   
  2.  Since the backup failed, 
  does that mean the images that were backed up are no longer on the 
  media?
   
  Thanks in 
  advance.
   
  -Tim 
  Martino


RE: [Veritas-bu] Images on media question

2006-01-31 Thread WEAVER, Simon
Title: Message



Hi 
Tim
Yes 
that is my understanding. If the backup shows a "BOMB" icon or a red circle with 
a white cross, it usually means that this is an invalid backup, and I believe 
that netbackup will not contain any data or images for this backup 
job.
 
Thanks
Simon 
WeaverTechnical SupportWindows Domain Administrator 
EADS 
AstriumTel: 02392-708598 
Email: 
[EMAIL PROTECTED] 

  
  -Original Message-From: Tim Martino 
  [mailto:[EMAIL PROTECTED] Sent: 30 January 2006 
  20:29To: veritas-bu@mailman.eng.auburn.eduSubject: 
  [Veritas-bu] Images on media question
  
  Running NetBackup 4.5 
  FP3.
   
  A weekend Fullback loaded 4 
  different tapes according to the Activity Monitor.  The backup failed due 
  to no available media.  Running the Images on Media Report for these 
  tapes, I see no images for the failed backup.  
  
   
  1.  I am not sure if the GUI 
  is the best determinant of this.
   
  2.  Since the backup failed, 
  does that mean the images that were backed up are no longer on the 
  media?
   
  Thanks in 
  advance.
   
  -Tim 
  Martino

This email is for the intended addressee only.
If you have received it in error then you must not use, retain, disseminate or otherwise deal with it.
Please notify the sender by return email.
The views of the author may not necessarily constitute the views of EADS Astrium Limited.
Nothing in this email shall bind EADS Astrium Limited in any contract or obligation.

EADS Astrium Limited, Registered in England and Wales No. 2449259
Registered Office: Gunnels Wood Road, Stevenage, Hertfordshire, SG1 2AS, England


RE: [Veritas-bu] Images on media question

2006-01-30 Thread Mark . Donaldson



Anything other than an error code 0 or 1 is a failed backup; failed 
backups do not create any valid images.  The attempt, though, may still 
occupy tape space until any other successful images on that tape are expired 
& the entire tape is reusable.
 
There 
may be a delay in the time when a tape's images are expired and the tape becomes 
reusable.
 
Look 
at the "bpexpdate -deassignempty" command to speed the process.  It also 
accepts a mediaid if you want to limit its effect.  The command is safe, 
not deleting any valid images.  It's just a cleanup 
command.
 
-M

  -Original Message-From: 
  [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED]On Behalf Of Tim 
  MartinoSent: Monday, January 30, 2006 1:29 PMTo: 
  veritas-bu@mailman.eng.auburn.eduSubject: [Veritas-bu] Images on 
  media question
  
  Running NetBackup 4.5 
  FP3.
   
  A weekend Fullback loaded 4 
  different tapes according to the Activity Monitor.  The backup failed due 
  to no available media.  Running the Images on Media Report for these 
  tapes, I see no images for the failed backup.  
  
   
  1.  I am not sure if the GUI 
  is the best determinant of this.
   
  2.  Since the backup failed, 
  does that mean the images that were backed up are no longer on the 
  media?
   
  Thanks in 
  advance.
   
  -Tim 
  Martino