Operating System - HP-UX
1834732 Members
3073 Online
110070 Solutions
New Discussion

Re: vgremove: Volume group not activated.

 
Luis Lino_1
Advisor

vgremove: Volume group not activated.

Dear Friends,
We have a problem with vgremove, we have already deleted disk from EVA3000 and it's OK, but when we execute:
strings /etc/lvmtab
/dev/vg00
/dev/dsk/c0t6d0
/dev/dsk/c2t6d0
/dev/vgrac
/dev/dsk/c6t2d4
/dev/dsk/c6t2d5
/dev/dsk/c6t2d7

ioscan -funC disk
Class I H/W Path Driver S/W State H/W Type Description
=======================================================================
disk 0 2/0/0/2/0.6.0 sdisk CLAIMED DEVICE HP 73.4GMAS3735NC
/dev/dsk/c0t6d0 /dev/rdsk/c0t6d0
disk 1 2/0/0/2/1.2.0 sdisk CLAIMED DEVICE HP DVD-ROM 305
/dev/dsk/c1t2d0 /dev/rdsk/c1t2d0
disk 2 2/0/0/3/0.6.0 sdisk CLAIMED DEVICE HP 73.4GMAS3735NC
/dev/dsk/c2t6d0 /dev/rdsk/c2t6d0


We don't know how delete /dev/vgrac, We tried to executed vgremove but it doesn't work.

Could you help me, please?

Thanks
Luis L.
8 REPLIES 8
Yang Qin_1
Honored Contributor

Re: vgremove: Volume group not activated.

run vgexport vgrac
read man vgexport

Yang
Christian Tremblay
Trusted Contributor

Re: vgremove: Volume group not activated.

The proper way is to remove the VG BEFORE removing the storage.

Try mv /etc/lvmtab /etc/lvmtab.old
vgscan

Chris
Coolmar
Esteemed Contributor

Re: vgremove: Volume group not activated.

You will have to vgexport. First I would copy the /etc/lvmtab to /etc/lvmtab.orig and then run "vgscan -a"
Yang Qin_1
Honored Contributor

Re: vgremove: Volume group not activated.

> You will have to vgexport. First I would copy the /etc/lvmtab to /etc/lvmtab.orig and then run "vgscan -a"

From vgexport manpage:

The volume group identified by vg_name is removed from the /etc/lvmtab
file, and the associated device files including the vg_name directory
and group file are removed from the system.


Yang
Christian Tremblay
Trusted Contributor

Re: vgremove: Volume group not activated.

The vgexport will fail for the same reason the vgremove fails: The disks are gone and the VG is not activated and cannot be, so your only option remains to rename the lvmtab file and recreate it with vgscan.

You should always remove LVM structures before removing the LUNs not to get this problem.
Mark Nieuwboer
Esteemed Contributor

Re: vgremove: Volume group not activated.

No christian, what your telling is not true.
with vgexport you will remove the vg even if the disk aren't there anymore.

Please be carefull with vgscan it can cause a lot of damage. always make a backup of lvmtab before you do a vgscan -a.

grtz. Mark
Christian Tremblay
Trusted Contributor

Re: vgremove: Volume group not activated.

Well, my experience differs, I had the exact same problem last week where the LUNs were removed in the SAN before the LVM structures were, and vgremove and vgexport failed with the "volume group not activated" message.

And I could not activate it because of the missing LUNs.

If it works for Luis to vgexport the VG without it being activated then..good, but I had to rename lvmtab and run vgscan which fixed the problem in no time.
Luis Lino_1
Advisor

Re: vgremove: Volume group not activated.

Thanks

Now is OK:
1. vgexport vgrac
2. vgscan