Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

Please help have been trying for over 3-4 days now with various methods. I have created a folder named 'OldHome in my /tmp directory and also have all the encrypted data in a folder there. I deleted my old user with the encrypted files but kept all of the data and have cleared the keyring prior to this method as was unable to log into the old user for an unknown reason, i believe it was because i used root terminal on recovery to reset my password as this was the first thing i completed to log in as it had been such a long time, this had not worked, i have re-created the user but not attempted to copy the home directory into this because before when using it i was having this same problem with the password and attempted to copy the home folder which caused me to lose any remaining space on the separate home partition. Below is the method i have taken in terminal used from https://help.ubuntu.com/community/EncryptedPrivateDirectory#Recovering_Your_Data_Manually, using both the manual method first then the automatic method in live cd mode. I also have a problem copying the encrypted files over to an external hdd getting a read write error: -

ubuntu@ubuntu:~$ sudo ecryptfs-recover-private

INFO: Searching for encrypted private directories (this might take a while)...

INFO: Found [/media/718910c2-d11e-4617-867e-d0ae0425e9e7/.ecryptfs/USERNAME_bak/.Private].

Try to recover this directory? [Y/n]: y

INFO: Found your wrapped-passphrase

Do you know your LOGIN passphrase? [Y/n] n

INFO: To recover this directory, you MUST have your original MOUNT passphrase.

INFO: When you first setup your encrypted private directory, you were told to record

INFO: your MOUNT passphrase.

INFO: It should be 32 characters long, consisting of [0-9] and [a-f].

Enter your MOUNT passphrase:

INFO: Success! Private data mounted read-only at [/tmp/ecryptfs.HJJxSJ63].

ubuntu@ubuntu:~$ sudo apt-get install nautilus

Reading package lists... Done Building dependency tree
Reading state information... Done Suggested packages: gnome-sushi The following packages will be upgraded: nautilus 1 upgraded, 0 newly installed, 0 to remove and 276 not upgraded. Need to get 845 kB of archives. After this operation, 0 B of additional disk space will be used. Get:1 http://archive.ubuntu.com/ubuntu/ precise-updates/main nautilus i386 1:3.4.2-0ubuntu5 [845 kB] Fetched 845 kB in 4s (197 kB/s)
(Reading database ... 148708 files and directories currently installed.) Preparing to replace nautilus 1:3.4.2-0ubuntu4 (using .../nautilus_1%3a3.4.2-0ubuntu5_i386.deb) ... Unpacking replacement nautilus ... Processing triggers for libglib2.0-0 ... Processing triggers for man-db ... Processing triggers for desktop-file-utils ... Processing triggers for bamfdaemon ... Rebuilding /usr/share/applications/bamf.index... Processing triggers for gnome-menus ... Setting up nautilus (1:3.4.2-0ubuntu5) ...

ubuntu@ubuntu:~$ sudo fdisk -l

Disk /dev/sda: 250.1 GB, 250059350016 bytes 255 heads, 63 sectors/track, 30401 cylinders, total 488397168 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00072328

Device Boot Start End Blocks Id System /dev/sda1 * 2048 58595797 29296875 83 Linux /dev/sda2 58597374 488396799 214899713 5 Extended /dev/sda5 484741120 488396799 1827840 82 Linux swap / Solaris /dev/sda6 58597376 242917375 92160000 83 Linux /dev/sda7 478715904 484726783 3005440 82 Linux swap / Solaris

Partition table entries are not in disk order

Disk /dev/sdb: 1021 MB, 1021313024 bytes 15 heads, 46 sectors/track, 2890 cylinders, total 1994752 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000

Device Boot Start End Blocks Id System /dev/sdb1 * 240 1994751 997256 6 FAT16

Disk /dev/sdc: 120.0 GB, 120034123776 bytes 255 heads, 63 sectors/track, 14593 cylinders, total 234441648 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0xc51d19ca

Device Boot Start End Blocks Id System /dev/sdc1 2048 234438655 117218304 7 HPFS/NTFS/exFAT

ubuntu@ubuntu:~$ sudo mount -o remount,ro /dev/sda6

ubuntu@ubuntu:~$ sudo mount -o remount,ro /dev/sda1

ubuntu@ubuntu:~$ sudo find / -type d -iname '.Private' 2>/dev/null /media/718910c2-d11e-4617-867e-d0ae0425e9e7/.ecryptfs/USERNAME_bak/.Private ubuntu@ubuntu:~$ sudo ecryptfs-add-passphrase --fnek

Passphrase:

Inserted auth tok with sig [XXXXXXXXXXXXXXXX] into the user session keyring

Inserted auth tok with sig [XXXXXXXXXXXXXXXX] into the user session keyring

ubuntu@ubuntu:~$ sudo mount -t ecryptfs /media/718910c2-d11e-4617-867e-d0ae0425e9e7/.ecryptfs/USERNAME_bak/.Private /media/c26296ba-cd38-450e-ae66-194d96cb27af/tmp/OldHome

Passphrase:

Select cipher:

1) aes: blocksize = 16; min keysize = 16; max keysize = 32 (loaded)

2) des3_ede: blocksize = 8; min keysize = 24; max keysize = 24 (not loaded)

3) cast6: blocksize = 16; min keysize = 16; max keysize = 32 (not loaded)

4) cast5: blocksize = 8; min keysize = 5; max keysize = 16 (not loaded)

Selection [aes]: aes

Select key bytes:

1) 16

2) 32

3) 24

Selection [16]: 16

Enable plaintext passthrough (y/n) [n]: n

Enable filename encryption (y/n) [n]: y

Filename Encryption Key (FNEK) Signature [XXXXXXXXXXXXXXXX]: [XXXXXXXXXXXXXXXX]

Attempting to mount with the following options:

ecryptfs_unlink_sigs

ecryptfs_fnek_sig=[XXXXXXXXXXXXXXXX]

ecryptfs_key_bytes=16

ecryptfs_cipher=aes

ecryptfs_sig=XXXXXXXXXXXXXXXX WARNING: Based on the contents of [/root/.ecryptfs/sig-cache.txt],

it looks like you have never mounted with this key before. This could mean that you have typed your passphrase wrong.

Would you like to proceed with the mount (yes/no)? : y

Would you like to proceed with the mount (yes/no)? : y

Would you like to proceed with the mount (yes/no)? : y

Would you like to proceed with the mount (yes/no)? : y

Would you like to proceed with the mount (yes/no)? : y

Aborting mount.

ubuntu@ubuntu:~$ <--- THEN BACK TO THIS PROMPT

share|improve this question

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.