View previous topic :: View next topic |
Author |
Message |
leonchik1976 Guru
Joined: 24 Jan 2010 Posts: 325
|
Posted: Tue Aug 11, 2020 5:09 am Post subject: Can't boot LUKS with LVM |
|
|
Trying to install system with lvm inside LUKS - but after booting, it stuck on "Loading initial ramdisk ..."
/dev/sda1 - /boot/efi
/dev/sda2 - /boot
/dev/sda3 (luks) -> inside it VG, with vg-swap and vg-gentoo Logical volumes
/etc/default/grub:
Code: | GRUB_CMDLINE_LINUX="dolvm crypt_root=UUID=<LUKS device UUID> init=/lib/systemd/systemd" |
/etc/fstab:
Code: | UUID=<EFI partition UUID> /boot/efi vfat defaults 0 0
UUID=<BOOT partition UUID> /boot ext4 defaults,noatime 0 2
UUID=<SWAP partition UUID> none swap sw 0 0
UUID=<ROOT partition UUID> / ext4 defaults,noatime 0 1 |
because no output from kernel - can't say where the problem, please your help, where to start debugging it?
checked several times kernel config - also compiled all required modules in-kernel, tried both genkernel-next & dracut, please your help |
|
Back to top |
|
|
DespLock n00b
Joined: 27 Jul 2020 Posts: 65
|
Posted: Tue Aug 11, 2020 4:00 pm Post subject: |
|
|
Hi,
first you need another paremter in your GRUB_CMDLINE_LINUX:
Code: |
root=UUID=<UUID root volume>
|
Second: a UUID is not a secret passphrase, it's just a unique ID. I guess you have compared the entries with
?
Third: you need to run genkernel with lvm/luks support like:
Code: |
genkernel --luks --lvm initramfs
|
Or enable them in your "genkernel.conf".
Fourth shouldn't your swap entry look like this:
Code: |
UUID=<SWAP partition UUID> swap swap sw 0 0
|
Pls check and let us know if it'sworking or not.
Last edited by DespLock on Tue Aug 11, 2020 4:12 pm; edited 1 time in total |
|
Back to top |
|
|
leonchik1976 Guru
Joined: 24 Jan 2010 Posts: 325
|
Posted: Tue Aug 11, 2020 4:07 pm Post subject: |
|
|
DespLock wrote: | Hi,
first you need another paremter in your GRUB_CMDLINE_LINUX:
Code: |
root=UUID=<UUID root volume>.
|
Second: a UUID is not a secret passphrase, it's just a unique ID. I guess you have compared the entries with
?
Third: you need to run genkernel with lvm/luks support like:
Code: |
genkernel --luks --lvm initramfs
|
Or enable them in your "genkernel.conf".
Fourth shouldn't your swap entry look like this:
Code: |
UUID=<SWAP partition UUID> swap swap sw 0 0
|
Pls check and let us know if it'sworking or not. |
Hi,
1. root=UUID - according to LUKS on LVM section in https://wiki.gentoo.org/wiki/Dracut, the "note" - is exactly my case - i already have root=UUID generated by grub itself, so i removed it from /etc/default/grub
2. Sure, UUID was taken from blkid
3. i ran genkernel --luks --lvm --udev --install initramfs
4. swap line was taken from handbook.
just to notice - exact the same installation works perfectly without LUKS - exactly the same - and it works, the only thing i changed in this installation, is LUKS part, and compiling required modules in-kernel from https://wiki.gentoo.org/wiki/Dm-crypt |
|
Back to top |
|
|
Whissi Retired Dev
Joined: 12 Jan 2011 Posts: 222
|
Posted: Wed Aug 12, 2020 10:44 am Post subject: |
|
|
You are mixing a lot.
- Are you using genkernel or genkernel-next? The latter is dead is going away soon.
- Dracut notes don't apply to genkernel.
- Are you only building initramfs with genkernel or both (kernel and initramfs)?
I think it would be easier to show us generated grub kernel command-line from /boot/grub/grub.cfg... _________________ Regards,
Whissi |
|
Back to top |
|
|
leonchik1976 Guru
Joined: 24 Jan 2010 Posts: 325
|
Posted: Wed Aug 12, 2020 10:55 am Post subject: |
|
|
Whissi wrote: | You are mixing a lot.
- Are you using genkernel or genkernel-next? The latter is dead is going away soon.
- Dracut notes don't apply to genkernel.
- Are you only building initramfs with genkernel or both (kernel and initramfs)?
I think it would be easier to show us generated grub kernel command-line from /boot/grub/grub.cfg... |
Doesn't matter if dracut or genkernel - in both case - when grub.cfg generated - "root=" appears anyway, so no need to add in /etc/default/grub - otherwise you finish with twice "root="
* From the beginning it looked for me like kernel itself issue, and not dracut/genkernel-next related - so what i did:
1. Took kernel configuration from minimal-iso installed cd - added everything that needed for crypt - system boots perfectly!
2. Upgraded kernel back to 5.8.0-r1 - with "make oldconfig" accepting all defaults - system boots perfectly!
now will re-configure kernel to match my needs, doing it slowly, hoping the problem is gone |
|
Back to top |
|
|
leonchik1976 Guru
Joined: 24 Jan 2010 Posts: 325
|
Posted: Fri Aug 14, 2020 1:22 pm Post subject: |
|
|
After some tests, i found that enabling "Simple framebuffer support" in kernel, resolves my original issue.
The weird part, that it won't boot only with full disk encryption, on just '/' on LVM without crypt, works fine without enabling "Simple framebuffer support"
Can someone explain me why, please? |
|
Back to top |
|
|
|