How can I mount an encrypted LVM partition?

Hi, I have a HP laptop with openSUSE Tumbleweed (TWD) and Windows 11 installed. Now I installed openSUSE Leap 16.0 additionally. During installation I could not give the mount points for my old home partition because the graphical installer offered no fitting partition type (no btrfs, no LVM, no NTFS). Now I am stuck with trying to mount my old home partition from TWD when Leap 16.0 is running.

Leap 16.0 is installed on /dev/nvme1n1/,
TWD and Win11 are installed on /dev/nvme0n1/
TWD is on an encrypted logical partition /dev/nvme0n1/p5 (“PV of system”)
The logical partition is divided into “home” (XFS LV), “root” (Btrfs LV), “swap” (Swap LV)

When Leap 16 is running, I can see the Windows 11 partition in the dolphin file manager and click on it, then enter my normal user password (why?) and it is mounted.
But I cannot see anything of the partition /dev/nvme0n1/p5 in dolphin.
The file /etc/fstab only shows the mounted partitions.

Thank you for your help!

lvm partition are listed in /dev/mapper/.
Open a terminal, type lsblk, verify the partition your Tumbleweed home should be on, unlock with sudo cryptsetup open /dev/<partition> tumbleweed-home, create mountpoint (could just be a directory named tumbleweed-home in your leap home dir) and mount with sudo mount /dev/mapper/tumbleweed-home /path/to/mountpoint.
Normally, that should at least let you access your files.
If your old home partition wasn’t encrypted you should be able to find it under /dev/mapper and mount from there without decrypting it first.

I think you get asked for your password because mounting is generally done by the root user. So authenticating again is neccessary just like it is when using sudo.

1 Like

Yeah! I’ve access to my data again.
Thanks for your help!

After the cryptsetup open. I could enter the passphrase and it was accepted. In lsblk I can now see my three twd partitions within the LVM:

nvme1n1>nvme1n1p5>tumbleweed>system-swap
nvme1n1>nvme1n1p5>tumbleweed>system-home
nvme1n1>nvme1n1p5>tumbleweed>system-root

The mounting then worked with (as root):

mkdir /home/twd
mount /dev/mapper/system-home /home/twd

I was puzzled until I realized, I have to omit the “tumbleweed” in the mount command, because system-home is directly shown in /dev/mapper/.

Once again, thank you for your help!

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.