![]() |
Problems booting from LUKS on top of LVM
Hello all, I'm new to this forum although I've been lurking for a long time now.
As the subject says, I'm having trouble booting a LUKS encrypted root filesystem inside LVM. The problem is that while booting the system doesn't ask for the passphrase and skips mounting the root filesystem thus failing to boot. I have a single HDD that I divided in 2 partitions, one for /boot and another for LVM. The LVM is divided in several partions (root, home and swap) each one encrypted with their own LUKS passphrase or key. I did all this setup while installing the system (debian), and everything worked flawlessly, but then I decided to upgrade to the testing branch and that updated my kernel. Now I can't boot using that newly kernel (however I still can use the old one). I've been googling and searching here for a long time and most of the solutions I found are for LVM inside LUKS, and my setup is the opposite, so they didn't work for me. As the GRUB commands are the same for both kernels and I added all lvm and crypt related modules to /etc/initramfs-tools/modules and I did not forget to run update-initramfs I suppose this has to do with something in the configuration, but I can't find where my mistake is. Any ideas on what to do or pointers to where to look for more info? I wanted to have LUKS inside LVM and not the other way so that later on I can add more hard disks without trouble. Thanks in advance! |
Also, if I copy /usr/share/initramfs-tools/hooks/lvm2 to /etc/initramfs-tools/hooks/lvm2, when I call update-initramfs I get an error about a symbolic link unable to be created because it already exists...
Maybe that's the problem? But I do not know how to solve it. I also copied the cryptsetup and udev hooks and I have some udev scripts in /etc/initramfs-tools/scripts/init-top and init-bottom Please anyone? EDIT: I found a line in the booting process that says: Begin: Loading essential drivers ... modprobe: module lvm2 not found in modules. dep Then divice-mapper kicks in and then it runs /scripts/init-premount and tries to mount the root filesystem but skips everything. If I wait a bit I get dropped to the initramfs console but just before that it tells me to check cryptopts=source= bootarg: cat /proc/cmdline or missing modules, devices: cat /proc/modules; ls /dev and something about module ehci-orion not found. In the initramfs console, if I run cat /proc/modules | grep -i lvm I get nothing :( Why isn't it being loaded?? |
I fixed it!
I found that the problem was LVM and not LUKS, so I duckduckgoed and found this post: http://forums.debian.net/viewtopic.php?t=105549 Where the OP said that he fixed it by editing this in /etc/default/grub: Quote:
|
All times are GMT -5. The time now is 01:42 PM. |