Lost LUKS partition
Posted: 10 Sep 2019, 05:14
Hi All,
Trying to recover an external drive's partitions that were accidentally messed up by a boot drive creator program (WinToFlash) and would like advice on how to proceed. Details as follows.
- Western Digital 3TB My Passport
- 2 Partitions: (1) NTFS, (1) EXT4 (LUKS)
In the process of attempting to reformat the drive to turn it into a boot drive, a stupid mistake on my part, WinToFlash halted the process with an error. I can't remember the error message unfortunately, but the error occurred before the actual writing began.
This resulted in the partitions showing up as RAW/unallocated in the Disk Management. The NTFS partition is now RAW while the LUKS partition is "unallocated". For some reason Disk Management shows 3 partitions, and unless it's actually storage space I just never allocated, I'm not sure why that is.
However in TestDisk, 2 partitions are discovered:
The LUKS partition is currently unrecognized by Linux. Yet TestDisk indicates: LUKS 1 (Data size unknown), 2097 KB / 2048 KiB.
I believe the first step would be to image the drive? The only way I see to get an image of the entire drive is to set the partition table type to None. If I select EFI GPT as TestDisk recommends I see the partitions and can image them individually. I would like to image the entire drive in case the recovery process goes wrong, but is imaging the individual partitions sufficient?
Out of curiosity, I used TestDisk on the MS Data partition and it was able to recover all files/folder structure on that partition. I ran PhotoRec on the LUKS Partition for a bit: it found 10/10 headers and began recovering.. something.
For the time being I've disconnected the drive to prevent any further complications. In my online investigation into how to restore a LUKS partition, people said the partition cannot be recovered without a backup of the LUKS header, which I unfortunately don't have as I created it before I knew to backup the header. Still, I'm hoping that the partition can be recovered as TestDisk is able to list it.
TestDisk/PhotoRec are being used on a Windows machine, and I have the necessary space to save an image of the drive.
I'm not too saavy with these programs, so any help will be greatly appreciated.
Trying to recover an external drive's partitions that were accidentally messed up by a boot drive creator program (WinToFlash) and would like advice on how to proceed. Details as follows.
- Western Digital 3TB My Passport
- 2 Partitions: (1) NTFS, (1) EXT4 (LUKS)
In the process of attempting to reformat the drive to turn it into a boot drive, a stupid mistake on my part, WinToFlash halted the process with an error. I can't remember the error message unfortunately, but the error occurred before the actual writing began.
This resulted in the partitions showing up as RAW/unallocated in the Disk Management. The NTFS partition is now RAW while the LUKS partition is "unallocated". For some reason Disk Management shows 3 partitions, and unless it's actually storage space I just never allocated, I'm not sure why that is.
However in TestDisk, 2 partitions are discovered:
The LUKS partition is currently unrecognized by Linux. Yet TestDisk indicates: LUKS 1 (Data size unknown), 2097 KB / 2048 KiB.
I believe the first step would be to image the drive? The only way I see to get an image of the entire drive is to set the partition table type to None. If I select EFI GPT as TestDisk recommends I see the partitions and can image them individually. I would like to image the entire drive in case the recovery process goes wrong, but is imaging the individual partitions sufficient?
Out of curiosity, I used TestDisk on the MS Data partition and it was able to recover all files/folder structure on that partition. I ran PhotoRec on the LUKS Partition for a bit: it found 10/10 headers and began recovering.. something.
For the time being I've disconnected the drive to prevent any further complications. In my online investigation into how to restore a LUKS partition, people said the partition cannot be recovered without a backup of the LUKS header, which I unfortunately don't have as I created it before I knew to backup the header. Still, I'm hoping that the partition can be recovered as TestDisk is able to list it.
TestDisk/PhotoRec are being used on a Windows machine, and I have the necessary space to save an image of the drive.
I'm not too saavy with these programs, so any help will be greatly appreciated.