1

I just installed Ubuntu 12.04 with the encrypting option. Soon after I found that I have lost my Windows Vista and all my previous partitions as the in the new Ubuntu only one hard drive with summation of all previous partitions appears.

As I needed my data I tried to recover the partitions. I was successful except for the Windows drive (dev/sda1) and that is because it is encrypted. Now, I cannot even run Windows with Windows Vista recovery CD. Any help please.

1

2 Answers 2

0

To access a drive encrypted with LUKS or dmcrypt:

First, open a terminal window and become root. Type blkid to learn the device name of the partition you want. (In your case you have already done this ;-)

Now for the magic bit: Run

cryptsetup luksOpen <device file> <device-mapper name>

and type your password. For example, you might do something like cryptsetup luksOpen /dev/sda1 mydrivethatineed. With this command, the decrypted device would appear at /dev/mapper/mydrivethatineed.

Now you can go ahead and

mount /dev/mapper/<device-mapper name> /mnt

and your filesystem should appear under /mnt.

One last thing: don't forget to unmount a crypto drive when you're done; otherwise, what's the point of crypto? (Do note that the kernel unmounts everything and forgets all passphrases on shutdown.) Unmount it with:

cryptsetup luksClose <device-mapper name>

and you should be set!

1
  • Thanks polarkatenuchie. That didn't work. Actually now I am running Ubuntu from liveUSB. Afraid to install it on hard drive since I think it may destroy my windows drive /dev/sda1 which you can see below is encrypted. The only thing that I need to do is to be able to have this drive back. As I said before, probably because it's locked, even with my windows recovery DVD I cannot boot up to windows. I tried many suggestions to mount this drive but none of them worked. I know both passphrase and password.
    – Jeo
    Oct 24, 2012 at 2:01
0

Actually, I think you used the guided install and used the entire partition. There is no "real" support for Full Drive Encryption in windows so its highly unlikely that your windows drive is still there.

There is a little hope though, some portion of your data may remain where the drive was not written to. Data recovery may be possible.

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.