LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   Need to recover data from a LVM volume (https://www.linuxquestions.org/questions/linux-general-1/need-to-recover-data-from-a-lvm-volume-332642/)

deyv 06-11-2005 11:28 PM

Need to recover data from a LVM volume
 
I had a machine running Fedora Core 3 that had a severe motherboard failure during an update session.
I cannot get the drive to boot properly in another system so what I was hoping to do is add the drive to this second system as hdb and just pull the data that I need off of the drive.
How do I go about getting the data from the original LVM volume onto another system? I am new to working with LVM and I do not want to screw up my data.

Thanks,

-Deyv

rkettle 06-12-2005 05:26 PM

you can mount it like any other file system.. the fact that it happened during an upgrade sounds like too much of a coincidence to me though. Just plug in the hard drive and mount it. Are you sure the motherboard is dead?

Regards
Richard

deyv 06-13-2005 12:00 PM

I definitely verified the board is bad, the IDE controller ports do not work and the mouse PS2 port does not work either.

As for pulling the data off, are you saying that I can mount the partition (/dev/hdb2) just like a normal partition? I was concerned just directly mounting it because it was part on a LVM volume. I will give a shot and see if I can pull off the data.

Thanks,

deyv

lnozot 07-07-2005 04:37 PM

I have a simular problem. I have a system running SATA boot drives and I installed a SCSI tape drive.

After doing this the system doesn't boot properly. After further investigation I am missing LVM data for the PV that holds usr, var, and other data.

I've been unable to mount any of these partitions because it can't find the PV nor VG.

Anyone know how I can recover the VG and LVs?

Thanks!
Loren

deyv 07-07-2005 04:52 PM

I am still having the same problem and I have yet to find a solution.

WhatsHisName 07-07-2005 05:46 PM

If the distribution you are using is not natively LVM aware (e.g., FC4 Linux Rescue mode is NOT natively LVM aware), try activating the volume group(s) by running:

lvm vgchange -a y

OR

vgchange -a y # Note: this is a symlink that may not work


Then run:

lvm lvscan

OR

lvscan

to see the logical volumes.


Then mount them like any olde partition:

mount /dev/VolGoup00/LogVol00 /mnt/temp

or something like that, where /mnt/temp or whatever you want to mount under preexists.

lnozot 07-07-2005 06:14 PM

I am running Suse 9.3/Reiser.

I have done that work and I get nothing back. However, if I do a pvscan I get.

PV /dev/sda3 lvm2 [227.73GB]
Total 1 [227.73 GB] / in use: 0 [0 ] / in no VG: 1 [227.73 GB]


The system doesn't think there is a volume group nor lvols on the partition (PV).

Loren

WhatsHisName 07-07-2005 07:40 PM

Try this:

lvm vgdisplay -P -v

If anything is there, even in a damaged state, you should see it.


If everything else fails, read:

man vgcfgrestore

and think long and hard before you execute vgcfgrestore.

lnozot 07-07-2005 08:23 PM

It doesn't report anything.

Where would the metadata text file be stored if it exists?

Thanks!

lnozot 07-07-2005 08:33 PM

OK,

I put one of my other drives that was a part of the VG back into the system and tried again. It finds the LVs.

However the report is that it cannot find PV with UUID ..........

I obviously know which PV that is but how can I fix that?

Thanks!
Loren

badbit 07-23-2005 04:01 PM

I'm having the very same problem, now my system won't boot, and displays the same message about not being able to find the PV with the specified UUID.

I'm going mad! I can't access my data, and I need it badly. I've asked in several forums, and nobody has an answer. I would be happy if I could hex edit my partiton, and try to recover the info myself, is it possible?

lnozot 07-25-2005 04:12 PM

Badbit,

I have not found a good way to resolve this issue. I have worked with a few tools, (insert, recovery, and dfsee). The issue I have run into is that LVM is not really supported in recovery tools. You can do some things but not an extreem amount.

I am still working on my issue and if I find something that works I'll post it here.

Loren

badbit 07-25-2005 05:27 PM

I've tried with dfsee also, but no luck...

I tried something with Partition Magic, from my Windows XP, but unfortunately it prevented me from booting windows. Now that i've corrected it, I'm thinking of deleting my NTFS partition, and installing another Fedora Core 4, to see if it's easier to recover from there. What do you think?

lnozot 07-25-2005 05:43 PM

dfsee doesn't support Linux version of LVM. The other tools do.

If you do an install you jeopardize your data. You should go buy a new disc and do a drive to drive copy with one of the tools. Then you can work on the disc you are having trouble with.

Your best bet is to use a bootable hard drive recovery tool. Insert and Recovery tools are ones you should be able to find at sourceforge.net.

So, don't do anything to your disc before backing it up.

Good Luck!


All times are GMT -5. The time now is 07:07 AM.