Skip to content

Commit df1c187

Browse files
committed
Formatting
1 parent 6b21fbb commit df1c187

File tree

1 file changed

+26
-25
lines changed

1 file changed

+26
-25
lines changed

articles/virtual-machines/workloads/sap/sap-hana-high-availability-scale-out-hsr-suse.md

Lines changed: 26 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -819,36 +819,39 @@ Create a dummy file system cluster resource, which will monitor and report failu
819819

820820
## Implement HANA HA hooks SAPHanaSrMultiTarget and susChkSrv
821821

822-
This important step is to optimize the integration with the cluster and detection when a cluster failover is possible. It is highly recommended to configure SAPHanaSrMultiTarget Python hook. For HANA 2.0 SP5 and above, implementing both SAPHanaSrMultiTarget and susChkSrv hooks is recommended.
822+
This important step is to optimize the integration with the cluster and detection when a cluster failover is possible. It is highly recommended to configure SAPHanaSrMultiTarget Python hook. For HANA 2.0 SP5 and higher, implementing both SAPHanaSrMultiTarget and susChkSrv hooks is recommended.
823823

824824
> [!NOTE]
825825
> SAPHanaSrMultiTarget HA provider replaces SAPHanaSR for HANA scale-out. SAPHanaSR was described in earlier version of this document.
826826
> See [SUSE blog post](https://www.suse.com/c/sap-hana-scale-out-multi-target-upgrade/) about changes with the new HANA HA hook.
827-
> This document provides steps for a new installation with the new provider. Upgrading an existing environment from SAPHanaSR to SAPHanaSrMultiTarget provider requires several changes and are _NOT_ described in this document. If the existing environment uses no third site for disaster recovery and [HANA multi-target system replication](https://help.sap.com/docs/SAP_HANA_PLATFORM/4e9b18c116aa42fc84c7dbfd02111aba/ba457510958241889a459e606bbcf3d3.html) is not used, SAPHanaSR HA provider can remain in use.
828827

829-
SusChkSrv extends the functionality of the main SAPHanaSrMultiTarget HA provider. It acts in the situation when HANA process hdbindexserver crashes. If a single process crashes typically HANA tries to restart it. Restarting the indexserver process can take a long time, during which the HANA database is not responsive. With susChkSrv implemented, an immediate and configurable action is executed, instead of waiting on hdbindexserver process to restart on the same node. In HANA scale-out susChkSrv acts for every HANA VM independently. The configured action will kill HANA or fence the affected VM, which triggers a failover by SAPHanaSR in the configured timeout period.
828+
Provided steps for SAPHanaSrMultiTarget hook are for a new installation. Upgrading an existing environment from SAPHanaSR to SAPHanaSrMultiTarget provider requires several changes and are _NOT_ described in this document. If the existing environment uses no third site for disaster recovery and [HANA multi-target system replication](https://help.sap.com/docs/SAP_HANA_PLATFORM/4e9b18c116aa42fc84c7dbfd02111aba/ba457510958241889a459e606bbcf3d3.html) is not used, SAPHanaSR HA provider can remain in use.
830829

831-
SUSE SLES 15 SP1 or higher is required for operation of both HANA HA hooks. Below table shows other dependencies.
830+
SusChkSrv extends the functionality of the main SAPHanaSrMultiTarget HA provider. It acts in the situation when HANA process hdbindexserver crashes. If a single process crashes typically HANA tries to restart it. Restarting the indexserver process can take a long time, during which the HANA database isn't responsive. With susChkSrv implemented, an immediate and configurable action is executed, instead of waiting on hdbindexserver process to restart on the same node. In HANA scale-out susChkSrv acts for every HANA VM independently. The configured action will kill HANA or fence the affected VM, which triggers a failover in the configured timeout period.
831+
832+
SUSE SLES 15 SP1 or higher is required for operation of both HANA HA hooks. Following table shows other dependencies.
832833
833834
|SAP HANA HA hook | HANA version required | SAPHanaSR-ScaleOut required |
834835
|----------------------| ----------------------- | --------------------------- |
835836
| SAPHanaSrMultiTarget | HANA 2.0 SPS4 or higher | 0.181 or higher |
836837
| susChkSrv | HANA 2.0 SPS5 or higher | 0.184.1 or higher |
837838
839+
Steps to implement both hooks:
840+
838841
1. **[1,2]** Stop HANA on both system replication sites. Execute as <sid\>adm:
839842
840843
```bash
841844
sapcontrol -nr 03 -function StopSystem
842845
```
843846
844-
2. **[1,2]** Adjust `global.ini` on each cluster site. If the prerequisites for susChkSrv hook are not met, remove the entire block `[ha_dr_provider_suschksrv]` from below section.
845-
You can adjust the behavior of susChkSrv with parameter action_on_lost. Valid values are [ ignore | stop | kill | fence ].
847+
2. **[1,2]** Adjust `global.ini` on each cluster site. If the prerequisites for susChkSrv hook aren't met, remove the entire block `[ha_dr_provider_suschksrv]`.
848+
You can adjust the behavior of susChkSrv with parameter action_on_lost. Valid values are `[ ignore | stop | kill | fence ]`.
846849

847850
```bash
848-
# add to global.ini
851+
# add to global.ini on both sites. Do not copy global.ini between sites.
849852
[ha_dr_provider_saphanasrmultitarget]
850853
provider = SAPHanaSrMultiTarget
851-
path = /usr/share/SAPHanaSR-ScaleOut/
854+
path = /usr/share/SAPHanaSR-ScaleOut
852855
execution_order = 1
853856
854857
[ha_dr_provider_suschksrv]
@@ -861,7 +864,7 @@ You can adjust the behavior of susChkSrv with parameter action_on_lost. Valid va
861864
ha_dr_saphanasrmultitarget = info
862865
```
863866

864-
Configuration pointing to the standard location /usr/share/SAPHanaSR-ScaleOut brings a benefit, that the python hook code is automatically updated through OS or package updates and it gets used by HANA at next restart. With an optional own path, such as /hana/shared/myHooks you can decouple OS updates from the used hook version.
867+
Default location of the HA hooks as deliveredy SUSE is /usr/share/SAPHanaSR-ScaleOut. Using the standard location brings a benefit, that the python hook code is automatically updated through OS or package updates and gets used by HANA at next restart. With an optional own path, such as /hana/shared/myHooks you can decouple OS updates from the used hook version.
865868

866869
3. **[AH]** The cluster requires sudoers configuration on the cluster nodes for <sid\>adm. In this example that is achieved by creating a new file. Execute the commands as `root` adapt the values of hn1 with correct lowercase SID.
867870

@@ -872,7 +875,6 @@ Configuration pointing to the standard location /usr/share/SAPHanaSR-ScaleOut br
872875
so1adm ALL=(ALL) NOPASSWD: /usr/sbin/crm_attribute -n hana_hn1_gsh *
873876
so1adm ALL=(ALL) NOPASSWD: /usr/sbin/SAPHanaSR-hookHelper --sid=hn1 *
874877
EOF
875-
876878
```
877879
878880
4. **[1,2]** Start SAP HANA on both replication sites. Execute as <sid\>adm.
@@ -1005,33 +1007,32 @@ Configuration pointing to the standard location /usr/share/SAPHanaSR-ScaleOut br
10051007
## (Optional) Enabling HANA multi-target system replication for DR purposes
10061008
10071009
<details>
1008-
<summary>Expand</summary>
1010+
<summary>Expand section</summary>
10091011
1010-
With new SAP HANA HA provider SAPHanaSrMultiTarget, a third system replication site as disaster recovery (DR) can be used with a HANA scale-out system. The cluster environment is aware of a multi-target DR setup. Failure of the third site will not trigger any cluster action. Cluster is detects the replication status of connected sites and the monitored attributed can change between SOK and SFAIL. Maximum of one system replication to an HANA database outside the linux cluster is supported.
1012+
With new SAP HANA HA provider SAPHanaSrMultiTarget, a third system replication site as disaster recovery (DR) can be used with a HANA scale-out system. The cluster environment is aware of a multi-target DR setup. Failure of the third site will not trigger any cluster action. Cluster is detects the replication status of connected sites and the monitored attributed can change between SOK and SFAIL. Maximum of one system replicatiion to an HANA database outside the linux cluster is supported.
10111013
1012-
> [!NOTE]
1013-
Example of a multi-target system replication system. See [SAP documentation](https://help.sap.com/docs/SAP_HANA_PLATFORM/4e9b18c116aa42fc84c7dbfd02111aba/2e6c71ab55f147e19b832565311a8e4e.html) for further details.
1014-
[./media/sap-hana-high-availability/sap-hana-high-availability-scale-out-hsr-suse-multi-target.png]
1014+
Example of a multi-target system replication system. For further information, see [SAP documentation](https://help.sap.com/docs/SAP_HANA_PLATFORM/4e9b18c116aa42fc84c7dbfd02111aba/2e6c71ab55f147e19b832565311a8e4e.html).
1015+
![Example of a multi-target system replication system](./media/sap-hana-high-availability/sap-hana-high-availability-scale-out-hsr-suse-multi-target.png)
10151016
1016-
1. Deploy Azure resources for the third site. Depending on your requirements, a different Azure region is used for disaster recovery purposes.
1017+
1. Deploy Azure resources for the third site. Depending on your requirements, a different Azure region is often used for disaster recovery purposes.
10171018
Steps required for the HANA scale-out on third site are same as described in this document for SITE1 and SITE2, with the following exceptions:
1018-
- No load balancer for third site and no integration with cluster load balancer for VMs of third site.
1019-
- OS packages SAPHanaSR-ScaleOut, SAPHanaSR-ScaleOut-doc and OS package pattern ha_sles are _NOT_ installed on third site VMs.
1020-
- No majority maker VM for third site, since there is no cluster integration.
1021-
- NFS volume /hana/shared for third site exclusive use must be created.
1022-
- No integration into the cluster for VMs or HANA resources of the third site.
1023-
- No SAP HANA HA hooks setup for third site.
1019+
- No load balancer for third site and no integration with cluster load balancer for VMs of third site
1020+
- OS packages SAPHanaSR-ScaleOut, SAPHanaSR-ScaleOut-doc and OS package pattern ha_sles aren't installed on third site VMs
1021+
- No majority maker VM for third site, as there's no cluster integration
1022+
- NFS volume /hana/shared for third site exclusive use must be created
1023+
- No integration into the cluster for VMs or HANA resources of the third site
1024+
- No HANA HA hook setup for third site
10241025
10251026
2. With SAP HANA scale-out on third site operational, register the third site with the primary site.
1026-
In the example name SITE-DR is used for third site.
1027+
The example uses SITE-DR as the name for third site.
10271028
```bash
10281029
# Execute on the third site
10291030
su - hn1adm
10301031
# Make sure HANA is not running on the third site. If it is started, stop HANA
10311032
sapcontrol -nr 03 -function StopSystem
10321033
sapcontrol -nr 03 -function WaitforStopped 600 10
10331034
# Register the HANA third site
1034-
hdbnsutil -sr_register --name=HANA_DR --remoteHost=hana-s1-db1 --remoteInstance=03 --replicationMode=async
1035+
hdbnsutil -sr_register --name=SITE-DR --remoteHost=hana-s1-db1 --remoteInstance=03 --replicationMode=async
10351036
```
10361037
10371038
3. Verify HANA system replication shows both secondary and third site.
@@ -1056,7 +1057,7 @@ Example of a multi-target system replication system. See [SAP documentation](htt
10561057
# HANA_S2 30 4 hana-s2-db1 SWAIT S
10571058
```
10581059
1059-
Failure of the third site will not trigger any cluster action. Cluster is detects the replication status of connected sites and the monitored attributed can change between SOK and SFAIL.
1060+
Failure of the third site won't trigger any cluster action. Cluster detects the replication status of connected sites and the monitored attributed can change between SOK and SFAIL. Any tests of the takover to third/DR site or execution DR process should place the cluster resources into maintenance mode to prevent any undesired cluster actions.
10601061
10611062
If cluster parameter AUTOMATED_REGISTER="true" is set in the cluster after conclusion of testing, HANA parameter `register_secondaries_on_takeover = true` can be configured in `[system_replication]` block of global.ini on the two SAP HANA sites in the Linux cluster. Such configuration would re-register the third site after a takeover between the first two sites to keep a multi-target setup.
10621063

0 commit comments

Comments
 (0)