When you add a drive to a disk set, the volume management software repartitions the drive as follows so that the state database for the disk set can be placed on the drive.
A small portion of each drive is reserved for use by Solaris Volume Manager software. In volume table of contents (VTOC) labeled devices, slice 7 is used. In Extensible Firmware Interface (EFI) labeled devices, slice 6 is used. The remainder of the space on each drive is placed into slice 0.
Drives are repartitioned when they are added to the disk set only if the target slice is not configured correctly.
Any existing data on the drives is lost by the repartitioning.
If the target slice starts at cylinder 0, and the drive partition is large enough to contain a state database replica, the drive is not repartitioned.
Ensure that the disk set has been created. For instructions, see How to Create a Disk Set.
List the DID mappings.
phys-schost# cldevice show | grep Device
Choose drives that are shared by the cluster nodes that will master or potentially master the disk set.
Use the full DID device name, which has the form /dev/did/rdsk/dN,when you add a drive to a disk set.
In the following example, the entries for DID device /dev/did/rdsk/d3 indicate that the drive is shared by phys-schost-1 and phys-schost-2.
=== DID Device Instances === DID Device Name: /dev/did/rdsk/d1 Full Device Path: phys-schost-1:/dev/rdsk/c0t0d0 DID Device Name: /dev/did/rdsk/d2 Full Device Path: phys-schost-1:/dev/rdsk/c0t6d0 DID Device Name: /dev/did/rdsk/d3 Full Device Path: phys-schost-1:/dev/rdsk/c1t1d0 Full Device Path: phys-schost-2:/dev/rdsk/c1t1d0 …
Become owner of the disk set.
phys-schost# cldegivegroup switch -n node devicegroup
Specifies the node to take ownership of the device group.
Specifies the device group name, which is the same as the disk set name.
Add the drives to the disk set.
Use the full DID path name.
phys-schost# metaset -s setname -a /dev/did/rdsk/dN
Specifies the disk set name, which is the same as the device group name.
Adds the drive to the disk set.
Do not use the lower-level device name (cNtXdY) when you add a drive to a disk set. Because the lower-level device name is a local name and not unique throughout the cluster, using this name might prevent the metaset from being able to switch over.
Verify the status of the disk set and drives.
phys-schost# metaset -s setname
The metaset command adds the drives /dev/did/rdsk/d1 and /dev/did/rdsk/d2 to the disk set dg-schost-1.
phys-schost# metaset -s dg-schost-1 -a /dev/did/rdsk/d1 /dev/did/rdsk/d2
To repartition drives for use in volumes, go to How to Repartition Drives in a Disk Set.
Otherwise, go to How to Create an md.tab File to define metadevices or volumes by using an md.tab file.