1834315 Members
2070 Online
110066 Solutions
New Discussion

Re: fbackup script

 
Anitha_3
Frequent Advisor

fbackup script

hi,

how to take full backup of my box (everythig), i have to backup all (vg00, vg01 etc) using fbackup.

kindly help me in getting this..

thanks & best regards,
Govind
8 REPLIES 8
Fred Ruffet
Honored Contributor

Re: fbackup script

basically, it should look like :
fbackup -f /dev/rmt/0m -i /

Note that you will need a big tape, and that some files (like sockets) may provide warning and may not be necessarly needed.

Regards,

Fred
--

"Reality is just a point of view." (P. K. D.)
BONNAFOUS Jean Marc
Trusted Contributor

Re: fbackup script

Hi,

fbackup -f /dev/rmt/0m -i /

(/dev/rmt/0m is tape device file)

See man page for others options like -I for generate a index, or incremental backup.

Be sure that users aren't connected because fbackup save only closed files.

Rgds
JMB
Si vous ne faites jamais de bétises, c'est que vous ne faites rien de difficile. Et ça c'est une grosse bétise.
Darren Prior
Honored Contributor

Re: fbackup script

Hi Govind,

Although it is possible to take a complete system backup with fbackup, it may not be the best solution. fbackup will allow you to recover all or selected files, but you will need a working system to recover to. For situations where you don't have a working system, an Ignite backup is better.

Many people use a combination of Ignite and fbackup - it's worth spending some time searching the forums to find more info on this.

regards,

Darren.
Calm down. It's only ones and zeros...
I.Delic
Super Advisor

Re: fbackup script

hi govind,

I had a same question for the forum. I got very interesting answers from the guy's.
http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=626720


maybe it helps

a specially the script from BILL is an great solution for your backup


Idriz
Bill Hassell
Honored Contributor

Re: fbackup script

You need to download the latest version of Ignite/UX so you can create a vg00 bootable tape in case the root disk fails. You also need to run fbackup and specify all the mountpoints in your backup. Save your make_tape_recovery (Ignite/UX) tapes for a disaster and run fbackup at least weekly, perhaps daily. AS mentioned, fbackup cannot be used if your system can't be booted but the most common use for backups is to restore a few files.


Bill Hassell, sysadmin
Sยภเl Kย๓คг
Respected Contributor

Re: fbackup script


It is advised to use igniteux backup only.You can use -x option with make_tape_recovery to backup the cg otherthan root vg.Better don't go for fabackup
regards
SK
Your imagination is the preview of your life's coming attractions
Govinda
Advisor

Re: fbackup script

guys, thanks for the inputs. but i cant take ignite backup since the server doesnt have dlt connected to it directly so i want to take the backup on remote tape using fbackup.

thanks
Govind
Huib Freeke
Occasional Advisor

Re: fbackup script

here is a example script,



System backup nr. 1 using fbackup

# Backup filesystems en restore test single file
#
#
# Variable
LOG=/home/LOGS/DUMPLOG
day=`date +%a`
TAPE1=/dev/rmt/0m
LOGDIR=/backup/fbackup/log
EXEDIR=/backup/fbackup/bin
LOG2=$LOGDIR/rec.log
TMPREPORT=/tmp/report
REPORT1=$LOGDIR/fbackupreport1
ERROR1=$LOGDIR/fbackuplog1
GRAPH1=$LOGDIR/fbackupgraph1
CONFIGFILE1=$LOGDIR/fbackup_config1
WORKPATH=/opt/ignite/bin
DBUSEFILE=/tmp/dbusefile
LASTFILE=/etc/LASTFILE
#
# Cleanup old files
#
> $LOGDIR/fbackuplog1
> $LOGDIR/fbackupreport1
> $DBUSEFILE
touch $CONFIGFILE1
#
# ######################## Create everyday a graphfile ########################
#
> $GRAPH1
date +%d%m%y > $LASTFILE
echo "i /etc " >> $GRAPH1 # Included
echo "i /bin " >> $GRAPH1 # Included
echo "i /sbin " >> $GRAPH1 # Included
echo "e /var/spool/sockets/pwgr/ " >> $GRAPH1 # Excluded
echo "e /var/spool/cron" >> $GRAPH1 # Excluded
echo "e /var/opt/samba/log.smbd" >> $GRAPH1 # Excluded
echo "e /var/opt/dce/rpc/local/01288 " >> $GRAPH1 # Excluded

bdf|grep -v /dev/vg00/lvol3|grep -v Filesystem|grep -v gelder|grep -v cdrom|awk '{print "i "$NF }'|sort -u >> $GRAPH1
#
#
echo `date '+%a %h %d %T'` "Dump1 starts " >> $LOG

mt -f $TAPE1 rew > /dev/null 2>&1
X=$?
if test $X -eq 0
then
BKSTS=OKE
else
BKSTS=FAILED
fi

case $BKSTS in
OKE)
fbackup -c $CONFIGFILE1 -f $TAPE1 -u0g $GRAPH1 -I $REPORT1 2> $ERROR1
BKRSLT=$?
case $BKRSLT in
0)
rm -f $LASTFILE
recgraph=$LOGDIR/restoregraph
recvlog=$LOGDIR/recovery.log
recerr=$LOGDIR/recovery.err
echo "i /etc/LASTFILE" > $recgraph
sleep 60
frecover -vxo -g $recgraph -f $TAPE1 > $recvlog 2> $recerr
sleep 60
ls -l $LASTFILE > /dev/null
Y=$?
if test $Y -eq 0
then
echo `date '+%a %h %d %T'`" Dump1 finished " >> $LOG
else
echo `date '+%a %h %d %T'`" Dump1 Restore_test_Failed " >> $LOG
fi
;;
1)echo `date '+%a %h %d %T'`" Dump1 Failed_backup " >> $LOG;;
2)echo `date '+%a %h %d %T'`" Dump1 Failed_backup " >> $LOG;;
3)echo `date '+%a %h %d %T'`" Dump1 Check_backup " >> $LOG;;
4)echo `date '+%a %h %d %T'`" Dump1 Check_backup " >> $LOG;;
esac
;;
FAILED)
echo `date '+%a %h %d %T'`" Dump1 FAILED " >> $LOG;;
esac

#
#
#
#
#
chmod 777 $REPORT1
chmod 777 $ERROR1