#/bin/ksh # Script : /u01n/oracle/offline_backup.sh # Purpose : Script to run an off-line bkup on Secondary[prosp2] server # Outputs : email or sms # Author: : ######################################################################### # # # Resync & Split the BC Volume Groups # # # ######################################################################### CURRENT_DATE=`date +"%Y%m%d_%H:%M"` BACKUP_LOG_DIR=/u01/oracle/scripts/bkup_logs RESYNC_LOG="$BACKUP_LOG_DIR/resync_${CURRENT_DATE}.log" SPLIT_LOG="$BACKUP_LOG_DIR/split_${CURRENT_DATE}.log" PAIR_VG="vgdb_bc1 vgarchive_bc1 vgapp_bc1" mess3="BC VG is in inconsistent state...... BACKUP WILL EXIT....!!" cd /opt/HORCM/scripts . ./set_env1 ./sync_all >> $RESYNC_LOG for BCVG in $PAIR_VG do pairevtwait -g $BCVG -nowait RT=$? if [[ "${RT}" = "3" ]] then print "BC VG is in paired state " else /usr/bin/echo 27832122462 27832122462 $mess3 | /usr/bin/telnet 10.0.67.182 5000 exit ${RT} fi done if [[ "${RT}" = "3" ]] then echo This scripts works cd /opt/HORCM/scripts . ./set_env1 >> $SPLIT_LOG ./split_all >> $SPLIT_LOG fi