HP Serviceguard Extended Distance Cluster for Linux A.11.20.10 Deployment Guide, December 2012

ARRAY /dev/md0 metadata=1.2 name=node1.ind.hp.com:0
UUID=354b6919:e7db657c:1864a2c0:481b5f36
NOTE: Ensure that you copy the output to /etc/mdadm.conf file for each node.
Once the new RAID device, /dev/md0, is created on one of the cluster nodes, you must assemble
it on the nodes where the package must run. You create an MD device only once and you can
manage other functions using the serviceguard-xdc scripts.
To assemble the MD device, complete the following procedure:
1. Stop the MD device on the node where you created it, by running the following command:
# mdadm -S /dev/md0
2. On the other nodes, do the following:
a. Run the following command:
# mdadm -A -R /dev/md0 /dev/hpdev/sde /dev/hpdev/sdf
b. To have the name of MD device consistent across the nodes, see step 2 as described in
creating MD device.
3. Stop the MD device on the other node by running the following command:
# mdadm -S /dev/md0
You must stop the MD device soon after you assemble it on the second node.
4. If you want to create volume groups, restart the MD device on the first node by running the
following command:
# mdadm -A -R /dev/md0 /dev/hpdev/sde /dev/hpdev/sdf
5. After you have created the volume groups, stop the MD device by running the following
command:
# mdadm -S /dev/md0
IMPORTANT: You need to repeat this procedure to create all MD devices that are used in a
package.
When data is written to this device, the MD driver writes to both the underlying disks. In case of
read requests, the MD reads from one device or the other based on its algorithms. After creating
this device you treat it like any other LUN that is going to have shared data in a Serviceguard
environment and then create a logical volume and a file system on it.
3.3.4 Creating Volume Groups and Configuring VG Exclusive Activation on the MD
Mirror
Once the MD mirror device is created, you need to create volume groups and logical volumes on
it. You must use the Volume Group Exclusive activation feature. This protects against a volume
group which is already active on one node to be activated again (accidentally or on purpose) on
any other node in the cluster.
Creating the volume group and logical volume infrastructure on an MD device is similar to creating
the same on a single device. However, when you create a logical volume on an MD device, it can
be done on a physical disk (LUN) or on a partition.
For example, let us assume that /dev/sde and /dev/sdf are two physical disks that form the
md device /dev/md0. The persistent device names for /dev/sde and /dev/sdf are /dev/
hpdev/md0_mirror0 and /dev/hpdev/md0_mirror1 respectively. When you create a logical
volume, duplicate entries are detected for the two physical disks that form the mirror device. The
following message may be displayed:
24 Configuring your Environment for Software RAID