SAP Hana TDI setup – SAP Hana HSR & SAP Netweaver With file system replication (Part2)
In the Part1 of my doucment i have explain how to config my DNS, install Hana by using a script, install Netweaver 7.5 and configure Hana HSR by command line.
My Hana HSR competed i check the replication status, this can be done by:
SAP Hana Studio under replication
From the Hana Cockpit
By command line as SIDADM with the command “hdbnsutil –sr_state
And by using Python tool from the “python_support” directory
I’m all set for the Hana replication I can now configure my FreeNas for storage replication for the ABAP server portion.
Configure FreeNas 10 Storage replication
FreeNas is a nice opensource free storage appliance which can by virtual or physical, up to you.
It allows you to use the same functionality or feature (very close) like a professional NAS and certainly the same as Home NAS.
Using storage replication is a common feature/service deserve by any professional NAS/SAN appliance such as:
… and more
Earlier in my configuration I have assign disk and create dataset to my respective vm which host SAP application, this task is mandatory to allow storage replication.
The first step is to create a “periodic snapshot task” is order to schedule the frequency of the data shipping
Once frequency is define, I can configure the “replication task”
When active I can see now my storage from site1 replicated under site2
I need now to mount on my secondary site the filesystem /usr/sap and /sapmnt from the snapped volume
I can see now that I have the same content on both storage
Note: Do not forget to request the license for BOTH site, run saplicense –get on both site for the HW key and load the license
Perform failed over to Site2
My Hana replication is working and my storage replication either for SAP application, I need to test now my solution to make sure I have no issue, I my case it is a controlled failed over process.
On the primary site, I begging to shutdown my SAP application
Then I suspend/stop the replication and periodic snapshot task on FreeNas
On my secondary site, I perform a takeover on Hana by using: hdbnsutil –sr_takeover
And shut it down the primary site
The failed over process completed I need to update my DNS in order to point the alias (vmapp/vmhana) to the correct site
Before to start the application make sure to check the hdbuserstore on the secondary site and also copy the /etc/services file in the secondary too
My secondary site is now fully operational from Hana side, I can start my SAP application
My application is now up and running I will connect to it I check the system information retrieve from the system info, I’m connected to the secondary database as expected.
I can see that I’m running on the secondary site without changing anything from my saplogon information and hana studio
My connection successful, I can perform a failed back operation.
Perform Hana upgrade to SP11
My upgrade process consist of updating my Hana instance from SP10 to SP11 in a limited time frame windows, my scenario will reflect a situation where I can’t afford to have more than (time) of outage.
In order to realize this operation I will proceed as follow:
- Stop the replication and snapshot task of FreeNas (site1)
- Configure the system user password in the local userstore under the key SRTAKEOVER (site2)
- Upgrade Hana to SP11 (site2)
- Upgrade Hana client on application server (site2)
- Re-sych the secondary Hana database site with the primary site (site2)
During the update process
Once the update is done Hana will restart and re-sych
- Shutdown application (site1)
- Perform takeover (site2)
- Switch DNS pointer
- Start application (site2)
- Start the replication and snapshot task of FreeNas (site2)
Refer to the section “Perform failed over to Site2” except for the file system replication, since now I replicate from Site2 to Site1. By doing so the client on Site1 will be automatically updated to SP11.
Upgrade Hana to SP11 (site1)
Register Hana as secondary site (site1)
By running the option “–hdbupd_server_nostart” when the primary will be updated it won’t restart, so I will be able to register it a secondary site and start it only once
Note: something you probably notice, but I still add it, when you are running on Hana SP10 and do register a site for replication vs SP11, the syntax change when you choose the mode of replication
- SP10 = hdbnsutil -sr_register –remoteHost=<host> –remoteInstance=## –mode=< sync|syncmem|async> –name=<site name>
- SP11 = hdbnsutil -sr_register –remoteHost=<host> –remoteInstance=## –ReplicationMode=<sync|syncmem|async> –operationMode=delta_datashipping|logreplay –name=<site name>
Once done I check from the former secondary site the replication process
My configuration is now completed for my DR scenario.