2

I have an LVM logical volume spread over eight separate physical volumes on Amazon AWS. The logical volume is formatted using ext3.

One of my physical volumes has failed. Is there any way to recover some or all of the data from the remaining volumes?

Thanks!

Tom
  • 3,133
  • 2
  • 19
  • 19

1 Answers1

0

I was able to more-or-less recover the remaining data by doing the following:

  1. Add a new physical volume to use as a replacement for the failed physical volume.
  2. Use vgscan to determine the UUID of the missing (failed) physical volume.
  3. Use pvcreate --uuid [uuid of failed volume] to add the new physical volume and to give it the same uuid and device descriptor as the failed one.
  4. Use vgcfgrestore [the volume group name] to restore the volume group descriptor (may or may not be needed.)
  5. Use vgchange -ay [the volume group name] to activate the volume group.
  6. Run e2fsck -y [the logical volume] to fix any errors; there will be a lot of them.
  7. Run mount [the logical volume] [desired mount point] and voilĂ ! I found my remaining data!
Tom
  • 3,133
  • 2
  • 19
  • 19