2

I have replaced my hard drive with an SSD and have installed Fedora on it exactly the same as my HDD. I'm attempting to read the data from the hard drive, but since both of the LVM partitions have partitions named fedora-home I can't mount it and it causes this error:

mount: /media: wrong fs type, bad option, bad superblock on /dev/mapper/fedora-home, missing codepage or helper program, or other error.
3

LVM requires each VG / LV to have its own unique name. It will refuse to activate duplicate names. If these are coming from separate installs, they'll each have their own unique VG UUID as shown in vgdisplay output.

Using this UUID you can rename one of them...

vgrename $VGUUID homburg

...and that should resolve the problem.

What the linked answer seems to be discussing is an even more problematic case, when a VG has been cloned outright so UUIDs of all layers (from partition through PV, VG, LV, down to the filesystem) are identical and so you have to re-generate them ALL.

However that does not seem to be your situation. If it's coming from separate installs, your UUIDs are fine, only a clash of regular names.

0

You can't do that. This answer over on ServerFault provides a method for solving the problem though.

is it possible to simultaneously mount 2 LVM volumes that are exact copies of each other (same UUIDs)

  • 1
    Link-only answer, but it's to another SE site. – roaima Jan 20 at 23:48
  • Is then conventional wisdom to quote/copy the answer across sites? – Jeff Schaller Jan 21 at 0:37
  • Sorry for the spam; also this: unix.meta.stackexchange.com/a/1397/117549 -- please feel free to flag this comments as "no longer needed" if they're not helpful. – Jeff Schaller Jan 21 at 1:22
  • @JeffSchaller i don't know. I can copy across the information if that's preferred - I've never really understood why we're not encouraged to cross link answers between the SE sites. But based on those links I'll extract the information and copy across. (It's a shame because if one answer is updated the other gets left behind.) – roaima Jan 21 at 8:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.