System Administration
cancel
Showing results for 
Search instead for 
Did you mean: 

Volume group "vg00" still has active LVs

Karthikeyan.j
Frequent Advisor

Volume group "vg00" still has active LVs

vgrename fails on Rhel 4 AS gives a error active lvs exists .
tried booting in liux resuce but the lvm gets activated at boot ,same error occurs when we execute vgrename Volume1 Vol1

Volume group "vg01" still has active LVs

Note : /usr is mounted on lvol1 on vg00
/opt is mounted on lvol2 on vg00
/home is mounted on lvol3 on vg00
/var is mounted on lvol4 on vg00
8 REPLIES
Tony Berry
Valued Contributor

Re: Volume group "vg00" still has active LVs

What happens if you boot into single user mode, manually umount all the vg01 filesystems, and run 'vgchange -a n vg01'?

Unix is boss.
skt_skt
Honored Contributor

Re: Volume group "vg00" still has active LVs

Why do u want to renmae LVs? Is that LV belongs to vg01 ot vg00?

if it vg01 , umount all file system from that VG and then do a vgchange -a n.

If it is from VG00.You may boot using rescue cd.make sure nothing is mounted from vg00 and Deactivate it.(as u said if it is already active).No normal file systems get mounted when you get shell prompt(#) in rescue mode.
Karthikeyan.j
Frequent Advisor

Re: Volume group "vg00" still has active LVs

Hi All
when i umount /usr , /opt/, /home ..etc i m not able to execute the commands vgchange so i had to copy the /usr to a normal file system and mount it and then when i execute vgchange -a n vg00 it says still lvs exists .

the reason why i want to rename is since our standards say we have to use vg00 but my mistake whe have created Vg00 i e the reason i have to vgrename it :)

Thx for all ur help :)
Hemmetter
Esteemed Contributor

Re: Volume group "vg00" still has active LVs

Hi Karthikeyan.j

The output of "pvs" and "lvs" may be helpful.
Do you have swap on any lvol?

rgds
HGH

Karthikeyan.j
Frequent Advisor

Re: Volume group "vg00" still has active LVs

Hi All
Pls find the output of Pvs and Lvs

PV /dev/cciss/c0d1p1 VG Vg01 lvm2 [67.81 GB / 48.81 GB free]
PV /dev/cciss/c0d0p3 VG Vg00 lvm2 [56.81 GB / 32.81 GB free]
Total: 2 [124.62 GB] / in use: 2 [124.62 GB] / in no VG: 0 [0 ]
[kk650976@galileo ~]$ sudo /usr/sbin/lvscan
ACTIVE '/dev/Vg01/lvol1' [15.00 GB] inherit
ACTIVE '/dev/Vg01/lvol2' [3.00 GB] inherit
ACTIVE '/dev/Vg01/lvol3' [1.00 GB] inherit
ACTIVE '/dev/Vg00/lvol3' [1.00 GB] inherit
ACTIVE '/dev/Vg00/lvol4' [10.00 GB] inherit
ACTIVE '/dev/Vg00/lvol1' [3.00 GB] inherit
ACTIVE '/dev/Vg00/lvol2' [10.00 GB] inherit

no swap is not on lvm partition
Hemmetter
Esteemed Contributor

Re: Volume group "vg00" still has active LVs

Hi

vg00 has 38G available space.
the 3 lvols in vg01 are together 19G.

Create three new lvols ( 15G 3G 1G ) in vg00.
mount them && copy data.

Then lvremove these vg01/lvols.
then vgremove vg01 ( vgchange -a n vg01 first)
then vgextend vg00 with /dev/cciss/c0d0p1

then you have your only vg00


rgds
HGH



Karthikeyan.j
Frequent Advisor

Re: Volume group "vg00" still has active LVs

Hi Hemmeter

The problem is on Vg01 application volumes are created /opt/psoft as 60 Gb /lvol1 vg01
and /opt/oracle 2gb lvol2 on vg01
/opt/tuxedo 2 gb lvol3 on vg01 .
Hemmetter
Esteemed Contributor

Re: Volume group "vg00" still has active LVs

Hi

/opt/psoft 60 Gb lvol1 vg01
/opt/oracle 2 Gb lvol2 vg01
/opt/tuxedo 2 Gb lvol3 vg01

does not match your earlier posting:

PV /dev/cciss/c0d1p1 VG Vg01 lvm2 [67.81 GB / 48.81 GB free]
$ sudo /usr/sbin/lvscan
ACTIVE '/dev/Vg01/lvol1' [15.00 GB] inherit
ACTIVE '/dev/Vg01/lvol2' [3.00 GB] inherit
ACTIVE '/dev/Vg01/lvol3' [1.00 GB] inherit

These are quite different prerequisites.
So you have to backup your data somewhere else before moving c0d1p1 to vg00.


rgds
HGH