< Previous | Next > | |
Product: Volume Replicator Guides | |
Manual: Volume Replicator 4.1 Administrator's Guide |
Synchronizing the Secondary and Starting ReplicationThis section explains how to synchronize the Secondary and start replication. Methods to Synchronize the SecondaryYou can synchronize the Secondary using the network, using block-level tape backup or by physically moving disks to the Secondary. Use one of the following methods to synchronize the Secondary depending on your environment:
The following tables explain when and how to use the different synchronization methods: Using the NetworkYou can synchronize the Secondary over the network either when the application is active or inactive.
Using Block-level Tape BackupMoving Disks Physically
Using the Automatic Synchronization FeatureThe Automatic Synchronization feature enables you to transfer the data on the Primary to the Secondary over the network. You can synchronize the Secondary using automatic synchronization either when the application is active or inactive. The Automatic Synchronization procedure transfers data in the Primary data volumes to the Secondary by reading the Primary data volumes from start to finish and sending the data to the Secondary. Note Automatic Synchronization does not maintain the order of writes; therefore, the Secondary is inconsistent until the process is complete. The Secondary becomes consistent after the automatic synchronization completes. To use Automatic Synchronization successfully, the network must be sized appropriately. Note that the synchronization will complete only if the Primary receives writes at a lesser rate than they can be sent to the Secondary. If the Primary receives writes at a faster rate than they can be sent to the Secondary, the synchronization might never complete, especially if the writes are dispersed widely in the volume. This feature enables you to synchronize multiple Secondary hosts at the same time. When performing automatic synchronization to multiple Secondary hosts, synchronization proceeds at the rate of the slowest network. VVR pauses synchronization if the Secondary fails or the network disconnects. If the Primary fails while synchronization is in progress, the synchronization continues from the point at which it had stopped when the Primary recovers. Prerequisite for using Automatic Synchronization
The vradmin startrep command when used with the option -a enables you to start replication and automatically synchronize the Secondary data volumes with the Primary data volumes in an RDS; it brings the Secondary data volumes up-to-date with the Primary data volumes. You can use this command to synchronize the Secondary when the data volumes contain data and when the application is active or inactive. Replication to another Secondary can be started only after this automatic synchronization completes. The vradmin startrep command can be issued from any host in the RDS. To check the status and progress of the automatic synchronization, use the vxrlink status command on the Primary RLINK. For more information, see Displaying the Status of a Secondary. To synchronize the Secondary and start replication using automatic synchronization, issue the following command: # vradmin -g diskgroup -a startrep local_rvgname sec_hostname The argument local_rvgname is the name of the RVG on the local host and represents its RDS. The argument sec_hostname is the name of the Secondary host displayed in the output of the vradmin printrvg command. If the RDS contains only one Secondary, the sec_hostname is optional. Example---Using the Automatic Synchronization Feature In this example, the data volumes in the Primary RVG hr_rvg on host seattle contain valid data and the application is active. To start replication and synchronize the Secondary RVG hr_rvg on host london, issue the following command: # vradmin -g hrdg -a startrep hr_rvg london Notes on Using Automatic Synchronization
Using the Full Synchronization FeatureThis section explains how to use the Full Synchronization feature of VVR to synchronize the Secondary completely and start replication. Full synchronization compresses zeroes while processing the data and hence proves beneficial when a large part of the Primary data volumes contain zeroes. However, we recommend that you use Automatic Synchronization to synchronize the Secondary because its performance is better than Full Synchronization. Automatic Synchronization also handles network outages efficiently and continues even after the system reboots. Full synchronization synchronizes the Secondary over the network when the Primary data volumes contain data and when the application is active or inactive. After the Primary and Secondary are synchronized, replication must be started. By default, the vradmin syncrvg command synchronizes Secondary data volumes using difference-based synchronization. To perform a full synchronization, specify the -full option. We recommend that you always use the -c option with the vradmin syncrvg command to synchronize the Secondary using full synchronization. The -c checkpoint option starts a checkpoint, synchronizes the data volumes, and ends the checkpoint after the synchronization completes. After the vradmin syncrvg command completes, use this checkpoint with the vradmin startrep command to start replication. To delete the Primary checkpoints, use the vxrvg checkdelete command. The SRL must be large enough to hold the incoming updates to the Primary data volumes while the synchronization is in progress. The SRL might fill up and the checkpoint might overflow if the number of writes to the Primary data volumes is high when the Secondary is being synchronized. A checkpoint that has overflowed becomes invalid and cannot be used to start replication. If the checkpoint overflows while synchronization is in progress, the vradmin syncrvg command must be issued again. The vradmin syncrvg command can be used to synchronize multiple Secondaries at the same time. The vradmin syncrvg command displays the progress of the synchronization. To synchronize the Secondary RVG with the Primary RVG using full synchronization with checkpoint Note The vradmin syncrvg command cannot be used for an RVG that has volume-set component volumes associated to it.
Example---Synchronizing the Secondary Using Full Synchronization with Checkpoint This example explains how to synchronize the Secondary RVG hr_rvg on the Secondary host london with the Primary RVG on host seattle. To synchronize the Secondary RVG hr_rvg on london with its Primary RVG on seattle using full synchronization
Using Block-level Backup and CheckpointThis method is useful for low bandwidth networks or very large data sets. You can use the block-level backup and checkpoint method to synchronize the Secondary when a backup of the data is available and a checkpoint has been started on the Primary. You do not have to use the network to transfer the data. This method does have a risk of SRL overflow. Make sure that the SRL is large enough to contain all the writes made by the application while synchronization is in progress. For instructions on how to resize the SRL, see Resizing the SRL. Caution During the process the checkpoint will overflow if the SRL fills up. To determine if the checkpoint has overflowed, issue the vxrvg cplist rvg_name command on the Primary to display the list of valid checkpoints. For detailed instructions, see Example---Synchronizing the Secondary Using Block-level Backup. To synchronize the Secondary using backup and Primary checkpoint
Example---Synchronizing the Secondary Using Block-level Backup This example explains how to synchronize the Secondary RVG hr_rvg on the Secondary host london with the Primary RVG on host seattle using block-level backup and checkpoint.
Using the Disk Group Split and Join FeatureThe Disk Group Split and Join feature of VERITAS Volume Manager enables you to synchronize the Secondary. For more information on the Disk Group Split and Join feature, refer to the VERITAS Volume Manager Administrator's Guide. To set up replication using this method, ensure that you have a valid Disk Group Split and Join license on your system. For detailed instructions, see Example 4---Setting Up Replication Using Disk Group Split and Join. To synchronize the Secondary using Disk Group Split and Join Perform the following steps on the Primary:
Using Difference-Based SynchronizationYou can synchronize the Secondary using difference-based synchronization when there is little difference between the Primary and Secondary data volumes in an RDS. Difference-based synchronization can be used to transfer data over the network when the application is active or inactive. In difference-based synchronization, the syncrvg command generates MD5 checksums for the data blocks on the Primary data volume and the corresponding Secondary data volume and compares these checksums. The syncrvg command then transfers over the network only those blocks for which checksums do not match. These steps are repeated for the entire Primary data volume and Secondary data volume. MD5 checksum is generated using the RSA Data Security, Inc. MD5 Message-Digest Algorithm. Difference-based synchronization is useful in situations such as:
The vradmin syncrvg command enables you to synchronize the Secondary RVG with the Primary RVG based on differences. You can issue the vradmin syncrvg command from any host in the RDS. The vradmin syncrvg command synchronizes the data volumes associated with the Secondary RVG in an RDS with the corresponding data volumes associated with its Primary RVG. The vradmin syncrvg command can be used to synchronize multiple Secondaries at the same time. To synchronize Secondary RVG with Primary RVG based on differences
Before issuing this command, verify that the RLINKs are detached. Use the # vradmin -g diskgroup -c checkpt_name syncrvg local_rvgname \ sec_hostname.... Note that you can use the -c option with the vradmin syncrvg command when performing difference-based synchronization, to automatically start a checkpoint with the specified name. After the data volumes are synchronized the checkpoint is ended. This checkpoint can then be used to start replication using the vradmin startrep command. The argument local_rvgname is the name of the RVG on the local host and represents its RDS. The argument sec_hostname is a space-separated list of the names of the Secondary hosts as displayed in the output of the vradmin printrvg command. The argument checkpt_name specifies the name of the Primary checkpoint of your choice. Example---Synchronizing the Secondary Based on Differences This example explains how to synchronize the Secondary RVG hr_rvg on the Secondary host london with the Primary RVG on host seattle. To synchronize the Secondary RVG, hr_rvg, on london with its Primary RVG on seattle based on differences Before issuing this command, make sure that the RLINKs are detached. # vradmin -g hrdg -c checkpt_presync syncrvg hr_rvg london Note that you can use the -c option with the vradmin syncrvg command when performing difference-based synchronization to automatically start a checkpoint with the specified name. After the data volumes are synchronized the checkpoint is ended. This checkpoint can then be used to start replication using the vradmin startrep command. The name checkpt_presync is the Primary checkpoint that you will create. |
^ Return to Top | < Previous | Next > |
Product: Volume Replicator Guides | |
Manual: Volume Replicator 4.1 Administrator's Guide | |
VERITAS Software Corporation
www.veritas.com |