Tuesday, February 14, 2012

HPUX Integrity Software mirror procedure

This was written by a former colleague. It is better than anything else I have seen. SEP
Mirroring a Boot Disk with LVM on HP-UX 11i for HP Integrity
The following diagram shows the disk layout of a boot disk. The disk
contains a Master Boot Record (MBR) and Extensible Firmware
Interface (EFI) partition tables that point to each of the partitions. The
command is used to create the partitions (see idisk (1M)).
Figure 6-5 Example LVM Disk Layout on HP Integrity Server
Before starting the procedure, make sure that add-on product HP
MirrorDisk/UX (B5403BA) is installed. This product is an extra-cost
product available on the HP-UX 11i application release media. For
swlist -l fileset | grep -i mirror
Step 1.
Partition the disk using the idisk command and a partition description
Create a partition description file. For example:
vi /tmp/idf
In this example the partition description file contains:
HPUX 100%
an EFI partition, an HP-UX partition, and an HP Service partition.
Boot disks of earlier HP Integrity Servers may have an EFI partition
of only 100MB and may not contain the HPSP partition.
The values in the example represent a boot disk with three partitions:
Partition the disk using idisk and your partition description file:
idisk -f /tmp/idf -w /dev/rdsk/c3t1d0
To verify you can run:
idisk /dev/rdsk/c3t1d0
Step 2.
the partitions. For example:
Use the insf command with the -e option to create the device files for all
insf -e -H 0/18/1/2/
You should now have eight device files for this disk:
(This refers to the entire disk)
(This refers to the EFI partition)
(This will be the HP-UX partition)
(This refers to the Service partition)
Step 3.
Use pvcreate to make the HP-UX partition of the disk an LVMmanaged
pvcreate -B /dev/rdsk/c3t1d0s2
Step 4.
Add the disk to vg00:
vgextend vg00 /dev/dsk/c3t1d0s2
Step 5.
Place the boot files on the disk using mkboot:
mkboot -e -l /dev/rdsk/c3t1d0
Step 6.
Copy any autoboot file from the original boot disk to this one.
partition to the current directory. Make sure to use the device file
with the
Use efi_cp to copy the AUTO file from the original boot disk’s EFIs1 suffix, as it refers to the EFI partition:
efi_cp -d /dev/rdsk/cntndns1 -u /efi/hpux/auto ./AUTO
Copy the file from the current directory into the new disk’s EFI
efi_cp -d /dev/rdsk/c3t1d0s1 ./AUTO /efi/hpux/auto
Step 7.
volume group onto the desired physical volume. The logical volumes
must be extended in the same order that they are configured on the
original boot disk. Use the
determine the list of logical volumes and their order. For example:
Use the lvextend command to mirror each logical volume in the rootpvdisplay command with the -v option to
pvdisplay -v /dev/dsk/c0t0d0s2 | grep ’current.*0000$’
00000 current /dev/vg00/lvol1 00000
00038 current /dev/vg00/lvol2 00000
00550 current /dev/vg00/lvol3 00000
00583 current /dev/vg00/lvol4 00000
00608 current /dev/vg00/lvol5 00000
00611 current /dev/vg00/lvol6 00000
00923 current /dev/vg00/lvol7 00000
01252 current /dev/vg00/lvol8 00000
In this example, mirror the logical volumes as follows:
lvextend -m 1 /dev/vg00/lvol1 /dev/dsk/c3t1d0s2
lvextend -m 1 /dev/vg00/lvol2 /dev/dsk/c3t1d0s2
lvextend -m 1 /dev/vg00/lvol3 /dev/dsk/c3t1d0s2
lvextend -m 1 /dev/vg00/lv0l4 /dev/dsk/c3t1d0s2
lvextend -m 1 /dev/vg00/lvol5 /dev/dsk/c3t1d0s2
lvextend -m 1 /dev/vg00/lvol6 /dev/dsk/c3t1d0s2
lvextend -m 1 /dev/vg00/lvol7 /dev/dsk/c3t1d0s2
lvextend -m 1 /dev/vg00/lvol8 /dev/dsk/c3t1d0s2
lvextend fails with following message:
“m”: Illegal option
then HP MirrorDisk/UX is not installed.
Step 8.
Update the root volume group information:
lvlnboot -R /dev/vg00
Step 9.
disk and that the boot, root, and swap logical volumes appear to be on
both disks:
Display the BDRA. Verify that the mirrored disk is displayed as a boot
lvlnboot –v
Step 10.
Specify the mirror disk as the alternate boot path in nonvolatile memory:
setboot -a path_to_disk
Step 11.
text editor:
Add a line to /stand/bootconf for the new boot disk using vi or another
vi /stand/bootconf
l /dev/dsk/c3t1d0s2
denotes LVM.

No comments: