Just one more proof for the steep learning curve which comes with Linux ;-)
My original LVM configuration was a complete mess up waiting to happen - only now did I figure out that entire LVM concept works to begin with.
On my old IBM OpSys the LVM manager created its own partitions.
Now I know that in Linux the LVM manager takes an *existing* partition and turns it into an LVM managed "virtual disk".
So during my original SuSE install I was clicking around like an idiot in the LVM manager, trying to *create* a partition in there, only to end up importing most of my already existing ones into LVM management.
And as soon as I needed to boot into a rescue CD, I found out that I could no longer access anything stored in the LVM in there.
Because even rescue distros that do have some LVM functionallity built in (like "gparted") can't handle *damaged* LVM volumes properly.
That's why its important to never LVM your root partition!
But I finally figured out how to get EVERYTHING back.
First I made a complete ghost of my "damaged" disk to a HD with the exact same(!) geometry.
With that safe back up I deleted my damaged partitions, re-installed SuSE from scratch (just enough parts to get it up & running), including the encrypted FS option, and put that drive onto the USB port.
The later part is important as otherwise the duplicate disk will get the entire boot sequence messed up when the drive is in the computer during start-up.
So I start up the computer and then connect my ghosted drive.
And with a little bit of "lvm pvscan/vgchange" magic I all of a sudden had all my originel partitions back online.
Including my encrypted one. When in doubt a bit of tampering with "/etc/cryptotab" and "mount -a" makes all the difference.
But since I was careful to choose the exact same ID's & sizes for the FS options when re-creating my partitions (only this time I made sure they were of the correct partition types as well), all I had to endure was a little LVM confusion because of duplicate partition IDs for my LVM volume.
But as I said, a bit of "lvm pvscan & vgchange" play took care of that.
Then I used "cp -a -x" to extract all of my files to another safe drive one file system at a time.
Now all I have to do is to use my rescue CD once more (and with my root partition being of the right non-LVM type I can actually access it correctly) and move my safed files back where they belong.
If I didn't loose no links or other stuff while doing "cp", then I should be back in business within the hour.
I sure was able to copy all my files w/o one single error once I had the FS back online.
Jeez, after days in which I had the partition table of that drive messed & garbbled with so many time that I sometimes thought not a single data record could have survived such torment!
|