Unsupported content

 

This version of the documentation is no longer supported. However, the documentation is available for your convenience. You will not be able to leave comments.

Configuring BMC Network Automation for HA

This topic provides instructions for configuring BMC Network Automation for high availability (HA).

Before you begin

To configure BMC Network Automation for HA, you can use any clustering technology and you can configure it accordingly with the help of your cluster administrator.

To configure the BMC Network Automation service as a generic service on a Windows cluster

To support BMC Network Automation installation in an HA environment, you must add the BMC Network Automation web service to the clustered application generic services.

  1. In the Microsoft Failover Cluster Manager, right-click Services and applications, and then click Configure a Service or Application from the left navigation pane.


                                                           
  2. In the High Availability Wizard: Before you Begin panel, click Next.
  3. In the Select Service or Application panel, select Generic Service, and click Next.

                     
  4. In the Select Service panel, select the BCA-Networks Web Server web service, and click Next.

  5. In the Client Access Point panel, perform the following substeps, and click Next.


    1. Specify a name for the web service that clients will use when accessing the service, for example BNA
    2. Select a network, and then add a new virtual IP address to which the service would be assigned and running on the cluster.

  6. In the Select Storage panel, do not select a shared volume, and click Next.

  7. Click Next until the Configure High Availability panel appears appears.
  8. Click Finish to complete the configuration.

    After the service is created, add the shared disk to the created generic service.
  9. Right-click the newly created service, for example, BNA, and then click Add Storage.

  10. In the Add Storage panel, select a shared volume that you want to add, and click Next.

  11. (Optional) Right-click the newly created service, for example, BNA, click Add a Resource, and then click Generic Service.

  12. In the Select Service panel, select the BCA-Networks TFTP Server web service, and click Next.
  13. Click Finish to complete adding the service.

Back to top

To configure BMC Network Automation service as a generic service on a Linux cluster

  1. Run the system-config-cluster command to open the Cluster Configuration console or the web-based console for Cluster Configuration. For example, https://hostname:<port>.
  2. Add the relevant nodes that make up the cluster and specify the host names for the primary and secondary servers.
  3. Add the failover domain with the Virtual Cluster host name.
  4. Add the following resources:
    1. Shared disk, for example, GFS

    2. Virtual IP address to which the service would be assigned and running on the cluster

  5. Add a new service under the Service Groups tab as shown in the following figure:

  6. Add the resources added in step 4 to the newly created service.
  7. Verify whether the /etc/cluster/cluster.conf file is created.

     Click here to view a sample cluster.conf file.
    <?xml version="1.0"?>
    <cluster config_version="9" name="cdl-lnx-clust">
        <clusternodes>
            <clusternode name="cdl-lnx-clust1" nodeid="1"/>
            <clusternode name="cdl-lnx-clust2" nodeid="2"/>
        </clusternodes>
        <rm>
            <failoverdomains>
                <failoverdomain name="cdl-lnx-clust" ordered="1">
                    <failoverdomainnode name="cdl-lnx-clust1" priority="1"/>
                    <failoverdomainnode name="cdl-lnx-clust2" priority="2"/>
                </failoverdomain>
            </failoverdomains>
            <resources>
                <clusterfs device="/dev/sdb" fsid="56449" fstype="gfs2" mountpoint="/gfs" name="gfs2"/>
                <ip address="10.129.180.60" sleeptime="10"/>
            </resources>
            <service autostart="0" domain="cdl-lnx-clust" name="cdl-lnx-clust" recovery="relocate">
                <clusterfs ref="gfs2"/>
                <ip ref="10.129.180.60"/>
            </service>
        </rm>
        <cman expected_votes="1" two_node="1"/>
    </cluster>
  8. Power off the cluster virtual machines (VMs).
  9. Power on the cluster VMs.
  10. Verify the cluster status by using either of the following methods:

    1. By executing the following command on any node:

      clustat \- verify cluster status
      
    2. By using the web-based console for Cluster Configuration as shown in the following figure:

  11. Move the cluster to the other node by using either of the following methods:

    1. By executing the following command on any node:

      clusvcadm \-r gfs \-m <Secondary Node/Primary Node>
      
    2. By using the web-based console for Cluster Configuration as shown in the following figure:

  12. Add the shell script, which automatically triggers the BMC Network Automation service on and off when failover occurs to the shared disk.

     Click here to view an example shell script for a BMC Network Automation server.
    #! /bin/bash
    # ---------------------------------------------------------------------------
    # Script to stop/start and give a status of ftp service in the cluster.
    # This script is build to receive 3 parameters.
    #    - start :  Executed by cluster to start the application(s) or service(s)
    #    - stop  :  Executed by cluster to stop  the application(s) or service(s)
    #    - status:  Executed by cluster every 30 seconds to check service status.
    # ---------------------------------------------------------------------------
    # ---------------------------------------------------------------------------
    #set -x
    FsDIR="/gfs"                           ; export FsDIR     # Root directory for Services
    ScDIR="$FsDIR/service_startup"         ; export ScDIR     # Service Scripts Directory
    ScName="startservice"                  ; export ScName    # Service ScNameance Name
    LOG="$ScDIR/log/${ScName}.log"         ; export LOG       # Service Log file name
    HOSTNAME=`hostname -a`                 ; export HOSTNAME  # HostName
    SePath="/etc/init.d/enatomcat"         ; export SePath    # Service Program name
    ScTxt=“/opt/bmc/bca-networks/java/bin/java" ; export ScTxt   
    # Service Config. file name
    RC=0                                   port RC       # Service Return Code
    DASH="---------------------"           ; export DASH     # Dash Line
    # Where the Action Start
    # ---------------------------------------------------------------------------
    case "$1" in
      start)
              echo -e "\n${DASH}" >> $LOG 2>&1
              echo -e "Starting service $SePath on $HOSTNAME at `date`" >>
              $LOG 2>&1
              echo -e "${SePath}" >> $LOG 2>&1
              ${SePath} start >> $LOG 2>&1
              RC=$?
              FPID=`ps -ef |grep -v grep |grep ${ScTxt} |awk '{ print $2 }'|
              head -1`
              echo "Service $SePath started on $HOSTNAME - PID=${FPID} RC=$RC">>
              $LOG
              echo "${DASH}" >> $LOG 2>&1
              ;;
      stop )
              echo -e "\n${DASH}" >> $LOG 2>&1
              echo -e "Stopping Service $SePath on $HOSTNAME at `date` " >>
              $LOG
              ps -ef | grep ${ScTxt}| grep -v grep >> $LOG 2>&1
              FPID=`ps -ef |grep -v grep |grep ${ScTxt} |awk '{ print $2 }
              '|head -1`
              echo -e "Killing PID ${FPID}" >> $LOG 2>&1
              kill $FPID  >> $LOG 2>&1
              echo -e "Service $SePath is stopped ..." >> $LOG 2>&1
              RC=0
              echo "${DASH}" >> $LOG 2>&1
              ;;
      status)
              COUNT=`ps -ef | grep ${ScTxt}| grep -v grep | wc -l`
              FPID=`ps -ef |grep -v grep |grep ${ScTxt} |awk '{ print $2 }
              '|head -1`
              echo -n "`date` Service $SePath ($COUNT) on $HOSTNAME">> 
              $LOG 2>&1
              if [ $COUNT -gt 0 ]
                 then echo " - PID=${FPID} - OK"  >> $LOG 2>&1
                      RC=0
                 else echo " - NOT RUNNING" >> $LOG 2>&1
                      ps -ef | grep -i ${ScTxt} | grep -v grep  >> $LOG 2>&1
                      RC=1
              fi
              ;;
    esac
    exit $RC
     Click here to view an example shell script for a BMC Network Automation agent.
    #! /bin/bash
    # ---------------------------------------------------------------------------
    # Script to stop/start and give a status of ftp service in the cluster.
    # This script is build to receive 3 parameters.
    #    - start :  Executed by cluster to start the application(s) or service(s)
    #    - stop  :  Executed by cluster to stop  the application(s) or service(s)
    #    - status:  Executed by cluster every 30 seconds to check service status.
    # ---------------------------------------------------------------------------
    # ---------------------------------------------------------------------------
    #set -x
    FsDIR="/gfs"                           ; export FsDIR     # Root directory for Services
    ScDIR="$FsDIR/service_startup"         ; export ScDIR     # Service Scripts Directory
    ScName="startservice"                  ; export ScName    # Service ScNameance Name
    LOG="$ScDIR/log/${ScName}.log"         ; export LOG       # Service Log file name
    HOSTNAME=`hostname -a`                 ; export HOSTNAME  # HostName
    SePath="/etc/init.d/bcanagent"         ; export SePath    # Service Program name
    ScTxt="java"                 ; export ScTxt       # Service Config. file name "java"
    RC=0                                   port RC            # Service Return Code
    DASH="---------------------"           ; export DASH      # Dash Line
    # Where the Action Start
    # ---------------------------------------------------------------------------
    case "$1" in
      start)
              echo -e "\n${DASH}" >> $LOG 2>&1
              echo -e "Starting service $SePath on $HOSTNAME at `date`" >>
              $LOG 2>&1
              echo -e "${SePath}" >> $LOG 2>&1
              ${SePath} start >> $LOG 2>&1
              RC=$?
              FPID=`ps -ef |grep -v grep |grep ${ScTxt} |awk '{ print $2 }
              '|head -1`
              echo "Service $SePath started on $HOSTNAME - PID=${FPID} RC=$RC">>
              $LOG
              echo "${DASH}" >> $LOG 2>&1
              ;;
      stop )
              echo -e "\n${DASH}" >> $LOG 2>&1
              echo -e "Stopping Service $SePath on $HOSTNAME at `date` " >>
              $LOG
              ps -ef | grep ${ScTxt}| grep -v grep >> $LOG 2>&1
              FPID=`ps -ef |grep -v grep |grep ${ScTxt} |awk '{ print $2 }
              '|head -1`
              echo -e "Killing PID ${FPID}" >> $LOG 2>&1
              kill $FPID  >> $LOG 2>&1
              echo -e "Service $SePath is stopped ..." >> $LOG 2>&1
              RC=0
              echo "${DASH}" >> $LOG 2>&1
              ;;
      status)
              COUNT=`ps -ef | grep ${ScTxt}| grep -v grep | wc -l`
              FPID=`ps -ef |grep -v grep |grep ${ScTxt} |awk '{ print $2 }
              '|head -1`
              echo -n "`date` Service $SePath ($COUNT) on $HOSTNAME">>
              $LOG 2>&1
              if [ $COUNT -gt 0 ]
                 then echo " - PID=${FPID} - OK"  >> $LOG 2>&1
                      RC=0
                 else echo " - NOT RUNNING" >> $LOG 2>&1
                      ps -ef | grep -i ${ScTxt} | grep -v grep  >> $LOG 2>&1
                      RC=1
              fi
              ;;
    esac
    exit $RC
  13. Perform the following tasks to add the script as a resource:

    1. Select Script as the resource type.

    2. Specify a name for the script.

    3. Specify the location of the script.

  14. Add the newly added script resource to the existing service.

Back to top

To configure the Oracle RAC database

  1. Log on to the BMC Network Automation host and stop the BMC Network Automation service.
  2. From the <BMC Network Automation installation>/bca-networks-data folder, open the database.properties file.
  3. Update the javax.jdo.option.ConnectionURL property with the following value: javax.jdo.option.ConnectionURL=jdbc:oracle:thin:@cdlrac.bmc.com:1521:CDL.
  4. From the <BMC Network Automation installation>//tomcat/conf/ folder, open the server.xml file.
  5. Update the connectionURL property with the following value:
    connectionURL="jdbc:oracle:thin:@ cdlrac.bmc.com:1521:CDL
  6. From the <BMC Network Automation installation> folder, open the BcanInstalledConfiguration.xml file.
  7. Locate the following properties in the file and update their values:
    • DATABASE_PORT_NUMBERDBport
    • DATABASE_URLDBurl
  8. Start the BMC Network Automation service.

Back to top

To integrate BMC Network Automation and BMC Atrium CMDB

  1. Log on to BMC Network Automation using the cluster host name or service virtual IP address.
  2. Go to Admin> system parameter> Enable CMDB integration URLand set the following parameters:
    • Atrium Web URL — specify the BMC Atrium Web Registry URL, for example, http://AWSLoadBalancer:8080/cmdbws/server/cmdbws.
    • Enterprise AR UsernameDemo.
    • Enterprise AR Password — specify the password for the Demo user.
  3. Click Save.

Back to top

This version of the documentation is no longer supported. However, the documentation is available for your convenience. You will not be able to leave comments.

Comments