Changed PV and lost LV in LVM with Debian 3.0 - Help please
From: Buyle Jerome (jerome_at_buyle.org)
Date: 05/23/04
- Next message: Fritz Bayer: "Re: k3b kernel 2.6.5 DVD cdrecord ATAPI"
- Previous message: Bob: "Wireless card driver installation"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Sun, 23 May 2004 12:14:42 +0200
Hello,
I've configured the following setup months ago on my system (Debian
Woody 3.0 stable with 2.4.18-bf2.4 kernel) :
- RAID1 device /dev/md0 containing /dev/hde1 and /dev/hdg1
- LVM Volume group "vg_mirror" containing /dev/md0 as its only physical
volume
- Various logical volumes inside of vg_mirror
After a power failure this night, I restarted my server this morning.
One of the filesystems in vg_mirror wouldn't mount, giving the following
error :
=====
herbert:/# mount /mnt/helene_safe/
mount: wrong fs type, bad option, bad superblock on
/dev/vg_mirror/lv_helene_safe, or too many mounted file systems
=====
I thought of doing an fsck, but then (in my typical Windows tradition) I
decided to reboot the machine and let the system run fsck by itself.
After this reboot, this went worse : it was impossible to mount any
filesystem in vg_mirror :
=====
herbert:/# mount /mnt/helene_safe
mount: special device /dev/vg_mirror/lv_helene_safe does not exist
herbert:/#
=====
So i checked the state of vg_mirror (using Webmin) to discover that :
- Apparently vg_mirror is configured to use one PV, but it's not
/dev/md0 anymore, it's /dev/hde1.
- vg_mirror contains no logical volume.
I tried using vgcfgrestore to restore configuration from the Volume
Group descriptors backup (the files in /etc/lvmconf/) but it seemes that
there was no info in these files regarding /dev/md0.
Now I run a pvscan to check what Physical Volumes (in LVM terms) are
known to the LVM :
=====
herbert:/# pvscan
pvscan -- reading all physical volumes (this may take a while...)
pvscan -- inactive PV "/dev/md0" of VG "vg_mirror" [18.64 GB / 18.64 GB
free]
pvscan -- WARNING: physical volume "/dev/hdg1" belongs to a meta device
pvscan -- WARNING: physical volume "/dev/hde1" belongs to a meta device
pvscan -- ACTIVE PV "/dev/hdc" of VG "vg_data" [111.79 GB / 32.78
GB free]
pvscan -- total: 4 [130.44 GB] / in use: 4 [130.44 GB] / in no VG: 0 [0]
=====
It appears that :
- /dev/md0 is still somehow linked to vg_mirror,
- LVM "knows" that /dev/hde1 and /dev/hdg1 are not to be used directly
as PVs.
- My other volume group, vg_data, is doing fine
I'm wondering if Webmin is displaying the right information.
What I want to do now is :
- Re-verify the vg_mirror configuration and be 100% sure.
- Re-configure /dev/md0 as a PV in vg_mirror WITHOUT reseting all its
configuration (PE size, etc) and thus WITHOUT losing data.
- Re-configure my 4 LVs in vg_mirror, again by somehow restoring the
original LVs configuration.
Is there someone who's got more experience with LVM (this is my only LVM
install, and so far it's been "setup and forget about it") who'd be able
to give me some indications. I feel a little dizzy and I'm scared of
losing my data in these filesystems on vg_mirror.
Thanks in advance for any hint, suggestion, help...
Jerome Buyle
- Next message: Fritz Bayer: "Re: k3b kernel 2.6.5 DVD cdrecord ATAPI"
- Previous message: Bob: "Wireless card driver installation"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|