No relevant resource is found in the selected language.

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>Search

Reminder

To have a better experience, please upgrade your IE browser.

upgrade

Huawei SAP HANA Appliance Two Node Installation Guide (RH5885H and RH8100 V3+Redhat) 09

Rate and give feedback :
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document. Note: Even the most advanced machine translation cannot match the quality of professional translators. Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
Configuring Resources for Red Hat 7.2 Cluster HA

Configuring Resources for Red Hat 7.2 Cluster HA

  1. Run the following commands on the active node to configure basic HA resource parameters:

    [root@HW00001 hdbclient]# pcs property set no-quorum-policy="stop"
    [root@HW00001 hdbclient]# pcs resource defaults default-resource-stickness=1000
    [root@HW00001 hdbclient]# pcs resource defaults default-migration-threshold=5000
    [root@HW00001 hdbclient]# pcs resource op defaults timeout=600s
    [root@HW00001 hdbclient]#

  2. Run the following commands in yellow on the active node to configure the stonith resource instance, and set ipaddr, login, passwd, and pcmk_host_list for external/ipmi. When a split brain occurs, the remote server is restarted by the IPMI.

    [root@HW00001 hdbclient]# pcs stonith create st_ipmi_hw00001 fence_ipmilan \
    ipaddr=192.168.40.22 \
    lanplus=on \
    login="root" \
    passwd="Huawei12#$" \
    pcmk_host_list="HW00001"
    [root@HW00001 hdbclient]# pcs stonith create st_ipmi_hw00002 fence_ipmilan \
    > ipaddr=192.168.40.24 \
    >lanplus=on \
    >  login="root" \
    >  passwd="Huawei12#$" \
    >  pcmk_host_list="HW00002"
    NOTE:

    Run pcs stonith create st_ipmi_hw00001 fence_ipmilan to generate the stonith resource named st_ipmi_hw00001. Set the resource name based on the actual host name. fence_ipmilan indicates that the port type is ipmilan. Set ipaddr to the BMC IP address of the local node. In this example, the BMC IP address of node HW00001 is 192.168.40.22. Set login and passwd to the username and password for logging in to the BMC, respectively. pcmk_host_list indicates the host name of a resource, for example, the host name of st_ipmi_hw00001 is HW00001.

  3. Run the following commands to create stonith constraints:

    [root@HW00001 hdbclient]# pcs constraint location st_ipmi_hw00001 avoids HW00001
    [root@HW00001 hdbclient]# pcs constraint location st_ipmi_hw00002 avoids HW00002
    NOTE:

    Run pcs constraint location st_ipmi_hw00001 avoids HW00001 to prevent resource st_ipmi_hw00001 from running on node HW00001, and pcs constraint location st_ipmi_hw00002 avoids HW00002 to prevent resource st_ipmi_hw00002 from running on node HW00002.

  4. Run pcs status to check whether the stonith resource is successfully configured.

    [root@HW00001 hdbclient]# pcs status
    Cluster name: hacluster
    Last updated: Thu Oct 22 20:54:04 2015
    Last change: Thu Oct 22 20:54:02 2015
    Stack: cman
    Current DC: HW00001 - partition with quorum
    Version: 1.1.11-97629de
    2 Nodes configured
    2 Resources configured
    
    
    Online: [ HW00001 HW00002 ]
    
    Full list of resources:
    
     st_ipmi_hw00001        (stonith:fence_ipmilan):        Started HW00002
     st_ipmi_hw00002        (stonith:fence_ipmilan):        Started HW00001

  5. Check BMC IPMI connections of the cluster.

    On the OS of the active node, use the ipmitool to connect the BMC of the standby node and view the power status.

    On the OS of the standby node, use the ipmitool to connect the BMC of the active node and view the power status.

    Run ipmitool -I lanplus -H 192.168.44.43 -U root -P Huawei12#$ chassis power status on the active and standby nodes. If "Chassis Power is on" is displayed, the IPMI link is normal.

    Parameters in the command are described as follows:

    • H 192.168.44.43 indicates the BMC IP address of the remote node. Use the actual IP address in configuration.
    • U root indicates a BMC login user.
    • P Huawei12#$ indicates the default password for logging in to the BMC. Use the new password if the password has been reset.

    The following is an example:

    hw00001:~ # ipmitool -I lanplus -H 192.168.44.43 -U root -P Huawei12#$ chassis power status
    Chassis Power is on
    hw00002:~ # ipmitool -I lanplus -H 192.168.44.41 -U root -P Huawei12#$ chassis power status
    Chassis Power is on

  6. Run the following command in yellow to configure a virtual IP address:

    [root@HW00001 hdbclient]# pcs resource create rsc_ip_SAPHana_S00_HDB00 IPaddr2 \
    >ip="10.5.1.12" \
    >iflabel=0
     [root@HW00001 hdbclient]#
    NOTE:

    rsc_ip_SAPHana_S00_HDB00 indicates the resource name of the virtual IP address in the format of rsc_ip_SAPHana_<SID>_HDB00. The SID is set to S00 in this example. Set the SID based on actual situations. The virtual IP address and service IP address must be in the same network segment.

  7. Run the following commands in yellow on the active node to generate a SAPHanaTopology resource:

    [root@HW00001 hdbclient]# pcs resource create rsc_SAPHanaTopology_S00_HDB00 SAPHanaTopology \
    > SID=S00 \
    > InstanceNumber=00 \
    > op start timeout=600 \
    > op stop timeout=300 \
    > op monitor interval=10 timeout=600
    [root@HW00001 hdbclient]#
    NOTE:

    pcs resource create rsc_SAPHanaTopology_S00_HDB00 indicates that the resource named rsc_SAPHanaTopology_S00_HDB00 is generated. The resource name is in the format of rsc_SAPHanaTopology_<SID>_HDB00. The SID is set to S00 in this example. Set the SID based on actual situations. InstanceNumber indicates a database instance number and is set to 00 in this example.

  8. Run the following commands in yellow on the active node to generate a clone resource:

    [root@HW00001 hdbclient]# pcs resource clone rsc_SAPHanaTopology_S00_HDB00 \
    > meta is-managed=true clone-node-max=1 target-role="Started" interleave=true
    [root@HW00001 hdbclient]#
    NOTE:

    rsc_SAPHanaTopology_S00_HDB00 indicates a clone resource name in the format of rsc_SAPHanaTopology_<SID>_HDB00. The SID is set to S00 in this example. Set the SID based on actual situations.

  9. Run the following commands in yellow on the active node to generate a SAP HANA Master&Slave resource:

    [root@HW00001 hdbclient]# pcs resource create rsc_SAPHana_S00_HDB00 SAPHana \
    > SID=S00 \
    > InstanceNumber=00 \
    PREFER_SITE_TAKEOVER=true \
    DUPLICATE_PRIMARY_TIMEOUT=7200 \
    AUTOMATED_REGISTER=false \
    op start timeout=3600 \
    op stop timeout=3600 \
    op promote timeout=3600 \
    op demote timeout=3600 \
    op monitor interval=59 role="Master" timeout=700 \
    op monitor interval=61 role="Slave" timeout=700
    [root@HW00001 hdbclient]#
    NOTE:
    • rsc_SAPHana_S00_HDB00 indicates a SAP HANA resource name in the format of rsc_SAPHana_<SID>_HDB00. Set the SID based on actual situations.
    • PREFER_SITE_TAKEOVER specifies whether to enable the automatic takeover function. It is enabled in this example. DUPLICATE_PRIMARY_TIMEOUT indicates the timeout period of an SR failover. AUTOMATED_REGISTER specifies whether to enable the automatic registration function. It is disabled in this example.

  10. Run the following commands in yellow on the active node to generate active and standby resources:

    [root@HW00001 hdbclient]# pcs resource master msl_rsc_SAPHana_S00_HDB00 rsc_SAPHana_S00_HDB00 \
    > meta is-managed=true notify=true clone-max=2 clone-node-max=1 \
    > target-role="Started" interleave=true
    [root@HW00001 hdbclient]#
    NOTE:

    The SID is set to S00 in this example. Set the SID based on actual situations.

  11. Run the following commands in yellow on the active node to create active and standby resource constraints:

    [root@HW00001 hdbclient]# pcs constraint colocation add rsc_ip_SAPHana_S00_HDB00 with master msl_rsc_SAPHana_S00_HDB00 2000                                                      
    [root@HW00001 hdbclient]# pcs constraint order rsc_SAPHanaTopology_S00_HDB00-clone then msl_rsc_SAPHana_S00_HDB00 symmetrical=false
    Adding rsc_SAPHanaTopology_S00_HDB00-clone msl_rsc_SAPHana_S00_HDB00 (kind: Mandatory) (Options: symmetrical=false first-action=start then-action=start)
    [root@HW00001 hdbclient]#
    NOTE:

    The SID is set to S00 in this example. Set the SID based on actual situations.

  12. Create uplink port resource , by running pcs resource create bond1-monitor ethmonitor interface=bond1 --clone ,the uplink port is set to bond1 in this example , Set the port name based on actual situations.
  13. Create the constraint by running pcs constraint location rsc_ip_SAPHana_S00_HDB00 rule score=-INFINITY ethmonitor-bond1 ne 1 , the uplink port is set to bond1 in this example ,and the Vip name is set to Set the port name based on actual situations.
  14. Enable autostart of pacemaker on two nodes.

    systemctl enable pcsd.service
    systemctl enable corosync.service
    systemctl enable pacemaker.service

  15. Run pcs resource cleanup to get the current status of HA resource;

    pcs resource cleanup

  16. Wait 5 minute , run pcs status to query the HA status.

    [root@hw00001 exe]# pcs status
    Cluster name: hacluster
    Last updated: Thu Aug 11 17:00:42 2016          Last change: Thu Aug 11 16:59:42 2016 by root via crm_attribute on hw00001
    Stack: corosync
    Current DC: hw00001 (version 1.1.13-10.el7-44eb2dd) - partition with quorum
    2 nodes and 7 resources configured
    
    Online: [ hw00001 hw00002 ]
    
    Full list of resources:
    
     st_ipmi_hw00001       (stonith:fence_ipmilan):        Started hw00002
     st_ipmi_hw00002       (stonith:fence_ipmilan):        Started hw00001
     rsc_ip_SAPHana_S00_HDB00       (ocf::heartbeat:IPaddr2):       Started hw00002
     Clone Set: rsc_SAPHanaTopology_S00_HDB00-clone [rsc_SAPHanaTopology_S00_HDB00]
         Started: [ hw00001 hw00002 ]
     Master/Slave Set: msl_rsc_SAPHana_S00_HDB00 [rsc_SAPHana_S00_HDB00]
         Masters: [ hw00002 ]
         Slaves: [ hw00001 ]
    
    PCSD Status:
      hw00001: Online
      hw00002: Online
    
    Daemon Status:
      corosync: active/enabled
      pacemaker: active/enabled
      pcsd: active/enabled

Translation
Download
Updated: 2019-06-17

Document ID: EDOC1100019155

Views: 21049

Downloads: 99

Average rating:
This Document Applies to these Products
Related Documents
Related Version
Share
Previous Next