Is the LVMonLUKS tutorial up-to-date?

Hello

I am trying to follow this tutorial: LVMonLUKS – Discovery for UEFI

  • device: thinkpad x260
  • installer: endeavourOS gemini

I am following it precisely however there are issues and eventually it goes so off track that I gave up.

Problem 1: Mount point for boot partition ?

Step #02 instructs to create /dev/sda1 with mount point /boot/efi. However the installer guides me to use /efi instead. I follow the installer’s instructions. I don’t know if this is causing any problem later. I adjust following instructions to use /efi.

This way the temporary install works properly. I booted into the new system. I also did a full update using the Welcome popup to see if that helped any of the subsequent issues, which unfortunately it did not.

Problem 2: keyfile

$ sudo cryptsetup luksAddKey /dev/sda2 /mnt/crypto_keyfile.bin
Enter any existing passphrase: 
Failed to open keyfile

If I enter the wrong passphrase, it returns No key available with this passphrase. So I think I am not making some typo to cause this.

Problem 3: leafpad

It’s not a huge issue because I just use nano instead. But the tutorial instructs to use leafpad on various occasions which isn’t available on the Live Installer. It just points that the tutorial may not be up to date.

Problem 4: /etc/mkinitcpio.conf

in step #11:

sudo leafpad /mnt/etc/mkinitcpio.conf

Change the HOOKS=… line by adding lvm2 and resume (before filesystems).

HOOKS="base udev autodetect modconf block keyboard keymap encrypt lvm2 resume filesystems fsck"

Save and exit.

there is no such file. There is /mnt/etc/mkinitcpio.d/linux.preset.pacsave. Contents of this file:

#
# SPDX-License-Identifier: GPL-3.0-or-later

# mkinitcpio preset file for the 'linux' package on archiso

PRESETS=('archiso')

ALL_kver='/boot/vmlinuz-linux'
ALL_config='/etc/mkinitcpio.conf'

archiso_image="/boot/initramfs-linux.img"

It seems that in March 2024 some kind of change was made here. I find this thread, How to deal with new mkinitcpio update with GRUB microcode [solved] / System Administration / Arch Linux Forums. But not sure how to integrate with this tutorial.

My best guess was to create /mnt/etc/mkinitcpio.conf.d/mkinitcpio-custom.conf and add the HOOK line here. But why isn’t there already a HOOK line?

Problem #5

Step #13: /mnt/etc/default

sudo leafpad /mnt/etc/default/grub

The directory /mnt/etc/default contains files named keyboard, locale and useradd. No grub.

Should I create it?

I now feel that I am deviating so much from the tutorial that the tutorial cannot possibly be correct.

Any advice?

The tutorial is completely out-of-date.

I will remove it.

1 Like

well that’s good to know so I can stop working on it.

is there an alternative or I should just give up on the idea for now?

I think it may be pretty hard to do lvm on luks in the current installer. I would have to test to be sure though.

Is lvm a hard requirement for you?

Well I guess it can’t be. Would be nice.

Should I make a new thread, or is it hopeless?

Give me a minute and I will test it.

1 Like

Yeah, it doesn’t work.

There are some upstream Calamares issues that make this difficult. Notably, this and this. The first is a bug that makes LVM not work. The second is something that makes working around the bug difficult.

OK thanks for the time and clarity. I will install in the normal way, which worked fine before.

Maybe instead of fully deleting the original tutorial link, would it make sense to replace it with an explanatory note? I found various links to the tutorial. It is more informative to explain to the user that this isn’t straight forward to accomplish rather than leaving it mysterious.

At any rate, my question is answered. :smiley:

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