Operating System - HP-UX
1833788 Members
2507 Online
110063 Solutions
New Discussion

Re: remove logical volumes when disk system crashed.

 
Ron Gardner
New Member

remove logical volumes when disk system crashed.

I need to remove lvol1,2,3 from vg01 after the disk expansion chassis failed. Where is the logical volume info stored so I can force removal when the disks nolonger exist on the system?
5 REPLIES 5
Mel Burslan
Honored Contributor

Re: remove logical volumes when disk system crashed.

did you try this ?

lvremove -f /dev/vg01/lvol1
lvremove -f /dev/vg01/lvol2
lvremove -f /dev/vg01/lvol3

if yes, what and if you get any error messages ?
________________________________
UNIX because I majored in cryptology...
Devender Khatana
Honored Contributor

Re: remove logical volumes when disk system crashed.

Hi,

Alongwith this also remove the lost disks information from the VG using

#vgreduce -f /dev/vgxx

HTH,
Devender
Impossible itself mentions "I m possible"
Raj D.
Honored Contributor

Re: remove logical volumes when disk system crashed.

Hi Ron ,

You can do as follows.

lvremove -f /dev/vg01/lvol1
lvremove -f /dev/vg01/lvol2
lvremove -f /dev/vg01/lvol3

vgreduce -f /dev/vg01

[ NOTE: The above command does not require a physical volume argument. It
must be run on a active volume group. ]


The LVM configuration information stores in /etc/lvmtab and /etc/lvmconf/vg01.conf ( for vg01 )

You can see
# strings /etc/lvmtab
# vgcfgrestore -n /dev/VG01 -l
to see the list of physical volumes on vg01.


Cheers ,
Raj.
" If u think u can , If u think u cannot , - You are always Right . "
Raj D.
Honored Contributor

Re: remove logical volumes when disk system crashed.

sorry mistake in last posting ,

# vgcfgrestore -n /dev/VG01 -l

should be

# vgcfgrestore -n /dev/vg01 -l

Cheers,
Raj.
" If u think u can , If u think u cannot , - You are always Right . "
Ron Gardner
New Member

Re: remove logical volumes when disk system crashed.

Thanks all for the help. What finally did remove the logical volumes was:
vgexport /dev/vg01 the old volume group. lvremove complained about no physical volumes attached.
Ron