AFM DR trucking use cases
Create the primary and secondary filesets from scratch
The primary and secondary clusters are empty and AFM DR establishes the relationship by creating PSNAP0 that is empty.
Trucking method recommendation: Use the inband trucking method for this scenario because the clusters have no data to copy and create PSNAP0.
Create a primary and secondary fileset from scratch, where primary has data and secondary does not have data
In this case, either the inband or the outband mechanism can be used to copy the data to the secondary cluster.
- Inband:
By using the inband method, the existing data in the primary is copied by AFM DR to the secondary. To copy this data a work queue is created on the gateway that contains all of the files that need to be copied and file system operations that need to be performed on the secondary. Then, the gateway processes this queue as quickly as possible by copying data to the secondary. When all of the work, which was outstanding when the command was run, is flushed to the secondary, a PSNAP0 is created. The trucking process ends when a snapshot is created.
It is recommended to start applications on the primary after the trucking process is complete. However, if applications are started while the trucking process is in progress, the gateway node queues the data generated by the application and the requests from the trucking process at the same time. The gateway node queue buffer is filled with many requests, which causes the queue memory overflow. In such a case, the queue is dropped and the gateway node goes into the recovery mode. This can result in a cycle where the primary cluster always lags behind the secondary cluster.
The potential solutions are as follows:- Add bandwidth to handle the initial synchronization workload. This bandwidth can involve tuning – for example, increasing the number of flush threads to increase the gateway throughput, additional hardware or network bandwidth.
- Keep the application from writing to the primary until the trucking process is complete and PSNAP0 is created.
- Increase the gateway node memory allocation to prevent memory overflows.
- Outband:In this case, a complete copy of the data exists before the primary-secondary relationship is created. The data can be copied to the secondary by using any method that includes a restore from a backup or a rsync process. When an identical copy of the data exists at the secondary, AFM DR can establish the DR relationship. The primary and secondary need to be identical when the relationship is established, so during this time the data must not change in the primary. After the PSNAP0 is created, applications can start by using the AFM DR filesets.Note: Both methods use the --inband option of mmafmctl command while setting up the relationship between the primary and secondary sites. For data that is already copied to the secondary site, mtime of files at the primary and secondary site is checked. If mtime values of both files match, data is not copied again and existing data on the secondary site is used. If mtime values of both files do not match, existing data on the secondary site is discarded and data from the primary site is written to the secondary site.
The primary fileset is empty and the secondary fileset has data
Trucking method recommendation: In such a situation, the recommended mechanism is outband trucking. The administrator copies data from the secondary to the primary and then uses the AFM DR conversion mechanism to establish the DR relationship.
Data exists on the 'to-be' primary and the secondary filesets
Ensure that the data is identical on the primary and the secondary before the AFM DR conversion is performed.
Trucking method recommendation: This can be done by using only the outband trucking. AFM DR checks whether the data is the same when the relationship is established.