Sun Cluster 3.0 U1 System Administration Guide

Chapter 4 Administering Quorum

This chapter provides the procedures for administering quorum within Sun Cluster.

This is a list of the procedures in this chapter.

Most examples shown in this chapter are from a three-node cluster.

See the Sun Cluster 3.0 U1 Concepts document for a conceptual overview of quorum and quorum devices.

4.1 Administering Quorum Overview

You can use the scconf(1M) command to perform all quorum administrative procedures. In addition, you can accomplish some procedures by using the scsetup(1M) interactive utility or the SunPlex Manager GUI. Whenever possible, quorum procedures are described in this chapter using scsetup. The SunPlex Manager online help describes how to perform quorum procedures using the GUI.

If any quorum-related scconf command is interrupted or fails, the quorum configuration information can become inconsistent in the cluster configuration database. If this occurs, either rerun the command or run scconf with the reset option to reset the quorum configuration.


Note -

The scsetup(1M) utility is an interactive interface to the scconf(1M) command. When scsetup runs, it generates scconf commands. These generated commands are shown in the examples at the end of the procedures.


There are two commands that can be used to view the quorum configuration: scstat -q option and scconf -p. Most of the verification steps in this chapter use scconf, but you can substitute scstat -q if you find its output more useful.

Table 4-1 Task List: Administering Quorum

Task 

For Instructions, Go To... 

Add a quorum device to a cluster 

    - Use scsetup

"4.1.1 How to Add a Quorum Device"

Remove a quorum device from a cluster 

    - Use scsetup (to generate scconf)

"4.1.2 How to Remove a Quorum Device"

Remove the last quorum device from a cluster 

    - Use scsetup (to generate scconf)

"4.1.3 How to Remove the Last Quorum Device From a Cluster"

Replace a quorum device in a cluster 

    - Use the add and remove procedures 

"4.1.4 How to Replace a Quorum Device"

Put a quorum device into maintenance state 

(While in maintenance state, the quorum device does not participate in voting to establish the quorum.) 

    - Use scsetup (to generate scconf)

"4.1.5 How to Put a Quorum Device Into Maintenance State"

Reset the quorum configuration to its default state 

    - Use scsetup (to generate scconf)

"4.1.6 How to Bring a Quorum Device Out of Maintenance State"

List the quorum devices and vote counts 

    - Use scconf

"4.1.7 How to List the Quorum Configuration"

4.1.1 How to Add a Quorum Device

You can also accomplish this procedure by using the SunPlex Manager GUI. See the SunPlex Manager online help for more information.

To complete this procedure, identify a disk drive by its device ID (DID), which is shared by the nodes. Use the scdidadm -L command to see the list of DID names. Refer to the scdidadm(1M) man page for additional information.

See the scsetup(1M) and scconf(1M) man pages for information on the commands used in this procedure.

  1. Become superuser on any node of the cluster.

  2. Enter the scsetup utility.


    # scsetup
    

    The Main Menu is displayed.

  3. To work with quorum devices, type 1 (Quorum).

    The Quorum Menu is displayed.

  4. To add a quorum device, type 1 (Add a quorum disk).

    Follow the instructions and type the name of the device to be used as the quorum device.

  5. Verify that the quorum device has been added.


    # scstat -q 
    

  6. Repeat Step 3 through Step 5 for each group of nodes that shares a storage enclosure.

4.1.1.1 Example--Adding a Quorum Device

The following example shows the scconf command generated by scsetup when it adds a quorum device and a verification step.


Become superuser on any cluster node.
[Execute the scsetup utility:]
# scsetup
Select Quorum>Add a quorum disk.
Answer the questions when prompted.
[Verify that the scconf command completed successfully:]
 
scconf -a -q globaldev=d20
 
    Command completed successfully.
Quit the scsetup Quorum Menu and Main Menu.
[Verify the quorum device is removed:]
# scstat -q
 
-- Quorum Summary --
 
  Quorum votes possible: 4
  Quorum votes needed:   3
  Quorum votes present:  4
 
-- Quorum Votes by Node --
 
                    Node Name           Present Possible Status
                    ---------           ------- -------- ------
  Node votes:       phys-schost-1       1        1       Online
  Node votes:       phys-schost-2       1        1       Online
 
-- Quorum Votes by Device --
 
                 Device Name         Present Possible Status
                 -----------         ------- -------- ------
  Device votes:  /dev/did/rdsk/d3s2  1        1       Online
  Device votes:  /dev/did/rdsk/d4s2  1        1       Online

4.1.2 How to Remove a Quorum Device

You can also accomplish this procedure by using the SunPlex Manager GUI. See the SunPlex Manager online help for more information.

When a quorum disk is removed, it no longer participates in the voting to establish quorum. Note that all two-node clusters require that at least one quorum device be configured. If this is the last quorum device on a cluster, scconf(1M) will fail to remove the device from the configuration.


Note -

If the device you intend to remove is the last quorum device in the cluster, see the procedure "4.1.3 How to Remove the Last Quorum Device From a Cluster".


  1. Become superuser on any node in the cluster.

  2. Determine the quorum device to be removed.


    # scconf -pv | grep Quorum
    

  3. Execute the scsetup(1M) utility.


    # scsetup
    

    The Main Menu is displayed.

  4. To work with the quorum device, type 1 (Quorum).

  5. To remove the quorum device, type 2 (Remove a quorum disk).

    Answer the questions displayed during the removal process.

  6. Quit scsetup.

  7. Verify that the quorum device is removed.


    # scstat -q
    

4.1.2.1 Example--Removing a Quorum Device

This example shows how to remove a quorum device from a cluster with two or more quorum devices configured.


Become superuser on any node and place the node to be removed in maintenance state.
[Determine the quorum device to be removed:]
# scconf -pv | grep Quorum
[Execute the scsetup utility:]
# scsetup
Select Quorum>Remove a quorum disk.
Answer the questions when prompted.
[Verify that the scconf command completed successfully:]
 
scconf -r -q globaldev=d4
 
    Command completed successfully.
Quit the scsetup Quorum Menu and Main Menu.
[Verify the quorum device is removed:]
# scstat -q
 
-- Quorum Summary --
 
  Quorum votes possible:      3
  Quorum votes needed:        2
  Quorum votes present:       3
 
-- Quorum Votes by Node --
 
                    Node Name           Present Possible Status
                    ---------           ------- -------- ------
  Node votes:       phys-schost-1       1        1       Online
  Node votes:       phys-schost-2       1        1       Online
 
-- Quorum Votes by Device --
 
                 Device Name         Present Possible Status
                 -----------         ------- -------- ------
  Device votes:  /dev/did/rdsk/d3s2  1        1       Online

4.1.3 How to Remove the Last Quorum Device From a Cluster

If the device you intend to remove is not the last quorum device in the cluster, use the previous procedure, "4.1.2 How to Remove a Quorum Device".


Note -

All two-node clusters require at least one configured quorum device. If this is the last quorum device on a two-node cluster, the cluster must be placed into install mode before scconf(1M) allows you to remove the device from the configuration. This should only be done if a node is being removed from the cluster.


  1. Become superuser on any node in the cluster and place the node to be removed in maintenance state.

    See "6.1.7 How to Put a Node Into Maintenance State".

  2. Place the cluster in install mode.


    # scconf -c -q installmode
    

  3. Remove the quorum device using the scconf command.


    # scconf -r -q globaldev=device
    

  4. Verify that the quorum device has been removed.


    # scstat -q
    

4.1.3.1 Example--Removing the Last Quorum Device

This example shows how to remove the last remaining quorum device in a cluster configuration.


[Become superuser on any node.]
[Place the cluster in install mode:]
# scconf -c -q installmode
[Remove the quorum device:]
# scconf -r -q globaldev=d3
[Verify the quorum device has been removed:]
# scstat -q
 
-- Quorum Summary --
 
  Quorum votes possible:      2
  Quorum votes needed:        2
  Quorum votes present:       2
 
-- Quorum Votes by Node --
 
                    Node Name           Present Possible Status
                    ---------           ------- -------- ------
  Node votes:       phys-schost-1       1        1       Online
  Node votes:       phys-schost-2       1        1       Online
 
-- Quorum Votes by Device --
 
                    Device Name         Present Possible Status
                    -----------         ------- -------- ------

4.1.4 How to Replace a Quorum Device

  1. Configure a new quorum device on the storage enclosure that currently includes the disk to be replaced.

    You need to first add a new quorum device to the configuration to take the place of the old device. See "4.1.1 How to Add a Quorum Device" to add a new quorum device to the cluster.

  2. Remove the failed disk as a quorum device.

    See "4.1.2 How to Remove a Quorum Device" to remove the old quorum device from the configuration.

  3. Replace the failed disk.

    Refer to the hardware procedures for your disk enclosure in the Sun Cluster 3.0 U1 Hardware Guide.

4.1.5 How to Put a Quorum Device Into Maintenance State

You can also accomplish this procedure by using the SunPlex Manager GUI. See the SunPlex Manager online help for more information.

Put a quorum device into maintenance state when taking the quorum device out of service for an extended period of time. This way, the disk device's quorum vote count is set to zero and does not contribute to the quorum count while the device is being serviced.

Use the scconf(1M) command to put a quorum device into maintenance state. The scsetup utility does not currently have this capability.


Note -

All two-node clusters require at least one configured quorum device. If this is the last quorum device on a two-node cluster, scconf will fail to put the device into maintenance state.


To put a cluster node into maintenance state, see "6.1.7 How to Put a Node Into Maintenance State".

  1. Become superuser on any node of the cluster.

  2. Put the quorum device into the maintenance state.


    # scconf -c -q globaldev=device,maintstate
    

    -c

    Specifies the change form of the scconf command.

    -q

    Manages the quorum options.

    globaldev=device

    Specifies the DID name of the disk device to change, for example, d4.

    maintstate

    Puts the shared quorum device into maintenance state.

  3. Verify that the quorum device is now in maintenance state.

    The output for the device you placed in maintenance state should read zero for the Quorum Device Votes.


    # scconf -p | grep -i quorum
    

4.1.5.1 Example--Putting a Quorum Device Into Maintenance State

The following example shows how to put a quorum device into maintenance state and how to verify the results.


# scconf -c -q globaldev=d20,maintstate
# scconf -p | grep -i quorum
  Node quorum vote count:                          1
  Node quorum vote count:                          1
Quorum devices:                                    d20
Quorum device name:                                d20
  Quorum device votes:                             0
  Quorum device enabled:                           no
  Quorum device name:                              /dev/did/rdsk/d20s2
  Quorum device hosts (enabled):                   phys-schost-2 phys-schost-3
  Quorum device hosts (disabled): 

4.1.5.2 Where to Go From Here

To re-enable the quorum device, see "4.1.6 How to Bring a Quorum Device Out of Maintenance State".

To put a node into maintenance state, see "6.1.7 How to Put a Node Into Maintenance State".

4.1.6 How to Bring a Quorum Device Out of Maintenance State

After a quorum device has been in maintenance state, and is being brought back online, use the following procedure to reset the quorum vote count to the default. For cluster nodes, the default quorum count is one. For quorum devices, the default quorum count is N-1, where N is the number of nodes with non-zero vote counts that have ports to the quorum device.

You should run this procedure any time a quorum device has been put into maintenance state and you are bringing it out of maintenance state.


Caution - Caution -

If you do not specify either the globaldev or node options, the quorum count is reset for the entire cluster.


To bring a cluster node as well as its associated quorum devices out of maintenance state, see "6.1.8 How to Bring a Node Out of Maintenance State".

  1. Become superuser on any node of the cluster.

  2. Reset the quorum count.


    # scconf -c -q globaldev=device,reset
    

    -c

    Specifies the change form of the scconf command.

    -q

    Manages the quorum options.

    globaldev=device

    Specifies the DID name of the quorum device to reset, for example, d4.

    reset

    The change flag that resets quorum.

  3. If you are resetting the quorum count because a node was in maintenance state, reboot the node.

  4. Verify the quorum vote count.


    # scconf -p | grep -i quorum
    

4.1.6.1 Example--Resetting the Quorum Vote Count (Quorum Device)

The following example resets the quorum count for a quorum device back to the default and verifies the result.


# scconf -c -q globaldev=d20,reset
# scconf -p | grep -i quorum
  Node quorum vote count:                          1
  Node quorum vote count:                          1
Quorum devices:                                    d20
Quorum device name:                                d20
  Quorum device votes:                             1
  Quorum device enabled:                           yes
  Quorum device name:                              /dev/did/rdsk/d20s2
  Quorum device hosts (enabled):                   phys-schost-2 phys-schost-3
  Quorum device hosts (disabled): 

4.1.7 How to List the Quorum Configuration

You can also accomplish this procedure by using the SunPlex Manager GUI. See the SunPlex Manager online help for more information.

You do not need to be superuser to list the quorum configuration.

    Use scconf(1M) to list the quorum configuration.


    # scconf -p | grep -i quorum
    

4.1.7.1 Example--Listing the Quorum Configuration


# scconf -p | grep "Quorum | vote"
 Node quorum vote count:                           1
 Node quorum vote count:                           1
Quorum devices:                                    d20
Quorum device name:                                d20
  Quorum device votes:                             1
  Quorum device enabled:                           yes
  Quorum device name:                              /dev/did/rdsk/d20s2
  Quorum device hosts (enabled):                   phys-schost-2 phys-schost-3
  Quorum device hosts (disabled):