Thursday, May 24, 2012

Netapp Snapmirror Setup


In this tutorial we will concentrate on setting up Netapp’s Snapmirror. In this lab I have two filers with the following hostname ctrlpri and ctrldr. ctrlpri (10.10.10.1) being the primary or source filer and ctrldr (10.10.10.2) being the disaster recovery or destination filer.
1. First up you must license snapmirror on both filers.
2. Enable Snapmirror on both filers.
ctrlpri> options snapmirror.enable on
ctrldr> options snapmirror.enable on
3. Turn on the Snapmirror log
ctrlpri> options snapmirror.log.enable on
ctrldr> options snapmirror.log.enable on
4. You must allow the destination filer access to the source filer. This is done by adding the ip address to /etc/snapmirror.allow on the source filer. NOTE use rdfile /etc/snapmirror.allow first to see if you have any existing entries.
ctrlpri> wrfile /etc/snapmirror.allow
10.10.10.2
ctrldr
Press CTRL-C to exit and save the file.
5. To create a volume for volume based replication we must first create the volume and then restrict it (In this tutorial we have created a destination volume named vol1_dr). After creating the volume, type in this command to restrict it. NOTE: You do not need to restrict the volume for Qtree replication which is explained in step 6b.
ctrldr> vol restrict vol1_dr
6a. The next step is to define what you want to replicate. In this step we will initialize a volume based replication. This is performed on the destination filer.
ctrldr> snapmirror initialize -S ctrlpri:vol1 ctrldr:vol1_dr
Transfer started.
Monitor progress with ‘snapmirror status’ or the snapmirror log
6b. In this step we will initialize a Qtree based replication. This is also performed on the destination filer. NOTE: the destination volume MUST NOT be in restricted mode. The Qtree will automatically be created for you, there is no need to manually create the destination Qtree.
ctrldr> snapmirror initialize -S ctrlpri:/vol/vol1/QtreeVM-NFS ctrldr:/vol/vol1_dr/Qtreevm-NFS
Transfer started.
Monitor progress with ‘snapmirror status’ or the snapmirror log
7. Now that we have our replication going we will want to check the status. On the destination filer perform the following command:
ctrldr> snapmirror status

ctrldr qtree Netapp Snapmirror Setup
As the initial baseline transfer is happening you will see the status as Uninitialized, once it completes you will see the status as idle.
8. So we’ve finished our initial baseline transfer and our status shows snapmirror is idle. Let’s schedule 15 minute transfers from source to destination. Use rdfile /etc/snapmirror.conf on the destination filer first to see if the file contains data. Then use the following command:
ctrldr> wrfile /etc/snapmirror.conf
ctrlpri:vol1 ctrldr:vol1_dr – 15 * * * *
CTRL-C to exit and save the file.
This will replicate every 15 minutes. Each * represents a value. Starting from right to left you have day of week, month, day of month, hour minute. Each value can only be a number. i.e. for month enter in 5 for May
You can check out more Snapmirror CLI commands in the Netapp CLI Pocket Guide Page.

Snapmirror Setup, Configuration and Schedule Video Tutorial


Source : www.sysadmintutorials.com


0 comments:

Post a Comment