Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 03-27-2009, 02:03 AM   #1
LQ Newbie
Registered: Mar 2009
Location: Norway
Distribution: Ubuntu/slackware/Debian
Posts: 2

Rep: Reputation: 0
Question Inconsistent metadata in lvm


I made a mistake yesterday, followed by a couple of other mistakes.

I'm running LVM2 on my Ubuntu installation, my lvol0 was almost full, so i added another 500GB hard drive to the computer, and decided to add it to my lvol0. Did this in the GUI for LVM (In ubuntu found in /usr/bin/system-config-lvm). The drive was not formatted yet. Then i ran the command "vgextend -L 950G /dev/vg0/lvol0". Then i ran the command "df -h" in shell, and saw that my partition was still the same size as earlier. Assumed this had to do with the fact that the drive was not formatted, so i tried formatting it, that was not possible due to the fact it was in use, although not mounted anywhere. So i tried removing it from the lvm in the gui mentioned earlier. Couldn't be done. Thought that had to be because vg0 was 950GB, so i resized it to 496 GB with the command "vgresize -L 496G /dev/vg0/lvol0". It gave me a warning that i could loose data when resizing down, but since i had not used more that about 470GB i thought i was safe. I was not safe at all. Now the lvm is down, with an errormessage saying the metadata is inconsistent. And when running commands like "pvdisplay", "vgdisplay" or just "pvs", i just get this message "File descriptor 5 left open" and nothing happends.

Is there a way to recreate the metadata?
Is there a way to recreate the data from the partitions to another harddrive?

Any help would be deeply appreciated (since i'm a man, and don't do backups :P)
Old 03-27-2009, 07:02 PM   #2
Senior Member
Registered: Jan 2008
Distribution: Arch/Knoppix
Posts: 1,823
Blog Entries: 14

Rep: Reputation: 282Reputation: 282Reputation: 282
since i'm a man, and don't do backup
I can't believe you wrote that. Sorry, I realize that's not helpful for your particular problem, but I'm hoping it's taken as helpful in a larger context.

Maybe this can help
or this
Old 03-27-2009, 08:03 PM   #3
LQ Newbie
Registered: Mar 2009
Location: Norway
Distribution: Ubuntu/slackware/Debian
Posts: 2

Original Poster
Rep: Reputation: 0
Thumbs up

It's just a saying that real men cries a lot, but never makes backups.

The second link contained information that really worked for me, just did the vgcfgrestore -f thingy.

Thanks a lot mostlyharmless



Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
LVM - editing metadata mickj Linux - Software 6 12-16-2008 09:37 AM
LVM and multiple iSCSI disks performance of LVM xxx_anuj_xxx Linux - Server 4 05-01-2008 12:26 PM
LXer: Managing LVM with the LVM Manager LXer Syndicated Linux News 0 03-16-2008 11:10 AM
LXer: Back Up (And Restore) LVM Partitions With LVM Snapshots LXer Syndicated Linux News 0 04-17-2007 11:16 AM
LVM Error: incorrect metadata area header checksum neillans Linux - General 1 02-28-2006 02:06 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:19 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration