Technology Blogs by Members
Explore a vibrant mix of technical expertise, industry insights, and tech buzz in member blogs covering SAP products, technology, and events. Get in the mix!
cancel
Showing results for 
Search instead for 
Did you mean: 
8,944
The purpose of this blog is to give insights on some of the commands and terms used in HANA System Replication.

HANA System Replication is a mechanism to ensure high availability of the system. It is mainly configured for reduced downtime during planned maintenance and disasters.

Terms & Definitions:

(1) hdbnsutil → Hana Database nameserver Utilities

(2) sr → system replication

(3) hdbnsutil -sr_enable --name=<Site Name> → This command is executed on the system which serves as source site in the replication.

This command is to be executed when the Hana database is up and running.

The Site name can be given according to the convenience or as per the naming convention being followed in the landscape.

Name is the logical entity given to identify systems in the replication tier.

(4) hdbnsutil -sr_disable → This command is executed on the system which is currently enabled as source site in the replication and is intended to disable it from serving as the source site.

This command is executed when the Hana database is up and running.

(5) hdbnsutil -sr_unregister → This command is executed on the system which has to be isolated from the replication or the intent is to stop it from serving as secondary site.

This command is ideally executed when the Hana database is in stopped state.

(6) hdbnsutil -sr_register --name=<Site Name> --remoteHost=<Source System Hostname> --
remoteInstance=<Instance Number> --replicationMode=<Mode of Replication> --
operationMode=<Mode of Operation> --force_full_replica

(a) remoteHost: This is the Hostname of the source site to which the current system is being registered.

(b) remoteInstance: Instance number of the source site to which the current system is being registered.

(c) replicationMode: Depending upon the requirement the replication mode can be selected.

(d) operationMode: Depending upon the requirement the operation mode can be selected.

(e) force_full_replica: This option forces the data to be replicated between the source and target from the scratch.

(7) hdbnsutil -sr_state → This command displays the current status of the replication configured.

(8) hdbnsutil -sr_cleanup → This command is to clean up the topology entries saved in the nameserver topology file.

(9) hdbnsutil -sr_cleaup --force → This command can be used in case to do the cleanup forcefully.

(10) hdbnsutil -sr_ changemode → This command is used to change the mode of replication instead of undergoing the process of unregistering and re-registering again.

(11) hdbnsutil -sr_takeover → This command is used to make the subsequent database serving as secondary site to serve as primary.

It only changes the database mode from read only mode to read/write mode.

(12) hdbnsutil -sr_initTopology → This command initializes the whole Hana topology and is only to be executed under extreme conditions as it nullifies every change performed on the database from ever since it was installed.

Types of Replication Modes:

(1) Synchronous(sync):

Primary system sends the data to secondary.
The secondary system accepts the data and commits into the persistence.
Once the data is persisted in secondary it sends an acknowledgement to the primary.
Then the primary system commits the data into persistence.
Primary system proceeds further if the parameter’s value “logshipping_timeout” is crossed.

(2) Synchronous In-memory(Syncmem):

Primary system sends the data to secondary.
The secondary loads the data into memory and acknowledges the primary system.
Upon receiving the confirmation, the primary system commits the data into persistence.

(3) Asynchronous (Async):

Primary system sends the data to secondary.
It writes the data into persistence without acknowledgement from the secondary system.

(4) Synchronous Full(Full sync):

Primary system sends the data to secondary.
The secondary system accepts the data and commits into the persistence.
Once the data is persisted in secondary it sends an acknowledgement to the primary.
Then the primary system commits the data into persistence.
The primary is totally blocked when there is no response from the secondary.

Types of Operation Modes:

(1) logreplay:

This kind of operation mode allows redo logs to be shipped to the secondary site.

(2) delta_datashipping:

This kind of operation mode allows the data to be shipped to the secondary system in the form of delta changes along with the redo logs.

(3) logreplay_readaccess:

This kind of operation mode is similar to logreplay, but here the secondary site is read enabled.
The reporting tools can connect to the secondary server, instead of fetching the data from the
primary.
1 Comment
Labels in this area