SHIFT

--- Sjoerd Hooft's InFormation Technology ---

User Tools

Site Tools


Sidebar

Recently Changed Pages:

View All Pages


View All Tags


LinkedIn




WIKI Disclaimer: As with most other things on the Internet, the content on this wiki is not supported. It was contributed by me and is published “as is”. It has worked for me, and might work for you.
Also note that any view or statement expressed anywhere on this site are strictly mine and not the opinions or views of my employer.


Pages with comments

View All Comments

srm

Site Recovery Manager 5.1

This page is about VMware Site Recovery Manager (SRM) 5.1. Installation, configuration and testing will be discussed. This implementation will use Array Based Replication on a IBM N-Series 6060, which actually is a NetApp FAS3160, so we'll use the N-Series Storage Replication Adapter (SRA). We already have a replication between our sites but this uses an old naming convention and is also not compliant with our performance policies. Therefore these will also change. We already prepared our environment for implementing Site Recovery Manager so both of our sites have a vCenter, and they are in Linked Mode (which is not a requirement but is a nice to have). The database is a Microsoft MSSQL 2008 R2 Server which is already installed by my DBA on a separate server.

The preparations are discussed in:

VMware preparations:

Note: The vCenter 5.1 report is based on vCenter 5.1 GA. The installed version is upgraded to 5.1.0b (release date 2012-12-20).

NetApp preparations:

Note: The terms IBM N-Series and NetApp will probably both be used in this page. I'm used of talking about NetApps, but the software I'm using is the rebranded one from IBM. This is obviously for support reasons.

Software Prerequisites

You need the SQL Native Client to create the ODBC Connection. Download the SQL Native Client by pointing your browser to the Microsoft SQL Server 2008 R2 SP1 Feature Pack website and download the “1033\x64\sqlncli.msi” file. Keep all settings default.

Note: Repeat this process at the recovery site.

Create the Database

When creating the database you'll need to meet these requirements:

  • Authentication:
    • Windows authentication when the SRM server and the database server are on the same host
    • SQL Authentication when the SRM server and the database server are on different hosts
  • Grant the SRM database user account the bulk insert, connect, and create table permissions.
  • The SRM database schema must have the same name as the database user account.
  • Set the SRM database user as the owner of the SRM database schema.
  • Set the SRM database schema as the default schema for the SRM database user.

For convenience I created a script which will set all required settings correct:

<code sql>
USE [master]
GO
CREATE DATABASE [SRMDB] ON PRIMARY
(NAME = N'srmdb', FILENAME = N'D:\MSSQL\DATA\SRMDB.mdf', FILEGROWTH = 10% )
LOG ON
(NAME = N'srmdb_log', FILENAME = N'D:\MSSQL\DATA\SRMDB.ldf', FILEGROWTH = 10% )
COLLATE SQL_Latin1_General_CP1_CI_AS
GO
USE SRMDB
GO
sp_addlogin @loginame=[SRM], @passwd=N'XXXXXXXXXXXXXXXXXXXXXXX', @defdb='SRMDB', @deflanguage='us_english'
GO
ALTER LOGIN [SRM] WITH CHECK_POLICY = OFF
GO
CREATE USER [SRM] for LOGIN [SRM]
GO
CREATE SCHEMA [SRM]
GO
ALTER USER [SRM] WITH DEFAULT_SCHEMA =[SRM]
GO
sp_addrolemember @rolename = 'db_owner', @membername = [SRM]
GO
Note: Repeat this process at the recovery site.

Create the DSN

Since SRM 5.1 is now a full 64 bits application you also need a 64 bits ODBC connection.

On the SRM Server perform the following steps to configure a correct DSN:

  • Navigate to Start → Administrative Tools → Data Sources (ODBC) and open the “System DSN tab”
  • Click Add
  • Select the “SQL Server Native Client 10.0” (version 2009.100.2500.00). If this one is not listed you forgot to install the SQL Native Client (see above under required software)
  • Provide a descriptive name and the server you want to connect to:

srm01.jpg

  • Change the authentication method to SQL Server authentication and enter the credentials of the database user:

srm02.jpg

  • Set the default database to SRMDB and keep all other defaults:

srm03.jpg

  • Keep all other options default, and at the end review your settings and click the “Test Data Source” button. The result should say that the tests completed successfully.
Note: Repeat this process at the recovery site.

Installing Site Recovery Manager

Installing Site Recovery Manager is done using this executable:

  • VMware-srm-5.1.0-941848.exe
    • Version: 5.1.0.1
    • Release date: 2012-12-20

Start the installation wizard and go through the installation wizard to accept the EULA and keep the default installation folder (C:\Program Files\VMware\VMware vCenter Site Recovery Manager). Since we'll use array based replication we'll choose to not install vSphere replication. Then fill in the vCenter information:
srm04.jpg
Accept the Security warning about the certificates, and select to automatically generate a certificate with your organization name and department:
srm05.jpgsrm06.jpg
Now enter a unique name for the site you're installing SRM in, and provide email addresses for notifications:
srm07.jpg
Now enter the database information:
srm08.jpg
Now just click install to start the installation.

Note: Repeat this process at the recovery site.

Installing Storage Replication Adapter

Installing the Storage Replication Adapter is done with this installer:

  • ibm_n_sra_2.0.1_64bit.msi
    • Download package: ibm_N-series_2.0.1.zip
    • Release date: 2012-09-12

Start the installation wizard and accept the EULA. Make sure you install the SRA for all users and to a complete install:
srm09.jpg
Then click install to start the installation.

Note: Repeat this process at the recovery site.

Install SRM Plug-In

Now on every box which will be used to manage SRM the plug-in will need to be installed. Make sure you do this on at least one box at the protected as well as the recovery site:

  • Login to the vSphere Client
  • Go to Plug-Ins and select Manage Plug-Ins
  • Click the Download and Install link for the available SRM plug-in:

srm10.jpg
The install is a simple Run, Next, Next install without any configuration. When the installation is done you should find the Site Recovery icon in the Solutions and Applications section in the vSphere client:
srm11.jpg

You should now be able to make a connection to the SRM servers in your vSphere client on both of your sites. Note that the status is still “Not Paired”: srm12.jpg

Pairing the Sites

Now it's time to start with the configuration of Site Recovery Manager. This starts with pairing the two sites together, which always starts from the protected site. In the Site Recovery view click the Configure Connection button to start the pairing process:
srm13.jpg
Now enter the name of the vCenter of the recovery site:
srm14.jpg
You will now receive an error regarding the certificate of the remote vCenter, click OK to accept this, then enter the vCenter server credentials:
srm15.jpg
You will receive an error regarding certificates again, this time of the remote SRM server. After clicking OK, the actual connection will be made:
srm16.jpg
Now notice that a popup window will appear asking for vCenter credentials. This would be your credentials, this is because the passing on of credentials between the two sites is not supported (yet) for SRM, and you'll need to enter your credentials for both vCenters:
srm17.jpg
It may take a while (for me a couple of minutes) but then you'll see that the both sites are connected:
srm18.jpg

Configure Inventory Mappings

This step actually is optional because you can configure each VMs resources per VM in the Protection Group. However, by setting a few them now you set defaults, which speeds up the process of protecting VMs. We'll use two type of mappings, resource and network.

To configure the resource mappings click the Resource Mappings in the Site Recovery view and select a cluster you want to create a mapping for, then click the configure Mapping button. A new window popups allowing you to select a destination cluster at the recovery site:
srm19.jpg
Repeat this for all clusters you will do failovers for, which will result in the following overview:
srm20.jpg

To configure the network mappings click the Network Mappings in the Site Recovery view and select a network you want to create a mapping for, then click the configure Mapping button. We have different networks for testing and for failover purposes. In this mapping configuration we select the Test network:
srm21.jpg

See SRM Networks for more information regarding SRM and Networks.

Assign a Placeholder Datastore

An important step in configuring SRM is creating the placeholder datastore. This is a small datastore which will be used by SRM to create a placeholder vmx (and some additional files) so this vmx can be registered to a host/cluster. Remember that the vmx file holds some site specific configuration for the VM and these should be modified for a failover. Without this placeholder vmx file there would be nothing to modify since the replicated LUNs are readonly. These placeholder VMs are really small so the datastore doesn't need to be that large. Remember that a VMFS volume must be a minimum of 1.2 GB in size, and most filers also keep a minimum. A size of 10 or 20 GB should be sufficient.

To assign an existing datastore as the placeholder datastore click the Placeholder Datastores tab in the Site Recovery view and click the Configure Placeholder Datastore. This will present you with a list of the datastores available so you can select one:
srm22.jpg
This will show like this in the Site Recovery view:
srm23.jpg

Configure Array Manager

Note that the “options httpd.admin.enable on” needs to be done on the storage before the Array Manager can be added. Otherwise this error will be shown:
SRA command 'discoverArrays' failed. Address of the storage array is not reachable. Storage array might be down or IP address entered might be incorrect. Ensure that the storage array is up and running and the IP address of the storage  array is reachable through the command line interface. 

The Array Manager is the software piece responsible for managing the storage. This is your graphical interface towards your storage device. To configure one go into your Site Recovery view and click the Array Managers button in the left under corner. This will provide you with an “Add Array Manager” button the left top corner:
srm24.jpg
Now, before you click the “Add Array Manager”, first do a rescan for SRA's:
srm25.jpg
This will present you with your installed SRA, note that you'll need to do this at the recovery site as well preventing the message “Unable to find SRA at the paired site”:
srm26.jpg

The next section is in our environment a little bit different from the default. We have a separate network for our replication, and since we use NetApp filers we have two heads per site. Also, there is a small bug in SRA 2.0.1 which screws up the find replicated devices function, meaning you'll have to either use the 2.0 version or tell the array manager which volumes it should check for. So the solution for all of these problems is:

  • Configure the SRA to use IP for replication
    • And set the replication IP addresses for the host names to use
  • Add a separate array manager per head
  • Add the volumes which are included in the replication in the array managers

To configure the SRA to use IP addresses change the following files at the SRM servers:
C:\Program Files\VMware\VMware vCenter Site Recovery Manager\storage\sra\IBM_ONTAP\ontap_config.txt:

#use_ip_for_snapmirror_relation = on\off(default is off)
# 20130208 sjoerd Changed to on
use_ip_for_snapmirror_relation = on

C:\Program Files\VMware\VMware vCenter Site Recovery Manager\storage\sra\IBM_ONTAP\ip_hostname_mapping.txt:

#this file contains the IP address and hostname mapping for protected and recovery site array
#if use_ip_for_snapmirror_relation is on in ontap_config.txt IP address and hostname mapping  should be 
#provided otherwise SRA will throw error mapping info not found. duplicate entries are not allowed if duplicate
#entries are found sra will return error.
#format of this file is as follows
#hostname = IP address (or long hostname)
#example 
#f3070-192-77 = 10.72.192.77
filer01a = 192.168.18.71
filer01b = 192.168.18.72
filer02a = 192.168.16.71
filer02b = 192.168.16.72
Note: You need to make these changes at both SRM servers.

Now you can click the “Add Array Manager” button, which will start a wizard where you start with giving the Array Manager a display name:
srm27.jpg
Enter the normal management IP address of Node A (or node B) of the filer, the list of replicated volumes and the username and password:
srm28.jpg
Which will give you a success message:
srm29.jpg
And an Array Manager in the overview:
srm30.jpg

Note: Repeat this process at the recovery site before you enable the Array Manager configuration.

Now enable the configuration by selecting one of the Array Managers and clicking the enable Action:
srm31.jpg
This will start a series of tasks which can be monitored in the Recent Tasks panel. When done you can click the Devices tab which will show you the devices:
srm32.jpg

Note: If you need to add a volume in the Array Manager simply right-click the array manager and select “Edit Array Manager” to follow the same wizard so you can add the new volume. Note that you need to add the volume for both Array Managers at the protected and recovery site.

Errors

These are some errors I encountered:

Error: Paired array manager not found. A paired array manager must be added for each site before enabling the array pair.

For me this meant I hadn't done the IP HostName Mapping for the SRAs yet. See above.

Error: Internal error: std::exception 'class Dr::Xml::XmlValidateException' "Element 'SourceDevices' is not valid for content model: '(SourceDevice,)'".

This is caused by the SRA bug. Simply add the volumes to the Array Manager configuration as shown above. After you've done that enabling of the Array Pairs will succeed without errors.

If you want to make sure you have all the snapmirrored volumes login to the destination filer (at the recovery site) and issue this command:

filer02a> rdfile /etc/snapmirror.conf
#Regenerated by registry Thu Apr 26 09:17:46 GMT 2012
#
192.168.18.71:R_DATA_Volume_0 filer02a:R_DATA_Volume_0 - * * * *
192.168.18.71:R_OS_Volume_0 filer02a:R_OS_Volume_0 - * * * *
192.168.18.71:R_FC_PRD_01A filer02a:R_FC_PRD_04A - * * * *

Licensing SRM

Don't forget to assign licenses! You install them just the same way as all other licenses (vCenter → Home → Administration → Licensing → Manage vSphere Licenses) and this is a kb article about it.

Continue

You are now done with the configuration of Site Recovery Manager 5.1 and can start SRM 5.1: Create Protection Groups and Recovery Plans creating protection groups.

You could leave a comment if you were logged in.
srm.txt · Last modified: 2021/09/24 00:25 (external edit)