Sun Cluster Software Installation Guide for Solaris OS

How to Create an File

Create an /etc/lvm/ file on each node in the cluster. Use the file to define Solstice DiskSuite metadevices or Solaris Volume Manager volumes for the disk sets that you created.

Note –

If you are using local metadevices or volumes, ensure that local metadevices or volumes names are distinct from the device-ID names used to form disk sets. For example, if the device-ID name /dev/did/dsk/d3 is used in a disk set, do not use the name /dev/md/dsk/d3 for a local metadevice or volume. This requirement does not apply to shared metadevices or volumes, which use the naming convention /dev/md/setname/{r}dsk/d#.

Tip –

To avoid possible confusion between local metadevices or volumes in a cluster environment, use a naming scheme that makes each local metadevice or volume name unique throughout the cluster. For example, for node 1 choose names from d100-d199. And for node 2 use d200-d299.

  1. Become superuser on the cluster node.

  2. List the DID mappings for reference when you create your file.

    Use the full device-ID path names in the file in place of the lower-level device names (cNtXdY).

    # scdidadm -L

    In the following example, the first column of output is the DID instance number, the second column is the full physical path name, and the third column is the full device-ID path name (pseudo path).

    1       phys-schost-1:/dev/rdsk/c0t0d0 /dev/did/rdsk/d1
    2       phys-schost-1:/dev/rdsk/c1t1d0 /dev/did/rdsk/d2
    2       phys-schost-2:/dev/rdsk/c1t1d0 /dev/did/rdsk/d2
    3       phys-schost-1:/dev/rdsk/c1t2d0 /dev/did/rdsk/d3
    3       phys-schost-2:/dev/rdsk/c1t2d0 /dev/did/rdsk/d3

  3. Create an /etc/lvm/ file and edit it by hand with your preferred text editor.

    See your Solstice DiskSuite or Solaris Volume Manager documentation and the man page for details on how to create an file.

    Note –

    If you have existing data on the drives that will be used for the submirrors, you must back up the data before metadevice or volume setup. Then restore the data onto the mirror.

  4. Activate the metadevices or volumes that are defined in the files.

    Go to How to Activate Metadevices or Volumes.

Example—Sample File

The following sample file defines the disk set that is named dg-schost-1. The ordering of lines in the file is not important.

dg-schost-1/d0 -m dg-schost-1/d10 dg-schost-1/d20
    dg-schost-1/d10 1 1 /dev/did/rdsk/d1s0
    dg-schost-1/d20 1 1 /dev/did/rdsk/d2s0

The following example uses Solstice DiskSuite terminology. For Solaris Volume Manager, a trans metadevice is instead called a transactional volume and a metadevice is instead called a volume. Otherwise, the following process is valid for both volume managers.

The sample file is constructed as follows.

  1. The first line defines the device d0 as a mirror of metadevices d10 and d20. The -m signifies that this device is a mirror device.

    dg-schost-1/d0 -m dg-schost-1/d0 dg-schost-1/d20

  2. The second line defines metadevice d10, the first submirror of d0, as a one-way stripe.

    dg-schost-1/d10 1 1 /dev/did/rdsk/d1s0

  3. The third line defines metadevice d20, the second submirror of d0, as a one-way stripe.

    dg-schost-1/d20 1 1 /dev/did/rdsk/d2s0