Operating System - HP-UX
1833798 Members
3078 Online
110063 Solutions
New Discussion

Re: Disk thinks it belongs to group

 
SOLVED
Go to solution
Kim Kendall
Regular Advisor

Disk thinks it belongs to group

I have a disk that (I think) used to be a mirror of the rood drive. But thr root volume says it has 0 mirrors.

It started generating lbolt errors and I tracked it down to this channel which only has this one drive.

The ioscan saw the device, diskinfo saw the device, so I was just going to put it back as the mirror.

I did a pvdisplay of it and it returned that it wasn't part of any volume group. So I proceeded as though this was going to be a new mirror, and tried to do a pvcreate -B of the device.

Anyway, I rebuilt the lvmtab file

See the attached....

Where do you think I should go from here? The vgscan suggested vgimport.
7 REPLIES 7
Helen French
Honored Contributor
Solution

Re: Disk thinks it belongs to group

Follow the instructions in this document to create a root mirror (TKB#LVMKBRC00005103):
http://www2.itrc.hp.com/service/cki/docDisplay.do?docLocale=en_US&docId=200000064129097
Life is a promise, fulfill it!
A. Clay Stephenson
Acclaimed Contributor

Re: Disk thinks it belongs to group

First, do a strings /etc/lvmtab and make sure that this device is not listed. It appears that this disk was vgexported'ed at some time in the past. We simply need to force a pvcreate and then you can add the disk to an existing VG. Do a pvcreate -f -B and you should be fine.
If it ain't broke, I can fix that.
Kim Kendall
Regular Advisor

Re: Disk thinks it belongs to group

Already tried to make it a mirror.... first thing I do is a pvcreate:

#pvcreate -B /dev/rdsk/c2t6d0
pvcreate: The physical volume already belongs to a volume group

And I cant find a vg that thinks it owns the disk, nor can I even remove it (pvremove)

See the attached on the original post.
James R. Ferguson
Acclaimed Contributor

Re: Disk thinks it belongs to group

Hi:

The 'pvcreate' failed because there is a Volume Group ID on the physical disk. You can/could use 'pvcreate -f /dev/rdsk/cXtYdZ' to overwrite it. The presence of this information indicates that the disk *was* used in an LVM configuration at one time.

You should not have resorted to a 'vgscan'. Before proceeding further, does your system truly consist of only 'vg00'?
Please *post* the output of 'vgdisplay /dev/vg00'.

Regards!

...JRF...
Kim Kendall
Regular Advisor

Re: Disk thinks it belongs to group


DOH !!!!

forgot about pvcreate "-f" ...
I'll try that, thanks
Ashwani Kashyap
Honored Contributor

Re: Disk thinks it belongs to group

The vgscan output suggests that this disk was exported out of lvmtab previously . It still retains the VG headers thats why it complains that it is a part of exported VG . IF you are sure that this was a mirror of the root disk , then you can force pbcreate on the disk .

Use pvcreate -f -B /dev/rdsk/cxtydz . And then follow the standard procedures for root disk mirroring .
S.K. Chan
Honored Contributor

Re: Disk thinks it belongs to group

If you're going to re-mirror the disk and very sure that this disk c2t6d0 does not currently belongs to any volume group you can do a ..
# pvcreate -f -B /dev/rdsk/c2t6d0
to force the pvcreate command. The rest of the steps would be like this ..

# mkboot -l /dev/rdsk/c2t6d0
=> Create boot track (place boot utilities in boot area), -l means treat device as LVM disk.
# mkboot -a "hpux -lq" /dev/rdsk/c2t6d0
=> Add AUTO file in boot LIF area, "lq" option is to bypass quorum check.
=> Repeat for primary disk (c1t6d0) as well.
# lifcp /dev/rdsk/c2t2d0:AUTO -
=> Check content of AUTO file. Repeat for primary disk (c1t6d0).
# vgextend /dev/vg00 /dev/dsk/c2t6d0
=> Adding disk to root VG.
# pvdisplay -v /dev/dsk/c2t6d0
=> Note of the order of LVs (assuming it's lvol1,lvol2,lvol3,lvol4 & lvol5)
# lvextend -m 1 /dev/vg00/lvol1 /dev/dsk/c2t6d0
=> Repeat for lvol2-lvol5
# lvlnboot -r /dev/vg00/lvol3 /dev/vg00
# lvlnboot -b /dev/vg00/lvol1 /dev/vg00
# lvlnboot -s /dev/vg00/lvol2 /dev/vg00
# lvlnboot -d /dev/vg00/lvol2 /dev/vg00
=> Update BDRA (root-lvol3, boot-lvol1, swap-lvol2 and dump-lvol2)
# lvlnboot -v
=> Check to make sure both disks are listed for root, boot and swap definition.
# setboot
=> Display boot path.
# setboot -a
=> Change alternate boot path to mirrored disk.
# shutdown -r -y 0
=> Interrupt upon bootup and select alt path to boot from in order to test.