Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

[FC4] attempt to extend LVM volume, but LVM setup messed up..

Status
Not open for further replies.

frummel

Technical User
Jun 21, 2002
91
NL
Hi,

i have tried to follow different HOWTO's on extending LVM groups with a second hard drive. I'm not sure what I have done to mess up, and I cannot recall all things I have tried in order to get things right.. which probably all resulted in a bigger mess.

The volume group /dev/VolGroup00 is still running as far is I can see, but the extra disk drive (160GB) isn't part of the volume group yet... below my current LVM table:

Code:
[root@serv01 ~]# pvdisplay
  Couldn't find device with uuid 'v3nxFi-5NMu-biBc-06AQ-tG5w-5gNh-Ah7CVd'.
  --- Physical volume ---
  PV Name               /dev/hda2
  VG Name               VolGroup00
  PV Size               76.22 GB / not usable 0
  Allocatable           yes (but full)
  PE Size (KByte)       32768
  Total PE              2439
  Free PE               0
  Allocated PE          2439
  PV UUID               zy7FiO-sxzP-sFZ4-nPIO-0eMS-N1UY-yRzF6h

  --- Physical volume ---
  PV Name               unknown device
  VG Name               VolGroup00
  PV Size               149.03 GB / not usable 0
  Allocatable           yes (but full)
  PE Size (KByte)       32768
  Total PE              4769
  Free PE               0
  Allocated PE          4769
  PV UUID               v3nxFi-5NMu-biBc-06AQ-tG5w-5gNh-Ah7CVd

  --- NEW Physical volume ---
  PV Name               /dev/hdb1
  VG Name
  PV Size               149.05 GB
  Allocatable           NO
  PE Size (KByte)       0
  Total PE              0
  Free PE               0
  Allocated PE          0
  PV UUID               dxyOPI-rM7h-JDjP-2rgT-E5gl-YMyR-dx8T2W

I need to get the NEW Physical Volume (/dev/hdb1) to be part of VolGroup00 (now existing only of /dev/hda2), and PV 'unknown device' must disappear somehow.

LVM diskcan displays the following:
Code:
[root@serv01 ~]# lvmdiskscan
  /dev/hda1 [      101.94 MB]
  /dev/hda2 [       76.23 GB] LVM physical volume
  /dev/hdb1 [      149.05 GB] LVM physical volume
  0 disks
  1 partition
  0 LVM physical volume whole disks
  2 LVM physical volumes

Any attempt to fix this is appreciated!

 
Hi, I tried some stuff to repair the mess mentioned earlier.

Code:
[root@serv01 ~]# vgreduce --removemissing VolGroup00                              Couldn't find device with uuid 'v3nxFi-5NMu-biBc-06AQ-tG5w-5gNh-Ah7CVd'.
  Couldn't find all physical volumes for volume group VolGroup00.
  Couldn't find device with uuid 'v3nxFi-5NMu-biBc-06AQ-tG5w-5gNh-Ah7CVd'.
  Couldn't find all physical volumes for volume group VolGroup00.
  Couldn't find device with uuid 'v3nxFi-5NMu-biBc-06AQ-tG5w-5gNh-Ah7CVd'.
  Couldn't find device with uuid 'v3nxFi-5NMu-biBc-06AQ-tG5w-5gNh-Ah7CVd'.
  LV VolGroup00/LogVol00 in use: not removing
  Failed to deactivate LV LogVol00
[root@serv01 ~]#

This is what I get. I understand LogVol00 is in use while logged on onto my FC4 box.. on this Logical Volume, the 'system' files reside.

What I don't understand, is why does this need to be deactivated, as well al VolGroup00? I managed to add a PV to the Volume Group eralier.. Why am I unable to remove it?

Code:
[root@serv01 ~]# vgreduce VolGroup00 'unknown device'
  Couldn't find device with uuid 'v3nxFi-5NMu-biBc-06AQ-tG5w-5gNh-Ah7CVd'.
  Couldn't find all physical volumes for volume group VolGroup00.
  Couldn't find device with uuid 'v3nxFi-5NMu-biBc-06AQ-tG5w-5gNh-Ah7CVd'.
  Couldn't find all physical volumes for volume group VolGroup00.
  Volume group "VolGroup00" doesn't exist
The above doesn't work, because no physical volume is attached... Is there a way to remove a device by UUID?

Help is soo appreciated... Thanks
 
Allright.. I'm in real trouble now.
I edited my LVM groups some more.
I did a pvreate, using the UUID of the existing PV, and actually overwrote it, attaching /dev/hdb1 to it.

Next, i wanted to use pvremove to remove the PV by it's PV Name. I went to have dinner, came back, and found my server was turned off..

When booting, I get kernel panic, error 22.
VolGroup00 cannot be found.

In really need the data that was originally on /dev/hda2, but I am unable to access it now. I did not format anything, so all data must be intact. However, I am unable to access it, even using the FC4 CD with the rescue options. It cannot see any Linux partitions.

Yep.. that's what happens if you don't backup data before messing around...

Help is desperately needed.. Thnx.
 
Hi,

I have got the same problem on a FC4 x86_64.
I messed up the / partition trying to remove a new extend.
In fact, i found out on the web, that apparently, the / partition cannot be extended dynamically because, it has to be unmount to get the change, which cannot be done when running from hard disk (/ is always mounted). Am I right?

Have you found a solution? Mine was to boot on my emergency debian on a 2nd disk. I'm going to try to mount the old partition from debian.

Seb
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top