03-26-2009 09:56 AM
03-26-2009 06:38 PM
03-27-2009 04:07 PM
This can be done easily. On the SITE_B, you can configure a break-off style
mirror (snapshot) and do a DG split to do offhost processing on host_b. You can trigger the snapshot on the secondary using vradmin. If you have DB, then have DB be quiesce when you call the IBC, so you would have a snapshot that is application consistent.
Here are some high level command that would help (Please note: these are just
high level commands, you may need other commands. Just thought I would give you commands, so you can try this out in your test configuration):
1. On the secondary, have a two break-off style snapshot configured.
# vxprint -g testdg -ht |grep -i snapdone
pl ss_vol1-04 vol1 ENABLED SNAPDONE 543415808 CONCAT - WO
pl ss_archvol-05 archvol ENABLED SNAPDONE 41943040 CONCAT - WO
2. Setup the env to take snapshot on secondary. This requires setting up onfreeze IBC script and executing the vradmin command.
# cat onfreeze
#----------------Begin of onfreeze -----------------
[. . .]
vxsnap -g testdg make source=vol1/newvol=snap_vol1/plex=ss_vol1-04
if [ $? -eq 0 ]
then
echo "INFO: Snapshot of vol1 created successfully."
else
echo "ERROR: Failed to create snapshot."
exit 1
fi
vxsnap -g testdg make source=archvol/newvol=snap_archvol/plex=ss_archvol-05
if [ $? -eq 0 ]
then
echo "INFO: Snapshot of archvol created successfully."
exit 0
else
echo "ERROR: Failed to create snapshot."
exit 1
fi
#--------------------End of onfreeze ---------------------
3. Trigger the snapshot creation on the seconday using the vradmin command.
#vradmin -g testdg ibc rvg1 testdg
4. Now the snapshot is taken, split the DG on host_a, import the DG on SITE_B_host_b and start the volumes; do an fsck of the file systems and start the database.
# vxdg split testdg testdg_snap snap_archvol snap_vol1
# vxdg deport testdg_snap
#
## on host_b; import the DG
# vxdg import testdg_snap.
# vxvol -g testdg_snap startall
# fsck -V vxfs /dev/vx/dsk/testdg_snap/snap_vol1
# fsck -V vxfs /dev/vx/dsk/testdg_snap/snap_archvol
## Now the snapshot or DG is available on the secondary, you can start the DB or the application.
5. To reattach or resync back to the original volume. unmount the volumes, deport the DG and import the DG on SITE_B_host_a and join the DG back. once join, you can resync/reattach the snapshots.
#
## umount all the volumes on SITE_B_host_b
## deport the DG using "vxdg deport testdg_snap"
## on SITE_B_host_a, import the dg using "vxdg import testdg_snap"
## join the DG back using:
# vxdg join testdg_snap testdg
# vxvol -g testdg startall
## Reattach/refresh the snapshots.
##
# vxsnap -g testdg reattach snap_archvol source=archvol
# vxsnap -g testdg reattach snap_vol1 source=vol1
You can repeast the steps 3 thru 5 again and again on a needed basis.
Hope this help ...
03-27-2009 10:14 PM
03-30-2009 06:59 AM