27.3 Adding a Node to a Package

     

In the previous example, I added a node to the cluster to give me an additional adoptive node for the clockwatch application. I will now add that node into the configuration of the clockwatch application. As we see, this follows a similar pattern to the template for adding a node to the cluster:

  • Ensure that the application binaries are loaded onto the new node, if applicable .

  • Ensure that any shared disk drives are available to the new node, e.g., vgimport , and so on.

  • Get the most up-to-date version of the ASCII configuration file ( cmgetconf ).

  • Update the ASCII configuration file.

  • Distribute the package control script to the new node.

  • Distribute any application monitoring script(s) to the new node.

  • Check the ASCII configuration file ( cmcheckconf ).

  • Compile and distribute the binary cluster configuration file ( cmapplyconf ).

  • Check that the changes have been distributed ( cmviewcl ).

Because my application binaries are on the shared disk drives, I will proceed with this checklist with the cmgetconf command.

 

 root@hpeos002[clockwatch] #  cmgetconf -v -p clockwatch clockwatch.conf  root@hpeos002[clockwatch] # root@hpeos002[clockwatch] #  vi clockwatch.conf  

The only change I made was to add the line

 

 NODE_NAME                       hpeos003 

to the list of adoptive nodes:

 

 root@hpeos003[vg01]  mkdir /etc/cmcluster/clockwatch  

Remember to create the appropriate directory on the new node.

 

 root@hpeos002[clockwatch] #  rcp -p CLOCKWATCH.sh clockwatch.cntl hpeos003:/etc/cmcluster graphics/ccc.gif /clockwatch  

Now that we have distributed (okay, so it's not the most secure method) the control script and application monitoring script(s), we can check the ASCII configuration file.

 

 root@hpeos002[clockwatch] #  cmcheckconf -v -P clockwatch.conf  Checking existing configuration ... Done Gathering configuration information ... Done Parsing package file: clockwatch.conf. Package clockwatch already exists. It will be modified. Maximum configured packages parameter is 10. Configuring 1 package(s). 9 package(s) can be added to this cluster. Modifying the package configuration for package clockwatch. Adding node hpeos003 to package clockwatch. Verification completed with no errors found. Use the cmapplyconf command to apply the configuration. root@hpeos002[clockwatch] # 

And now to compile distribute the new binary cluster configuration file.

 

 root@hpeos002[clockwatch] #  cmapplyconf -v -P clockwatch.conf  Checking existing configuration ... Done Gathering configuration information ... Done Parsing package file: clockwatch.conf. Package clockwatch already exists. It will be modified. Maximum configured packages parameter is 10. Configuring 1 package(s). 9 package(s) can be added to this cluster. Modify the package configuration ([y]/n)?  y  Modifying the package configuration for package clockwatch. Adding node hpeos003 to package clockwatch. Completed the cluster update. root@hpeos002[clockwatch] # root@hpeos002[clockwatch] #  cmviewcl -v -p clockwatch  PACKAGE      STATUS       STATE        AUTO_RUN     NODE     clockwatch   up           running      enabled      hpeos001       Policy_Parameters:       POLICY_NAME     CONFIGURED_VALUE       Failover        configured_node       Failback        manual       Script_Parameters:       ITEM       STATUS   MAX_RESTARTS  RESTARTS   NAME       Service    up                  0         0   clock_mon       Subnet     up                                192.168.0.0       Node_Switching_Parameters:       NODE_TYPE    STATUS       SWITCHING    NAME       Primary      up           enabled      hpeos001     (current)       Alternate    up           enabled      hpeos002   Alternate    up           enabled      hpeos003   root@hpeos002[clockwatch] # 

If I were being super-efficient, I would test that node hpeos003 was able to run the application properly. I could disable node hpeos002 from running clockwatch; cmmodpkg “v “d “n hpeos002 clockwatch . And then I could fail the package over using one of the Standard or Stress Tests we saw in Chapter 26. I assume that you are being conscientious and have performed all such tests with the approval of your management and user community.

When we first added a package to our cluster, we used a c ookbook approach. I am going to use the same cookbook to add a package to this cluster ”a task I can do while the cluster and other packages are running. The package I am going to add uses one of the Serviceguard Toolkits. In this instance, it is for the Oracle Toolkit.



HP-UX CSE(c) Official Study Guide and Desk Reference
HP-UX CSE(c) Official Study Guide and Desk Reference
ISBN: N/A
EAN: N/A
Year: 2006
Pages: 434

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net