Hi All,
Just fyi and would like to share my finding that Secondary host can be bring up without execute sr_takeover in hana system replication enviroment.
1) in our scenario, hana system replication is setup for 2 node, Primary and Secondary.
2) synchronization completed where initial snapshot is shipped to Secondary site.
3) Services in secondary host is up and accepting log transfer and replay.
4) normally, we will execute sr_takeover for switching over and bring Secondary site up for production usage. However, found out that apart from executing sr_takeover, we can do the following which give us the same result as sr_takeover.
i) issue HDB stop in secondary
ii) run hdbnsutil -sr_cleanup –force in secondary.
v-cbj2hanas0:/usr/sap/TST/HDB05> hdbnsutil -sr_cleanup –force
cleaning up …
###################################################################################################################################
### WARNING: cleaning up will break system replication; secondary sites need to be takeovered by issuing hdbnsutil -sr_takeover ###
###################################################################################################################################
checking for inactive nameserver …
nameserver v-host:30501 not responding.
opening persistence …
run as transaction master
clearing topology …
clearing local ini files …
done.
iii) issue hdbnsutil -sr_state to ensure system replication state is none
System Replication State
~~~~~~~~~~~~~~~~~~~~~~~~
mode: none
iv) Start Secondary Host. Once up, system is ready to access and for production usage.
vi) If you want to clear the replication config on Primary, you can issue below without stopping HDB.
> hdbnsutil -sr_disable –force
checking local nameserver:
checking for inactive nameserver …
nameserver is running, proceeding …
done.
> hdbnsutil -sr_state
checking for active or inactive nameserver …
System Replication State
~~~~~~~~~~~~~~~~~~~~~~~~
mode: none
Just my 2 cents worth, above method works well for system copy where it ensure availability of primary node. However, use it at your own risk as this is not docummented in any SAP material.
Thanks for this information, This is very useful for us.
However I have one question. Once you bring up the secondary in the manner suggested above for say a few hours, is it possible to shut it down and start replication from primary again without having to perform full replication?
Full replication would take a lot of time hence the question.
Thanks,
Anil
Hi Anil,
HANA is smart enough to detect either “full replica” is needed or not. Most likely a full replicate would be initiated if there are changes on secondary when it is up.
Thanks,
Nicholas Chang
Hi Nicholas,
Can’t you just stop the secondary, unregister it, start it, do your testing and then shutdown and re-register again at the end?
Best regards,
Frank
Hi Frank,
Yes, this is impossible. Just bear in mind a full replicate is required and you don’t activate any IP redirection.
Thanks,
Nicholas Chang