Sun Microsystems, Inc.
spacerspacer
spacer www.sun.com docs.sun.com |
spacer
black dot
 
 
4.  Administering Global Devices, Disk-Path Monitoring, and Cluster File Systems Administering Disk Device Groups How to Change the Desired Number of Secondaries for a Device Group  Previous   Contents   Next 
   
 

ProcedureHow to List a Disk Device Group Configuration

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

There are three ways you can list disk device group configuration information.

  1. Use the SunPlex Manager GUI.

    See the SunPlex Manager online help for more information.

  1. Use scstat(1M) to list the disk device group configuration.
    % scstat -D

  • Use scconf(1M) to list the disk device group configuration.
    % scconf -p

Example--Listing the Disk Device Group Configuration By Using scstat

Using the scstat -D command displays the following information.

-- Device Group Servers --
                         Device Group      Primary             Secondary
                         ------------      -------             ---------
  Device group servers:  schost-2          -                   -
  Device group servers:  schost-1          phys-schost-2       phys-schost-3
  Device group servers:  schost-3          -                   -
-- Device Group Status --
                              Device Group      Status              
                              ------------      ------              
  Device group status:        schost-2          Offline
  Device group status:        schost-1          Online
  Device group status:        schost-3          Offline

Example--Listing the Disk Device Group Configuration By Using scconf

When using the scconf command, look for the information listed under device groups.

# scconf -p
...
Device group name: dg-schost-1
	Device group type:              SDS/SVM
	Device group failback enabled:  yes
	Device group node list:         phys-schost-2, phys-schost-3
	Device group diskset name:      dg-schost-1

ProcedureHow to Switch the Primary for a Device Group

This procedure can also be used to start (bring online) an inactive device group.

You can also bring an inactive device group online, or switch the primary for a device group, by using the SunPlex Manager GUI. See the SunPlex Manager online help for more information.

  1. Become superuser on any node of the cluster.

  2. Use scswitch(1M) to switch the disk device group primary.
    # scswitch -z -D disk-device-group -h node

    -z

    Performs the switch.

    -D disk-device-group

    Specifies the device group to switch.

    -h node

    Specifies the name of the node to switch to. This node become the new primary.

  3. Verify that the disk device group has been switched to the new primary.

    If the disk device group is properly registered, information for the new disk device group displays when using the following command.
    # scstat -D

Example--Switching the Primary for a Disk Device Group

The following example shows how to switch the primary for a disk device group and verify the change.

# scswitch -z -D dg-schost-1 -h phys-schost-1
# scstat -D

-- Device Group Servers --
                          Device Group        Primary             Secondary
                         ------------        -------             ---------
Device group servers:    dg1                 phys-schost-1       phys-schost-2
 
-- Device Group Status --
                                Device Group        Status              
                              ------------        ------              
  Device group status:        dg1                 Online

ProcedureHow to Put a Disk Device Group in Maintenance State

Putting a device group in maintenance state prevents that device group from automatically being brought online whenever one of its devices is accessed. You should put a device group in maintenance state when completing repair procedures that require that all I/O activity be acquiesced until completion of the repair. Putting a device group in maintenance state also helps prevent data lost by ensuring that a disk device group is not brought online on one node while the diskset or disk group is being repaired on another node.


Note - Before a device group can be placed in maintenance state, all access to its devices must be stopped, and all dependent file systems must be unmounted.


  1. Place the device group in maintenance state.
    # scswitch -m -D disk-device-group

  2. If the repair procedure being performed requires ownership of a diskset or disk group, manually import that diskset or disk group.

    For Solstice DiskSuite/Solaris Volume Manager:
    # metaset -C take -f -s diskset


    Caution! Caution - If you are taking ownership of a Solstice DiskSuite/Solaris Volume Manager diskset, the metaset -C take command must be used when the device group is in maintenance state. Using metaset -t will bring the device group online as part of taking ownership. If you are importing a VxVM disk group, the -t flag must be used when importing the disk group. This prevents the disk group from automatically being imported if this node is rebooted.


    For VERITAS Volume Manager:
    # vxdg -t import disk-group-name

  3. Complete whatever repair procedure you need to perform.

  4. Release ownership of the diskset or disk group.


    Caution! Caution - Before taking the disk device group out of maintenance state, you must release ownership of the diskset or disk group. Failure to do so may result in data loss.


    • For Solstice DiskSuite/Solaris Volume Manager:
      # metaset -C release -s diskset

    • For VERITAS Volume Manager:
      # vxdg deport disk-group-name

  5. Bring the disk device group online.
    # scswitch -z -D disk-device-group -h node

Example--Putting a Disk Device Group in Maintenance State

This example shows how to put disk device group dg-schost-1 into maintenance state, and remove the disk device group from maintenance state.

[Place the disk device group in maintenance state.]
# scswitch -m -D dg-schost-1
 
[If needed, manually import the diskset or disk group.]
For Solstice DiskSuite/Solaris Volume Manager:
  # metaset -C take -f -s dg-schost-1
For VERITAS Volume Manager:
  # vxdg -t import dg1
  
[Complete all necessary repair procedures.]
  
[Release ownership.]
For Solstice DiskSuite/Solaris Volume Manager:
  # metaset -C release -s dg-schost-1
For VERITAS Volume Manager:
  # vxdg deport dg1
  
[Bring the disk device group online.]
# scswitch -z -D dg-schost-1 -h phys-schost-1
 
 
 
  Previous   Contents   Next