Operating System - HP-UX
1820644 Members
1937 Online
109626 Solutions
New Discussion

Re: Help Disk drive failure and pvremove

 
SOLVED
Go to solution
Neil Harris
Regular Advisor

Help Disk drive failure and pvremove

I was trying to create a new vg on an unused drive, this failed with a block error when the creation of the lvol was attempted and the vg was marked as unused. I have replaced the drive with a new one. I now wish to create the vg on the new drive. When I try to do this pvcreate tells me that there is an entry in lvmtab for this vg already and fails; which I can see as being resonable as it created the vg for the faulty drive but not the lvol. I have tried pvremove and this reports it cant find the device /dev/dsk/cxtxdx. If I do a vg remove I get vg is not activated and i cant activate it. What I want to know is how can I remove the entries for the previous drive from the system in order to create the vg. I really dont want to have to put the old drive back in the system in order to remove its entries, is there a way to do this. I have learned if this were to happen again I should remove the entries before replaceing the drive. Aint hind sight fun!!!
An inveterate hacker
1 REPLY 1
Sridhar Bhaskarla
Honored Contributor
Solution

Re: Help Disk drive failure and pvremove

Neil,

Do a vgexport on the new vg to get rid of it from lvmtab.

#vgexport new_vg_name

Once this is done, you do a pvcreate -f new_disk and then create a vg following the usual procedure.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try