Operating System - HP-UX
1827448 Members
4733 Online
109965 Solutions
New Discussion

Root Disk Mirroring on Production Servers

 
SOLVED
Go to solution
arkie
Super Advisor

Root Disk Mirroring on Production Servers

Hi,

We just observed that one of the production servers (all on HP-UX 11iv1) was mistakenly left out w.r.t. Root Disk Mirroring.

Can we do it now? What should we be careful about since downtime is not an option.

Pls guide
14 REPLIES 14
Michal Kapalka (mikap)
Honored Contributor
Solution

Re: Root Disk Mirroring on Production Servers

hi,

i use this script :

# primary disk : c2t0d0
# disk for mirroring : c2t1d0
set -x
pvcreate -B -f /dev/rdsk/c2t1d0
mkboot /dev/rdsk/c2t1d0
mkboot -a "hpux -lq" /dev/rdsk/c2t0d0
mkboot -a "hpux -lq" /dev/rdsk/c2t1d0
vgextend /dev/vg00 /dev/dsk/c2t1d0
lvextend -m 1 /dev/vg00/lvol1 /dev/dsk/c2t1d0
lvextend -m 1 /dev/vg00/lvol2 /dev/dsk/c2t1d0
lvextend -m 1 /dev/vg00/lvol3 /dev/dsk/c2t1d0
lvextend -m 1 /dev/vg00/lvol4 /dev/dsk/c2t1d0
lvextend -m 1 /dev/vg00/lvol5 /dev/dsk/c2t1d0
lvextend -m 1 /dev/vg00/lvol6 /dev/dsk/c2t1d0
lvextend -m 1 /dev/vg00/lvol7 /dev/dsk/c2t1d0
lvextend -m 1 /dev/vg00/lvol8 /dev/dsk/c2t1d0
lvlnboot -r /dev/vg00/lvol3
lvlnboot -s /dev/vg00/lvol2
lvlnboot -d /dev/vg00/lvol2
lvlnboot -b /dev/vg00/lvol1
lvlnboot -R
lvlnboot -v
setboot -a 0/1/1/0.1.0
setboot

mikap
Johnson Punniyalingam
Honored Contributor

Re: Root Disk Mirroring on Production Servers

simple Search "mirror" you will see lot of thread similar to "Mirror"

Always follow "official" HP document

http://docs.hp.com/en/5991-1236/When_Good_Disks_Go_Bad_WP.pdf
Problems are common to all, but attitude makes the difference
arkie
Super Advisor

Re: Root Disk Mirroring on Production Servers

Hi Michael,

Thanks for these useful steps.

Can we get started? Just want to know if these commands are not too resource intensive? .. since the server is in production and running on full load
Michal Kapalka (mikap)
Honored Contributor

Re: Root Disk Mirroring on Production Servers

hi,

i made it several times under production,
without any problem, but you as administrator should know if its possible or not, in my opinion, if you don't have a mirrored disks, you should do it ASAP, and also make a Ignite backup.

mikap
SUDHAKAR_18
Trusted Contributor

Re: Root Disk Mirroring on Production Servers

hi,

u guys really think about putting "hpux -lq" option on both the disks is usefull ?
arkie
Super Advisor

Re: Root Disk Mirroring on Production Servers

Hi Sudhakar,

I assume, we should be going for only:-

mkboot -a "hpux -lq (;0)/stand/vmunix" /dev/rdsk/c2t1d0

as OS is already loaded on c2t0d0
Johnson Punniyalingam
Honored Contributor

Re: Root Disk Mirroring on Production Servers

>>u guys really think about putting "hpux -lq" option on both the disks is usefull ?<<<


purpose of above said command , it will not harm, it will turn off the disk quorum enforcement on primary disk & mirror volumes.

Problems are common to all, but attitude makes the difference
arkie
Super Advisor

Re: Root Disk Mirroring on Production Servers

I am getting the following error while trying to extend the (/) LV

# lvextend -m 1 /dev/vg00/lvol3 /dev/dsk/c2t1d0
The newly allocated mirrors are now being synchronized. This operation will
take some time. Please wait ....
Logical volume "/dev/vg00/lvol3" has been successfully extended.
lvlnboot: LIF information corrupt or not present on "/dev/dsk/c2t1d0".
Use the "mkboot" command to initialize the LIF area.
lvlnboot: LIF information corrupt or not present on "/dev/dsk/c2t1d0".
Use the "mkboot" command to initialize the LIF area.
Volume Group configuration for /dev/vg00 has been saved in /etc/lvmconf/vg00.conf

Prior to this, I had done
# mkboot /dev/rdsk/c2t1d0
There appear to be non-boot logical volumes on this device.
Overwriting them could destroy all the data on this device
Should the logical volumes be overwritten [y/n]? y

# mkboot -a "hpux -lq (;0)/stand/vmunix" /dev/rdsk/c2t1d0

And also checked the same
# lifcp /dev/rdsk/c2t1d0:AUTO -
hpux -lq (;0)/stand/vmunix

But, it is still saying :-
lvlnboot: LIF information corrupt or not present on "/dev/dsk/c2t1d0".
Use the "mkboot" command to initialize the LIF area.

Michal Kapalka (mikap)
Honored Contributor

Re: Root Disk Mirroring on Production Servers

hi,

did you made pvcreate -B -f /dev/rdsk/..... ???

if not there is no LVM boot are structure created.

mikap
arkie
Super Advisor

Re: Root Disk Mirroring on Production Servers

Further, LIF directory contents for this drive shows only,
# lifls -l /dev/rdsk/c2t1d0
volume c2t1d0 data size 29 directory size 1 10/03/19 16:44:48
filename type start size implement created
===============================================================
LABEL BIN 8 8 0 10/03/19 16:44:48

Can anyone help me with this

arkie
Super Advisor

Re: Root Disk Mirroring on Production Servers

Hi Michael,

I didn't do a pvcreate during this session, as I could see it was already included in vg00.

# vgdisplay -v vg00
...
...
--- Physical volumes ---
PV Name /dev/dsk/c2t0d0
PV Status available
Total PE 4374
Free PE 253
Autoswitch On

PV Name /dev/dsk/c2t1d0
PV Status available
Total PE 4374
Free PE 4374
Autoswitch On


--- Physical volume groups ---
PVG Name vg00
PV Name /dev/dsk/c2t0d0

I also checked with pvdisplay to see if it was initialized. So, I just skipped pvcreate and vgextend. Pls correct me if i am wrong.
chris huys_4
Honored Contributor

Re: Root Disk Mirroring on Production Servers

Hi Arkie,

Not to want to alarm you, but taking over blindly commands, without knowing what these commands do, or how they will react on your environment, is not the most sensible thing to do.

f.e.
Prior to this, I had done
# mkboot /dev/rdsk/c2t1d0
There appear to be non-boot logical volumes on this device.
Overwriting them could destroy all the data on this device
Should the logical volumes be overwritten [y/n]? y

Are you sure, that the disk, the bootdisk can be mirrored to, has as device file c2t1d0 ?

And if c2t1d0 is the right disk, why does the mkboot command, seem to mention that it has allready logical volumes configured on this disk ?

And are you sure that these logical volumes are not used anymore by the system ?

Best Regards,
Chris
Michal Kapalka (mikap)
Honored Contributor

Re: Root Disk Mirroring on Production Servers

hi,

before you are extending the VG, you need to make pvcreate, its recommended to do pvcreate -f ( for new or used disks ), if you don't do -B them the disk will be never boot.

mikap
arkie
Super Advisor

Re: Root Disk Mirroring on Production Servers

Hi Chris,

I checked with ioscan and found that c2t1d0 was CLAIMED by the system. Also checked with in "vgdisplay -v vg00" o/p, found no used PEs

PV Name /dev/dsk/c2t1d0
PV Status available
Total PE 4374
Free PE 4374
Autoswitch On

By the time, already done the "lvextend -m 1" for the other PVs to this drive.

I realize my mistake now. But I was short of methods to check if c2t0d0 was pvcreated with -B option or not.

I have got to do this from scratch again. But the main issue now is to get this PV to its first stage