Script to Start Replica Sybase ASE Database
#!/bin/ksh
#
# script: startdb.sh <list_of_database_volumes>
#
# Sample script to recover and start replica Sybase ASE database.
# Import the snapshot volume disk group.
vxdg import $snapvoldg
# Mount the snapshot volumes (the mount points must already exist).
for i in $*
do
fsck -F vxfs /dev/vx/rdsk/$snapvoldg/snap_$i
mount -F vxfs /dev/vx/dsk/$snapvoldg/snap_$i ${rep_mnt_point}/$i
done
# Start the replica database.
# Specify the -q option if you specified the "for external dump"
# clause when you quiesced the primary database.
# See the Sybase ASE 12.5 documentation for more information.
/sybase/ASE-12_5/bin/dataserver \
[-q] \
-sdatabase_name \
-d /sybevm/master \
-e /sybase/ASE-12_5/install/dbasename.log \
-M /sybase
# Online the database. Load the transaction log dump and
# specify "for standby_access" if you used the -q option
# with the dataserver command.
isql -Usa -Ppassword -SFMR <<!
[load transaction from dump_device with standby_access
go]
online database database_name [for standby_access]
go
quit
!
|