Solaris Volume Manager Administration Guide

Maintaining Disk Sets

How to Check the Status of a Disk Set

  1. Use one of the following methods to check the status of a disk set.

    • From the Enhanced Storage tool within the Solaris Management Console, open the Disk Sets node. Right-click the Disk Set you want to monitor, then choose Properties from the menu. For more information, see the online help.

    • Use the metaset command to view disk set status.

      See metaset(1M) for more information.


      Note –

      Disk set ownership is only shown on the owning host.


Example—Checking the Status of a Specified Disk Set


red# metaset -s blue


Set name = blue, Set number = 1

Host                Owner
  idiom             Yes 

Drive               Dbase
  c1t6d0             Yes 
  c2t6d0             Yes 

The metaset command with the -s option followed by the name of the blue disk set displays status information for that disk set. By issuing the metaset command from the owning host, idiom, it is determined that idiom is in fact the disk set owner. The metaset command also displays the drives in the disk set.

The metaset command by itself displays the status of all disk sets.

How to Remove Disks from a Disk Set

To delete a disk set, you must first delete all drives from the disk set.

  1. Verify that the disk has been deleted from the disk set by using the metaset -s diskset-name command.


    # metaset -s blue
    

Example—Deleting a Disk from a Disk Set


lexicon# metaset -s blue -d c1t6d0
lexicon# metaset -s blue
 
Set name = blue, Set number = 1

Host                Owner
  lexicon            
	idiom 

Drive               Dbase
  c2t6d0             Yes 
 

This example deletes the disk from the disk set blue.

How to Take a Disk Set

  1. Use one of the following methods to take a disk set.

    • From the Enhanced Storage tool within the Solaris Management Console, open the Disk Sets node. Right-click the Disk Set you want to take, then choose Take Ownership from the menu. For more information, see the online help.

    • Use the following form of the metaset command.


      metaset -s diskset-name-t
      
    -s diskset-name

    Specifies the name of a disk set on which the metaset command will work.

    -t

    Specifies to take the disk set.

    -f

    Specifies to take the disk set forcibly.

    See the metaset(1M) man page for more information.

    When one host in a disk set takes the disk set, the other host in the disk set cannot access data on drives in the disk set.

    The default behavior of the metaset command takes the disk set for your host only if a release is possible on the other host.

    Use the -f option to forcibly take the disk set. This option takes the disk set whether or not another host currently has the set. Use this method when a host in the disk set is down or not communicating. If the other host had the disk set taken at this point, it would panic when it attempts to perform an I/O operation to the disk set.


    Note –

    Disk set ownership is only shown on the owning host.


Example—Taking a Disk Set


lexicon# metaset
...
Set name = blue, Set number = 1
 
Host                Owner
  lexicon
  idiom
...
lexicon# metaset -s blue -t
lexicon# metaset
...
Set name = blue, Set number = 1
 
Host                Owner
  lexicon                Yes
  idiom
...

In this example, host lexicon communicates with host idiom and ensures that host idiom has released the disk set before host lexicon attempts to take the set.

In this example, if host idiom owned the set blue, the “Owner” column in the above output would still have been blank. The metaset command only shows whether the issuing host owns the disk set, and not the other host.

Example—Taking a Disk Set Forcibly


# metaset -s blue -t -f

In this example, the host that is taking the disk set does not communicate with the other host. Instead, the drives in the disk set are taken without warning. If the other host had the disk set, it would panic when it attempts an I/O operation to the disk set.

How to Release a Disk Set

Releasing a disk set is useful when you perform maintenance on the physical drives in the disk set. When a disk set is released, it cannot be accessed by the host. If both hosts in a disk set release the set, neither host in the disk set can access volumes or hot spare pools defined in the set directly, although if both hosts release the set, the hosts can access the disks directly through their c*t*d* names.

  1. Check Background Information for Disk Sets.

  2. Use one of the following methods to release a disk set.

    • From the Enhanced Storage tool within the Solaris Management Console, open the Disk Sets node. Right-click the Disk Set you want to release, then choose Release Ownership from the menu. For more information, see the online help.

    • To release ownership of the disk set, use the following form of the metaset command.


      metaset -s diskset-name-r
      

      -s diskset-name

      Specifies the name of a disk set on which the metaset command will work.

      -r

      Releases ownership of a disk set. The reservation of all the disks within the disk set is removed. The volumes within the disk set are no longer accessible.

      See the metaset(1M) man page for more information.


      Note –

      Disk set ownership is only shown on the owning host.


  3. Verify that the disk set has been released on this host by using the metaset command without any options.


    # metaset
    

Example—Releasing a Disk Set


lexicon# metaset -s blue -r
lexicon# metaset -s blue
 
Set name = blue, Set number = 1

Host                Owner
  lexicon            
	idiom 

Drive               Dbase
  c1t6d0             Yes 
  c2t6d0             Yes 
 

This example shows the release of the disk set blue. Note that there is no owner of the disk set. Viewing status from host lexicon could be misleading. A host can only determine if it does or does not own a disk set. For example, if host idiom were to reserve the disk set, it would not appear so from host lexicon. Only host idiom would be able to determine the reservation in this case.

How to Delete a Host or Disk Set

Deleting a disk set requires that the disk set contains no drives and that no other hosts are attached to the disk set. Deleting the last host will destroy the disk set.

  1. Use one of the following methods to delete a host from a disk set, or to delete a disk set.

    • From the Enhanced Storage tool within the Solaris Management Console, open the Disk Sets node. Right-click the Disk Set you want to release, then choose Delete from the menu. Follow the instructions in the online help.

    • To delete the host and remove the disk set if the host removed is the last host on the disk set, use the following form of the metaset command.


      metaset -s diskset-name -d -h hostname
      

      -s diskset-name

      Specifies the name of a disk set on which the metaset command will work.

      -d

      Deletes a host from a disk set.

      -h hostname

      Specifies the name of the host to delete.


      # metaset -s blue -d idiom
      

      See the metasetmetaset(1M) man page for more information.

  2. Verify that the host has been deleted from the disk set by using the metaset command. Note that only the current (owning) host is shown. Other hosts have been deleted.


    # metaset -s blue
    Set name = blue, Set number = 1
    
    Host                Owner
      lexicon            Yes 
    
    Drive               Dbase
      c1t2d0             Yes 
      c1t3d0             Yes 
      c1t4d0             Yes 
      c1t5d0             Yes 
      c1t6d0             Yes 
      c2t1d0             Yes

Example—Deleting the Last Host from a Disk Set


lexicon# metaset -s blue -d lexicon
lexicon# metaset -s blue
 
metaset: lexicon: setname "blue": no such set 

This example shows the deletion of the last host from the disk set blue.