Mount LUKS encrypted Linux Mint 22 Cinnamon #36

Open
opened 2024-09-11 20:47:36 +02:00 by Benjamin_Loison · 19 comments

image

stalls for at least some minutes and blocks everything.

gnome-disk-utility is able to unlock encrypted device thanks to another prompt. However, it does not propose to mount the unlocked device.

Furthermore, when try to mount LVM2 PV Device:

sudo mount /dev/mapper/luks-XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX partition0/
Output:
mount: /mnt/partition0: unknown filesystem type 'LVM2_member'.
       dmesg(1) may have more information after failed mount system call.
![image](/attachments/4c548711-a6a4-4376-9fee-f03155178311) stalls for at least some minutes and blocks everything. `gnome-disk-utility` is able to unlock encrypted device thanks to another prompt. However, it does not propose to mount the unlocked device. Furthermore, when try to mount *LVM2 PV* *Device*: ```bash sudo mount /dev/mapper/luks-XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX partition0/ ``` <details> <summary>Output:</summary> ``` mount: /mnt/partition0: unknown filesystem type 'LVM2_member'. dmesg(1) may have more information after failed mount system call. ``` </details>
2.0 MiB
Author
Owner
sudo vgchange -ay
Output:
  2 logical volume(s) in volume group "vgmint" now active
  2 logical volume(s) in volume group "pegasus-vg" now active

Source: the Unix Stack Exchange answer 678435

sudo lvscan
Output:
  ACTIVE            '/dev/vgmint/root' [<1.82 TiB] inherit
  ACTIVE            '/dev/vgmint/swap_1' [976.00 MiB] inherit
  ACTIVE            '/dev/pegasus-vg/root' [743.73 GiB] inherit
  ACTIVE            '/dev/pegasus-vg/swap_1' [976.00 MiB] inherit
sudo lvdisplay
Output:
  --- Logical volume ---
  LV Path                /dev/vgmint/root
  LV Name                root
  VG Name                vgmint
  LV UUID                XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX
  LV Write Access        read/write
  LV Creation host, time mint, 2022-12-29 22:36:33 +0100
  LV Status              available
  # open                 0
  LV Size                <1.82 TiB
  Current LE             476128
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:4
   
  --- Logical volume ---
  LV Path                /dev/vgmint/swap_1
  LV Name                swap_1
  VG Name                vgmint
  LV UUID                XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX
  LV Write Access        read/write
  LV Creation host, time mint, 2022-12-29 22:36:33 +0100
  LV Status              available
  # open                 0
  LV Size                976.00 MiB
  Current LE             244
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:5
   
  --- Logical volume ---
  LV Path                /dev/pegasus-vg/root
  LV Name                root
  VG Name                pegasus-vg
  LV UUID                XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX
  LV Write Access        read/write
  LV Creation host, time pegasus, 2024-04-22 17:40:44 +0200
  LV Status              available
  # open                 1
  LV Size                743.73 GiB
  Current LE             190395
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:1
   
  --- Logical volume ---
  LV Path                /dev/pegasus-vg/swap_1
  LV Name                swap_1
  VG Name                pegasus-vg
  LV UUID                XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX
  LV Write Access        read/write
  LV Creation host, time pegasus, 2024-04-22 17:40:44 +0200
  LV Status              available
  # open                 2
  LV Size                976.00 MiB
  Current LE             244
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:2

do not help.

```bash sudo vgchange -ay ``` <details> <summary>Output:</summary> ``` 2 logical volume(s) in volume group "vgmint" now active 2 logical volume(s) in volume group "pegasus-vg" now active ``` </details> Source: [the Unix Stack Exchange answer 678435](https://unix.stackexchange.com/a/678435) ```bash sudo lvscan ``` <details> <summary>Output:</summary> ``` ACTIVE '/dev/vgmint/root' [<1.82 TiB] inherit ACTIVE '/dev/vgmint/swap_1' [976.00 MiB] inherit ACTIVE '/dev/pegasus-vg/root' [743.73 GiB] inherit ACTIVE '/dev/pegasus-vg/swap_1' [976.00 MiB] inherit ``` </details> ```bash sudo lvdisplay ``` <details> <summary>Output:</summary> ``` --- Logical volume --- LV Path /dev/vgmint/root LV Name root VG Name vgmint LV UUID XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX LV Write Access read/write LV Creation host, time mint, 2022-12-29 22:36:33 +0100 LV Status available # open 0 LV Size <1.82 TiB Current LE 476128 Segments 1 Allocation inherit Read ahead sectors auto - currently set to 256 Block device 253:4 --- Logical volume --- LV Path /dev/vgmint/swap_1 LV Name swap_1 VG Name vgmint LV UUID XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX LV Write Access read/write LV Creation host, time mint, 2022-12-29 22:36:33 +0100 LV Status available # open 0 LV Size 976.00 MiB Current LE 244 Segments 1 Allocation inherit Read ahead sectors auto - currently set to 256 Block device 253:5 --- Logical volume --- LV Path /dev/pegasus-vg/root LV Name root VG Name pegasus-vg LV UUID XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX LV Write Access read/write LV Creation host, time pegasus, 2024-04-22 17:40:44 +0200 LV Status available # open 1 LV Size 743.73 GiB Current LE 190395 Segments 1 Allocation inherit Read ahead sectors auto - currently set to 256 Block device 253:1 --- Logical volume --- LV Path /dev/pegasus-vg/swap_1 LV Name swap_1 VG Name pegasus-vg LV UUID XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX LV Write Access read/write LV Creation host, time pegasus, 2024-04-22 17:40:44 +0200 LV Status available # open 2 LV Size 976.00 MiB Current LE 244 Segments 1 Allocation inherit Read ahead sectors auto - currently set to 256 Block device 253:2 ``` </details> do not help.
Author
Owner

The Ask Ubuntu answer 1078061:

sudo vgrename 'XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX' my_unique_name
Output:
  Volume group "XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX" not found
  Cannot process volume group XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX
sudo modprobe dm-mod

does not help.

[The Ask Ubuntu answer 1078061](https://askubuntu.com/a/1078061): ```bash sudo vgrename 'XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX' my_unique_name ``` <details> <summary>Output:</summary> ``` Volume group "XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX" not found Cannot process volume group XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX ``` </details> ```bash sudo modprobe dm-mod ``` does not help.
Author
Owner
ls /dev/mapper/
control  luks-XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX  nvme0n1p5_crypt  pegasus--vg-root  pegasus--vg-swap_1  vgmint-root  vgmint-swap_1
sudo mount /dev/mapper/vgmint-root partition0/
Output:
mount: /mnt/partition0: can't read superblock on /dev/mapper/vgmint-root.
       dmesg(1) may have more information after failed mount system call.

Source: https://techglimpse.com/error-mount-unknown-filesystem-type-lvm2_member-fix/

```bash ls /dev/mapper/ ``` ``` control luks-XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX nvme0n1p5_crypt pegasus--vg-root pegasus--vg-swap_1 vgmint-root vgmint-swap_1 ``` ```bash sudo mount /dev/mapper/vgmint-root partition0/ ``` <details> <summary>Output:</summary> ``` mount: /mnt/partition0: can't read superblock on /dev/mapper/vgmint-root. dmesg(1) may have more information after failed mount system call. ``` </details> Source: https://techglimpse.com/error-mount-unknown-filesystem-type-lvm2_member-fix/
Author
Owner
sudo vgdisplay
Output:
  --- Volume group ---
  VG Name               vgmint
  System ID             
  Format                lvm2
  Metadata Areas        1
  Metadata Sequence No  3
  VG Access             read/write
  VG Status             resizable
  MAX LV                0
  Cur LV                2
  Open LV               0
  Max PV                0
  Cur PV                1
  Act PV                1
  VG Size               <1.82 TiB
  PE Size               4.00 MiB
  Total PE              476372
  Alloc PE / Size       476372 / <1.82 TiB
  Free  PE / Size       0 / 0   
  VG UUID               XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX
   
  --- Volume group ---
  VG Name               pegasus-vg
  System ID             
  Format                lvm2
  Metadata Areas        1
  Metadata Sequence No  3
  VG Access             read/write
  VG Status             resizable
  MAX LV                0
  Cur LV                2
  Open LV               2
  Max PV                0
  Cur PV                1
  Act PV                1
  VG Size               744.71 GiB
  PE Size               4.00 MiB
  Total PE              190647
  Alloc PE / Size       190639 / 744.68 GiB
  Free  PE / Size       8 / 32.00 MiB
  VG UUID               XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX
```bash sudo vgdisplay ``` <details> <summary>Output:</summary> ``` --- Volume group --- VG Name vgmint System ID Format lvm2 Metadata Areas 1 Metadata Sequence No 3 VG Access read/write VG Status resizable MAX LV 0 Cur LV 2 Open LV 0 Max PV 0 Cur PV 1 Act PV 1 VG Size <1.82 TiB PE Size 4.00 MiB Total PE 476372 Alloc PE / Size 476372 / <1.82 TiB Free PE / Size 0 / 0 VG UUID XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX --- Volume group --- VG Name pegasus-vg System ID Format lvm2 Metadata Areas 1 Metadata Sequence No 3 VG Access read/write VG Status resizable MAX LV 0 Cur LV 2 Open LV 2 Max PV 0 Cur PV 1 Act PV 1 VG Size 744.71 GiB PE Size 4.00 MiB Total PE 190647 Alloc PE / Size 190639 / 744.68 GiB Free PE / Size 8 / 32.00 MiB VG UUID XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX ``` </details>
Author
Owner
sudo vgrename 'XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX' my_unique_name
Output:
  Processing VG vgmint because of matching UUID XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX
  Error writing device /dev/mapper/luks-XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX at 8704 length 1536.
  WARNING: bcache_invalidate: block (6, 0) still dirty.
  Failed to write metadata to /dev/mapper/luks-XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX.
  Failed to write VG my_unique_name.
```bash sudo vgrename 'XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX' my_unique_name ``` <details> <summary>Output:</summary> ``` Processing VG vgmint because of matching UUID XXXXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXXXX Error writing device /dev/mapper/luks-XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX at 8704 length 1536. WARNING: bcache_invalidate: block (6, 0) still dirty. Failed to write metadata to /dev/mapper/luks-XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX. Failed to write VG my_unique_name. ``` </details>
Author
Owner
sudo mount -o ro /dev/mapper/vgmint-root partition0/
ls partition0/
Output:
bin                boot   dev  file.swap  lib    lib64              libx32      media  opt   root  sbin                srv  tmp                          usr
bin.usr-is-merged  cdrom  etc  home       lib32  lib.usr-is-merged  lost+found  mnt    proc  run   sbin.usr-is-merged  sys  tmpjcef-p2652132_scheme.tmp  var

Source: the Ask Ubuntu answer 296342

```bash sudo mount -o ro /dev/mapper/vgmint-root partition0/ ls partition0/ ``` <details> <summary>Output:</summary> ``` bin boot dev file.swap lib lib64 libx32 media opt root sbin srv tmp usr bin.usr-is-merged cdrom etc home lib32 lib.usr-is-merged lost+found mnt proc run sbin.usr-is-merged sys tmpjcef-p2652132_scheme.tmp var ``` </details> Source: [the Ask Ubuntu answer 296342](https://askubuntu.com/a/296342)
Author
Owner
tree benjamin
Output:
benjamin
├── Access-Your-Private-Data.desktop -> /usr/share/ecryptfs-utils/ecryptfs-mount-private.desktop
├── Desktop
│   ├── bens_folder
│   │   └── softwares
│   │       └── matrix-commander
│   │           └── data
│   └── YouTube-operational-API
└── README.txt -> /usr/share/ecryptfs-utils/ecryptfs-mount-private.txt

7 directories, 2 files
rm -R benjamin/Desktop/
rm: cannot remove 'benjamin/Desktop/': Read-only file system
```bash tree benjamin ``` <details> <summary>Output:</summary> ``` benjamin ├── Access-Your-Private-Data.desktop -> /usr/share/ecryptfs-utils/ecryptfs-mount-private.desktop ├── Desktop │   ├── bens_folder │   │   └── softwares │   │   └── matrix-commander │   │   └── data │   └── YouTube-operational-API └── README.txt -> /usr/share/ecryptfs-utils/ecryptfs-mount-private.txt 7 directories, 2 files ``` </details> ```bash rm -R benjamin/Desktop/ ``` ``` rm: cannot remove 'benjamin/Desktop/': Read-only file system ```
Author
Owner
cat ../../usr/share/ecryptfs-utils/ecryptfs-mount-private.txt
Output:
THIS DIRECTORY HAS BEEN UNMOUNTED TO PROTECT YOUR DATA.

From the graphical desktop, click on:
 "Access Your Private Data"

or

From the command line, run:
 ecryptfs-mount-private
ecryptfs-mount-private
ERROR: Encrypted private directory is not setup properly
```bash cat ../../usr/share/ecryptfs-utils/ecryptfs-mount-private.txt ``` <details> <summary>Output:</summary> ``` THIS DIRECTORY HAS BEEN UNMOUNTED TO PROTECT YOUR DATA. From the graphical desktop, click on: "Access Your Private Data" or From the command line, run: ecryptfs-mount-private ``` </details> ```bash ecryptfs-mount-private ``` ``` ERROR: Encrypted private directory is not setup properly ```
Author
Owner
Access-Your-Private-Data.desktop:
[Desktop Entry]
_Name=Access Your Private Data
_GenericName=Access Your Private Data
Exec=/usr/bin/ecryptfs-mount-private
Terminal=true
Type=Application
Categories=System;Security;
X-Ubuntu-Gettext-Domain=ecryptfs-utils
<details> <summary><code>Access-Your-Private-Data.desktop</code>:</summary> ``` [Desktop Entry] _Name=Access Your Private Data _GenericName=Access Your Private Data Exec=/usr/bin/ecryptfs-mount-private Terminal=true Type=Application Categories=System;Security; X-Ubuntu-Gettext-Domain=ecryptfs-utils ``` </details>
Author
Owner
sudo ecryptfs-recover-private
Output:
INFO: Searching for encrypted private directories (this might take a while)...
find: ‘/run/user/1000/doc’: Permission denied
find: ‘/run/user/1000/gvfs’: Permission denied

stuck in both home/ and home/benjamin/.

```bash sudo ecryptfs-recover-private ``` <details> <summary>Output:</summary> ``` INFO: Searching for encrypted private directories (this might take a while)... find: ‘/run/user/1000/doc’: Permission denied find: ‘/run/user/1000/gvfs’: Permission denied ``` </details> stuck in both `home/` and `home/benjamin/`.
Author
Owner

Searching on DuckDuckGo and Google "ERROR: Encrypted private directory is not setup properly".

sudo ecryptfs-mount-private /mnt/partition0/home/.ecryptfs/benjamin/.Private
ERROR: Encrypted private directory is not setup properly

Source: the Ask Ubuntu question 859898

does not work even if use relative path and add trailing /.

Searching on DuckDuckGo and Google `"ERROR: Encrypted private directory is not setup properly"`. ```bash sudo ecryptfs-mount-private /mnt/partition0/home/.ecryptfs/benjamin/.Private ``` ``` ERROR: Encrypted private directory is not setup properly ``` Source: [the Ask Ubuntu question 859898](https://askubuntu.com/q/859898) does not work even if use relative path and add trailing `/`.
Author
Owner

https://forums.linuxmint.com/viewtopic.php?t=315207 looks too complicated as far as I remember.

https://forums.linuxmint.com/viewtopic.php?t=315207 looks too complicated as far as I remember.
Author
Owner
sudo ecryptfs-recover-private benjamin
Output:
INFO: Found [benjamin].
Try to recover this directory? [Y/n]: Y
INFO: Could not find your wrapped passphrase file.
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:
sudo ecryptfs-recover-private .ecryptfs/benjamin/
Output:
INFO: Found [.ecryptfs/benjamin/].
Try to recover this directory? [Y/n]: Y
INFO: Could not find your wrapped passphrase file.
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:
```bash sudo ecryptfs-recover-private benjamin ``` <details> <summary>Output:</summary> ``` INFO: Found [benjamin]. Try to recover this directory? [Y/n]: Y INFO: Could not find your wrapped passphrase file. 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: ``` </details> ```bash sudo ecryptfs-recover-private .ecryptfs/benjamin/ ``` <details> <summary>Output:</summary> ``` INFO: Found [.ecryptfs/benjamin/]. Try to recover this directory? [Y/n]: Y INFO: Could not find your wrapped passphrase file. 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: ``` </details>
Author
Owner
sudo ecryptfs-recover-private home/.ecryptfs/benjamin/.Private/
Output:
INFO: Found [home/.ecryptfs/benjamin/.Private/].
Try to recover this directory? [Y/n]: Y
INFO: Found your wrapped-passphrase
Do you know your LOGIN passphrase? [Y/n] 
INFO: Enter your LOGIN passphrase...
Passphrase: 
Inserted auth tok with sig [XXXXXXXXXXXXXXXX] into the user session keyring
mount: /tmp/ecryptfs.XXXXXXXX: mount(2) system call failed: No such file or directory.
       dmesg(1) may have more information after failed mount system call.
ERROR: Failed to mount private data at [/tmp/ecryptfs.XXXXXXXX].

Source: the Ask Ubuntu answer 766227

Same error when run again.

sudo ls -lah /tmp/ecryptfs.XXXXXXXX/
total 24K
drwx------  2 root root 4.0K Sep 11 21:28 .
drwxrwxrwt 24 root root  20K Sep 11 21:28 ..

sudo dmesg does not seem clearly useful.

home/benjamin/ content has not changed.

```bash sudo ecryptfs-recover-private home/.ecryptfs/benjamin/.Private/ ``` <details> <summary>Output:</summary> ``` INFO: Found [home/.ecryptfs/benjamin/.Private/]. Try to recover this directory? [Y/n]: Y INFO: Found your wrapped-passphrase Do you know your LOGIN passphrase? [Y/n] INFO: Enter your LOGIN passphrase... Passphrase: Inserted auth tok with sig [XXXXXXXXXXXXXXXX] into the user session keyring mount: /tmp/ecryptfs.XXXXXXXX: mount(2) system call failed: No such file or directory. dmesg(1) may have more information after failed mount system call. ERROR: Failed to mount private data at [/tmp/ecryptfs.XXXXXXXX]. ``` Source: [the Ask Ubuntu answer 766227](https://askubuntu.com/a/766227) Same error when run again. ```bash sudo ls -lah /tmp/ecryptfs.XXXXXXXX/ ``` ``` total 24K drwx------ 2 root root 4.0K Sep 11 21:28 . drwxrwxrwt 24 root root 20K Sep 11 21:28 .. ``` </details> `sudo dmesg` does not seem clearly useful. `home/benjamin/` content has not changed.
Author
Owner
mount -t ecryptfs benjamin/.Private /mnt/iso0/
Output:
Select key type to use for newly created files: 
 1) passphrase
 2) tspi
Selection: 1
Passphrase:

Source: the Ask Ubuntu answer 1088709

```bash mount -t ecryptfs benjamin/.Private /mnt/iso0/ ``` <details> <summary>Output:</summary> ``` Select key type to use for newly created files: 1) passphrase 2) tspi Selection: 1 Passphrase: ``` </details> Source: [the Ask Ubuntu answer 1088709](https://askubuntu.com/a/1088709)
Author
Owner
mount -t ecryptfs

does not return anything even with sudo.

```bash mount -t ecryptfs ``` does not return anything even with `sudo`.
Author
Owner
sudo ecryptfs-insert-wrapped-passphrase-into-keyring home/benjamin/.ecryptfs/wrapped-passphrase
Output:
Passphrase: 
Error: Unwrapping passphrase and inserting into the user session keyring failed [-5]
Info: Check the system log for more information from libecryptfs

Source: the Ask Ubuntu answer 679565

I tried 3 times.

```bash sudo ecryptfs-insert-wrapped-passphrase-into-keyring home/benjamin/.ecryptfs/wrapped-passphrase ``` <details> <summary>Output:</summary> ``` Passphrase: Error: Unwrapping passphrase and inserting into the user session keyring failed [-5] Info: Check the system log for more information from libecryptfs ``` </details> Source: [the Ask Ubuntu answer 679565](https://askubuntu.com/a/679565) I tried 3 times.
Author
Owner
ecryptfs-unwrap-passphrase .ecryptfs/wrapped-passphrase 
Output:
Passphrase: 
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
```bash ecryptfs-unwrap-passphrase .ecryptfs/wrapped-passphrase ``` <details> <summary>Output:</summary> ``` Passphrase: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX ``` </details>
Author
Owner

https://vtvz.me/blog/ecryptfs-recovery-error/

sudo ecryptfs-insert-wrapped-passphrase-into-keyring .ecryptfs/wrapped-passphrase
Output:
Passphrase: 
Inserted auth tok with sig [XXXXXXXXXXXXXXXX] into the user session keyring
sudo ecryptfs-recover-private .Private/
Output:
INFO: Found [.Private/].
Try to recover this directory? [Y/n]:  
INFO: Found your wrapped-passphrase
Do you know your LOGIN passphrase? [Y/n] 
INFO: Enter your LOGIN passphrase...
Passphrase: 
Inserted auth tok with sig [XXXXXXXXXXXXXXXX] into the user session keyring
mount: /tmp/ecryptfs.XXXXXXXX: mount(2) system call failed: No such file or directory.
       dmesg(1) may have more information after failed mount system call.
ERROR: Failed to mount private data at [/tmp/ecryptfs.XXXXXXXX].
 echo -n "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX" | ecryptfs-add-passphrase --fnek -
Output:
Inserted auth tok with sig [XXXXXXXXXXXXXXXX] into the user session keyring
Inserted auth tok with sig [XXXXXXXXXXXXXXXX] into the user session keyring
sudo ecryptfs-recover-private .Private/
Output:
INFO: Found [.Private/].
Try to recover this directory? [Y/n]: 
INFO: Found your wrapped-passphrase
Do you know your LOGIN passphrase? [Y/n] 
INFO: Enter your LOGIN passphrase...
Passphrase: 
Inserted auth tok with sig [XXXXXXXXXXXXXXXX] into the user session keyring
INFO: Success!  Private data mounted at [/tmp/ecryptfs.XXXXXXXX].

/tmp/ecryptfs.XXXXXXXX contains correctly my files.

https://vtvz.me/blog/ecryptfs-recovery-error/ ```bash sudo ecryptfs-insert-wrapped-passphrase-into-keyring .ecryptfs/wrapped-passphrase ``` <details> <summary>Output:</summary> ``` Passphrase: Inserted auth tok with sig [XXXXXXXXXXXXXXXX] into the user session keyring ``` </details> ```bash sudo ecryptfs-recover-private .Private/ ``` <details> <summary>Output:</summary> ``` INFO: Found [.Private/]. Try to recover this directory? [Y/n]: INFO: Found your wrapped-passphrase Do you know your LOGIN passphrase? [Y/n] INFO: Enter your LOGIN passphrase... Passphrase: Inserted auth tok with sig [XXXXXXXXXXXXXXXX] into the user session keyring mount: /tmp/ecryptfs.XXXXXXXX: mount(2) system call failed: No such file or directory. dmesg(1) may have more information after failed mount system call. ERROR: Failed to mount private data at [/tmp/ecryptfs.XXXXXXXX]. ``` </details> ```bash echo -n "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX" | ecryptfs-add-passphrase --fnek - ``` <details> <summary>Output:</summary> ``` Inserted auth tok with sig [XXXXXXXXXXXXXXXX] into the user session keyring Inserted auth tok with sig [XXXXXXXXXXXXXXXX] into the user session keyring ``` </details> ```bash sudo ecryptfs-recover-private .Private/ ``` <details> <summary>Output:</summary> ``` INFO: Found [.Private/]. Try to recover this directory? [Y/n]: INFO: Found your wrapped-passphrase Do you know your LOGIN passphrase? [Y/n] INFO: Enter your LOGIN passphrase... Passphrase: Inserted auth tok with sig [XXXXXXXXXXXXXXXX] into the user session keyring INFO: Success! Private data mounted at [/tmp/ecryptfs.XXXXXXXX]. ``` </details> `/tmp/ecryptfs.XXXXXXXX` contains correctly my files.
Sign in to join this conversation.
No Label
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: Benjamin_Loison/linux#36
No description provided.