1: The LUKS header at the start of your home partition will begin with the following bytes: ['L','U','K','S',0xBA,0xBE] (from the spec) One you've found the header, assuming it's all intact, you'll be able to mount :). The exact details of mounting that you'll have to go through I'm not sure of enough to quote, maybe cryptsetup -o, or repartitioning, will be required. (If you do have the start of the home partition correct, then you should be able to run `head -c 4 /dev/sda4 `and have it return LUKS). Oh, and I suggest turning off swap in case the start of home is actually somewhere in that swap partition and you inadvertently start overwriting it when using the computer. 2: Overwriting the end of the partition is no big deal from a LUKS perspective, you'll lose that 5GB rounded up to some multiple of your cipher blocksize, the start of the partition however is critical as that is where the master key is stored.
From a filesystem perspective, I'm not sure how well whatever
filesystem you're using deals with the last 5GB being cut off :) On 7/19/07, Evgeni Golov <sargentd@xxxxxxxxxxxx> wrote:
Hey guys, yesterday I tried to install Windows from the recovery cds of my laptop-vendor, which had a bad effect: it erased my partition table and wrote data to the first 8 and last 5 GB of the disk. Before that, my disk looked like this: sda1: 10GB XP sda2: 10GB / (ext3) sda3: 1GB swap (LUKS) sda4: 78GB /home (LUKS) I could find / and swap with gpart, but could not for /home. So I recreated /home as the whole rest of the disk behind swap (like it should be). / works fine, I can boot from it and fsck does not complain. Same for swap, I could open it with my luks-key and it works fine. But for /home cryptsetup keeps telling me, it is not a luks partition. So I'm searching the problem (and it's solution of course): 1. did I set the wrong start/end sectors? how could I find the correct? 2. is the partition lost, because the last 5GB were overwritten? TIA Evgeni, who has backups, but recovery is so much more fun ;) --------------------------------------------------------------------- dm-crypt mailing list - http://www.saout.de/misc/dm-crypt/ To unsubscribe, e-mail: dm-crypt-unsubscribe@xxxxxxxx For additional commands, e-mail: dm-crypt-help@xxxxxxxx
--------------------------------------------------------------------- dm-crypt mailing list - http://www.saout.de/misc/dm-crypt/ To unsubscribe, e-mail: dm-crypt-unsubscribe@xxxxxxxx For additional commands, e-mail: dm-crypt-help@xxxxxxxx