Veritas-bu

[Veritas-bu] catalog backups offsite

2002-11-12 06:24:39
Subject: [Veritas-bu] catalog backups offsite
From: Bruno.Bossier AT comparex DOT be (Bruno.Bossier AT comparex DOT be)
Date: Tue, 12 Nov 2002 12:24:39 +0100
Thanks ! This is a Unix version, but I'm sure I can adapt it for Windows.
Give me some time to test it out and I will definitely let you know what
was the outcome.

Cheers,
Bruno





                                                                                
                                   
                    Sheng-Ling                                                  
                                   
                    Coady                To:     Bruno.Bossier AT comparex DOT 
be                                         
                    <coadyho@yahoo       cc:                                    
                                   
                    .com>                Subject:     Re: [Veritas-bu] catalog 
backups offsite                     
                                                                                
                                   
                    11/08/2002                                                  
                                   
                    23:30                                                       
                                   
                                                                                
                                   
                                                                                
                                   




How about the attached file?

Found this on the website.


--- Bruno.Bossier AT comparex DOT be wrote:
>
> Not really. This just explains on how to start a
> catalog backup from the
> command line using the configured method. It does
> not say anything about
> specifying individual tapes.
>
>
>
>
>
>
>
>
>                     Sheng-Ling Coady
>
>
>                     <coadyho AT yahoo DOT com>
>    To:     veritas-bu AT mailman.eng.auburn DOT edu
>
>                     Sent by:
>    cc:
>
>                     veritas-bu-admin AT mailman DOT eng.
>    Subject:     [Veritas-bu] catalog backups offsite
>
>                     auburn.edu
>
>
>
>
>
>
>
>
>                     11/06/2002 23:00
>
>
>
>
>
>
>
>
>
>
>
>
> I wonder if this would help you out a bit
>
>
>
http://seer.support.veritas.com/search_forms/SearchFrame.asp?SearchTerm=how%20to&Path=seer%2esupport%2everitas%2ecom%2fdocs%2f239811%2ehtm

>
>
> __________________________________________________
> Do you Yahoo!?
> HotJobs - Search new jobs daily now
> http://hotjobs.yahoo.com/
> _______________________________________________
> Veritas-bu maillist  -
> Veritas-bu AT mailman.eng.auburn DOT edu
>
http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu
>
>
>
>



__________________________________________________
Do you Yahoo!?
U2 on LAUNCH - Exclusive greatest hits videos
http://launch.yahoo.com/u2#! /bin/ksh

# This script will create a NetBackup database copy onto a specified tape
# Creator of this script is unknown, but the person I received it
# from is Bob Bakh with Veritas Software (that doesn't mean its supported)
# - David Chapa

NB=/usr/openv/netbackup
NB_PATH=$NB/bin
VM_PATH=/usr/openv/volmgr/bin
ADM_PATH=$NB_PATH/admincmd
POOL=NetBackup_Alt
MOUNT_LOC=/tmp/nb_mount
LOG=$NB/user_def/nbdb.log
OPS_RPT=$NB/user_def/ops_report
DATE=`date +%D`

echo "Backing up NetBackup database to tape...."
# Get a list of all tapes in $POOL and filter only those that are in the
robot (TLD)
# From this list find the tape with the least amounts of mounts
MEDIA_ID=`$VM_PATH/vmquery -bx -pn $POOL 2> /dev/null | grep TLD | awk '
BEGIN { MOUNTS=1000000}
{
if ( $9 < MOUNTS )
  { MEDIAID=$1
    MOUNTS=$9
   }
}
END {print MEDIAID} '`

# Mount the tape
$VM_PATH/tpreq -ev $MEDIA_ID -d dlt -p $POOL $MOUNT_LOC
if [ $? -ne 0 ] ; then
  echo "Tape $MEDIA_ID failed to mount, bpbackupdb cancelled on $DATE" >>
$LOG
  echo "Tape failed to mount.  Contact Storage Management." >> $OPS_RPT
  echo "Tape failed to mount.  Contact Storage Management."
  echo "Press Enter to exit"
  read ans
  exit 1
fi

# Create the database backup
$ADM_PATH/bpbackupdb -v -tpath $MOUNT_LOC
STATUS=$?
if [ $STATUS -ne 0 ] ; then
  $VM_PATH/tpunmount $MOUNT_LOC
  echo "bpbackupdb failed with error $STATUS on $DATE" >> $LOG
  echo "NetBackup database backup failed.  Contact Storage Management." >>
$OPS_RPT
  echo "NetBackup database backup failed.  Contact Storage Management."
  echo "Press Enter to exit"
  read ans
  exit 2
fi

# Unmount the tape
$VM_PATH/tpunmount $MOUNT_LOC

# Eject the tape
integer STATUS=1
while [ $STATUS -ne 0 ]
do
sleep 20
$VM_PATH/vmchange -res -m $MEDIA_ID -mt dlt -rt none -rc1 0 -rc2 0 -e 2>
/dev/null
STATUS=$?
if [ $STATUS -eq 221 ] ; then
  while true
  do
    echo "Robot Mail slot is full."
    echo "Please empty the robot CAP and press return when robot CAP is
empty"
    read ans
    $VM_PATH/vmchange -res -m $MEDIA_ID -mt dlt -rt none -rc1 0 -rc2 0 -e
2>
/dev/null
    if [ $? -ne 221 ] ; then
      break
    fi
  done
fi
done

echo "NetBackup database backed up successfully to tape $MEDIA_ID on $DATE"
>> $LOG
echo "NetBackup database backed up successfully to tape $MEDIA_ID on $DATE"
echo "\n *** Media ID $MEDIA_ID has been ejected - send offsite for 1 week
***"
echo "\n *** Media ID $MEDIA_ID has been ejected - send offsite for 1 week
***" >> $OPS_RPT
echo "\n NetBackup database backup ended"
read ans
exit 0






<Prev in Thread] Current Thread [Next in Thread>