The file replication job direction can be changed when both the source and the target systems are under VCS control, in two separate VCS clusters.
To change the replication direction when the VFR job is managed by VCS
# hares -offline job_name -sys system_name
where job_name is the name of the replication job you want to offline, and system_name is the name of the system on which the replication job is running.
# haconf -makerw
# hares -modify job_name Enabled 0
# haconf -dump -makero
# vfradmin job get ckpt job_name mntpt
where job_name is the name of the replication job for which you want to display the Storage Checkpoint, and mntpt is the mount point of the target system.
# hares -offline vcs_mntpt -sys system_name
where vcs_mntpt is the VCS mount point resource name and system_name is the name of the system on which the replication job was running.
For CFS mount points, execute the following command on the source node:
# cfsumount mntpt
Verify that the VCS resource is offlined before proceeding.
Type the following command to wait for the resource to go offline after issuing the offline command:
# hares -wait vcs_mntpt State OFFLINE -system_name
# /opt/VRTS/bin/fsckpt_restore device_file checkpoint_name
where device_file is the full path to the VxVM volume used by the file system. For example, /dev/vx/dsk/replicatedg/src_volume
.
For example:
# /opt/VRTS/bin/fsckpt_restore /dev/vx/dsk/replicatedg/src_volume vxfsrepl_ckpt_877167997_12Sep11_14_59
# hares -online vcs_mntpt -sys system_name
For CFS mount points, execute the following command on all nodes that were previously offlined:
# cfsmount mntpt
# /opt/VRTS/bin/fsckptadm rename checkpoint_name new_checkpoint_name src_mntpt
For example:
# /opt/VRTS/bin/fsckptadm rename vxfsrepl_ckpt_877167997_12Sep11_14_59 filesystem_root /src_mntpt
For more information, see the fsckpt_restore (1M) and fsckptadm (1M) manual pages.
# /opt/VRTS/bin/fsckptadm create checkpoint_name src_mntpt
For more information, see thefsckptadm (1M) manual page.
# vfradmin job set mode -s job_name tgt_mntpt
where job_name is the name of the replication job you want to modify and tgt_mntpt is the mount point on the old target system.
This command prepares the old target system to become the new source system for the replication job. The command swaps the source and the target file system names and swaps the source and the target IP addresses.
# vfradmin job set mode -t job_name src_mntpt
where job_name is the name of the replication job you want to modify and src_mntpt is the mount point on the old source system from where the file system was being replicated.
This command prepares the old source system to become the new target system for the replication job. The command swaps the source and the target file system names and swaps the source and the target IP addresses.
# haconf -makerw
# hares -modify job_name Enabled 1
# haconf -dump -makero
# hares -probe job_name -sys src_mntpt
# hares -online job_name -sys src_mntpt