Sun Cluster System Administration Guide for Solaris OS

ProcedureHow to Apply a Rebooting Patch (Node)

Apply the patch to one node in the cluster at a time to keep the cluster itself operational during the patch process. With this procedure, you must first shut down the node and boot it to single-user mode by using the boot -sx or shutdown -g -y -i0command, before applying the patch.

This procedure provides the long forms of the Sun Cluster commands. Most commands also have short forms. Except for the long and short forms of the command names, the commands are identical. For a list of the commands and their short forms, see Appendix A, Sun Cluster Object-Oriented Commands.

  1. Before applying the patch, check the Sun Cluster product web site for any special preinstallation or postinstallation instructions.

  2. Become superuser or assume a role that provides solaris.cluster.admin RBAC authorization on the node to which you are applying the patch.

  3. List the resource groups and device groups on the node being patched.


    # clresourcegroup status -n node
    # cldevicegroup status -n node
    
  4. Switch all resource groups, resources, and device groups from the node being patched to other cluster members.


    # clnode evacuate -n node
    
    evacuate

    Evacuates all device groups and resource groups including all non-global zones from the specified node.

    -n node

    Specifies the node from which you are switching the resource groups and device groups.

  5. Shut down the node.


    # shutdown -g0 [-y]
     [-i0]
  6. Boot the node in noncluster, single-user mode.

    • On SPARC based systems, perform the following command:


      ok boot -sx
      
    • On x86 based system, perform the following commands:


      phys-schost# shutdown -g -y -i0
      
      Press any key to continue
    1. In the GRUB menu, use the arrow keys to select the appropriate Solaris entry and type e to edit its commands.

      The GRUB menu appears similar to the following:


      GNU GRUB version 0.95 (631K lower / 2095488K upper memory)
      +-------------------------------------------------------------------------+
      | Solaris 10 /sol_10_x86                                                  |
      | Solaris failsafe                                                        |
      |                                                                         |
      +-------------------------------------------------------------------------+
      Use the ^ and v keys to select which entry is highlighted.
      Press enter to boot the selected OS, 'e' to edit the
      commands before booting, or 'c' for a command-line.

      For more information about GRUB based booting, see Chapter 11, GRUB Based Booting (Tasks), in System Administration Guide: Basic Administration.

    2. In the boot parameters screen, use the arrow keys to select the kernel entry and type e to edit the entry.

      The GRUB boot parameters screen appears similar to the following:


      GNU GRUB version 0.95 (615K lower / 2095552K upper memory)
      +----------------------------------------------------------------------+
      | root (hd0,0,a)                                                       |
      | kernel /platform/i86pc/multiboot                                     |
      | module /platform/i86pc/boot_archive                                  |
      +----------------------------------------------------------------------+
      Use the ^ and v keys to select which entry is highlighted.
      Press 'b' to boot, 'e' to edit the selected command in the
      boot sequence, 'c' for a command-line, 'o' to open a new line
      after ('O' for before) the selected line, 'd' to remove the
      selected line, or escape to go back to the main menu.
    3. Add -sx to the command to specify that the system boot into noncluster mode.


      [ Minimal BASH-like line editing is supported. For the first word, TAB
      lists possible command completions. Anywhere else TAB lists the possible
      completions of a device/filename. ESC at any time exits. ]
      
      grub edit> kernel /platform/i86pc/multiboot -sx
    4. Press the Enter key to accept the change and return to the boot parameters screen.

      The screen displays the edited command.


      GNU GRUB version 0.95 (615K lower / 2095552K upper memory)
      +----------------------------------------------------------------------+
      | root (hd0,0,a)                                                       |
      | kernel /platform/i86pc/multiboot -sx                                  |
      | module /platform/i86pc/boot_archive                                  |
      +----------------------------------------------------------------------+
      Use the ^ and v keys to select which entry is highlighted.
      Press 'b' to boot, 'e' to edit the selected command in the
      boot sequence, 'c' for a command-line, 'o' to open a new line
      after ('O' for before) the selected line, 'd' to remove the
      selected line, or escape to go back to the main menu.-
    5. Type b to boot the node into noncluster mode.


      Note –

      This change to the kernel boot parameter command does not persist over the system boot. The next time you reboot the node, it will boot into cluster mode. To boot into noncluster mode instead, perform these steps to again to add the -sx option to the kernel boot parameter command.


  7. Apply the software or firmware patch.


    # patchadd -M patch-dir patch-id
    
    patch-dir

    Specifies the directory location of the patch.

    patch-id

    Specifies the patch number of a given patch.


    Note –

    Always defer to the instructions in the patch directory, which supersede procedures in this chapter.


  8. Verify that the patch has been installed successfully.


    # showrev -p | grep patch-id
    
  9. Reboot the node into the cluster.


    # reboot
    
  10. Verify that the patch works, and that the node and cluster are operating normally.

  11. Repeat Step 2 through Step 10 for all remaining cluster nodes.

  12. Switch resource groups and device groups as needed.

    After you reboot all the nodes, the last node rebooted will not have the resource groups and device groups online.


    # cldevicegroup switch -n node   + | devicegroup ...
    # clresourcegroup switch -n node[:zone][,...] + | resource-group ...
    
    node

    The name of the node to which you are switching the resource groups and device groups.

    zone

    The name of the non-global zone on node that can master the resource group. Specify zone only if you specified a non-global zone when you created the resource group.

  13. Check to see if you need to commit the patch software by using the scversions command.


    # /usr/cluster/bin/scversions
    

    You will see one of the following results:


    Upgrade commit is needed.
    
    Upgrade commit is NOT needed. All versions match.
  14. If a commit is needed, commit the patch software.


    # scversions -c
    

    Note –

    Running scversions will cause one or more CMM reconfigurations, depending on the situation.



Example 10–1 Applying a Rebooting Patch (Node)

The following example shows the application of a rebooting Sun Cluster patch to a node.


# clresourcegroup status -n rg1
...Resource Group     Resource
--------------     --------
rg1                rs-2
rg1                rs-3
...
# cldevicegroup status -n nodedg-schost-1
...
Device Group Name:											dg-schost-1
...
# clnode evacuate  phys-schost-2
# shutdown -g0 -y -i0
...

Boot the node in noncluster, single-user mode.


# patchadd -M /var/tmp/patches 234567-05
...
# showrev -p | grep 234567-05

...
# reboot
...
# cldevicegroup switch -n  phys-schost-1 dg-schost-1
# clresourcegroup switch -n  phys-schost-1 schost-sa-1
# scversions
Upgrade commit is needed.
# scversions -c

See Also

If you need to back out a patch, see Changing a Sun Cluster Patch.