HP-UX How to mirror a root LVM?


This is a small and simple procedure about how to mirror  vg00  on HP-UX(11.31) server. First of all before start operation please take a  backup of your system.

Step 1: Check new  disk for  mirroring

#diskinfo  /dev/rdisk/disk13

Step 2:Create  partition table  for  new  disk

#echo 3 > /tmp/partitionfile
#echo EFI 500MB >> /tmp/partitionfile
#echo HPUX 100% >> /tmp/partitionfile
#echo HPSP 400MB >> /tmp/partitionfile

Step 3: Write  partition to the disk

#idisk -wf /tmp/partitionfile /dev/rdisk/disk13

Step 4: Check the partition table

#idisk /dev/rdisk/disk13

Step 5: Check new  device

#insf -eC disk
#ioscan -efnC disk

Step 6:Initialize new EFI partition and  create directory

#efi_fsinit -d /dev/rdisk/disk13_p1
#mkboot -e -l /dev/rdisk/disk13

Step 7: Write Auto File

#echo "boot vmunix -lq" > /tmp/AUTO.lq
#efi_cp -d /dev/rdisk/disk13_p1 /tmp/AUTO.lq /EFI/HPUX/AUTO

Step 8: Create  PV and  extend  vg00

#pvcreate -B /dev/rdisk/disk13_p2
#vgextend vg00 /dev/disk/disk13_p2 [/shell]

Step 9: Mirror  all  LVs .

# vgdisplay -v vg00|grep "LV Name"
LV Name /dev/vg00/lvol1
LV Name /dev/vg00/lvol2
LV Name /dev/vg00/lvol3
LV Name /dev/vg00/lvol4
LV Name /dev/vg00/lvol5
LV Name /dev/vg00/lvol6
LV Name /dev/vg00/lvol7
LV Name /dev/vg00/lvol8
LV Name /dev/vg00/lvol9

Apply this command for all LVs show below.

#lvextend -m 1 -s /dev/vg00/lvol1 /dev/disk/disk13_p2

Step 10:Add  new  device to boot  config

#echo "l /dev/disk/disk13_p2" >> /stand/bootconf

Step 11:Sync vg00

#vgsync  vg00

 

I'm a IT Infrastructure and Operations Architect with extensive experience and administration skills and works for Turk Telekom. I provide hardware and software support for the IT Infrastructure and Operations tasks.

205 Total Posts
Follow Me