[SOLVED] Upgrading 14.0 to 14.1 with encrypted disks (LUKS+LVM)
SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Upgrading 14.0 to 14.1 with encrypted disks (LUKS+LVM)
I have the LUKS+LVM setup as described in README_CRYPT.TXT.
I upgraded 14.0 to 14.1 following Pat's UPGRADE.TXT
I did build the initrd and ran lilo after that. However something must have gone wrong because when it boots it goes into a kernel panic. (Good thing I did this on the trial laptop...)
Is there any special instruction on how to upgrade when you have this setup? (ie LVM volume with /root and swap in encrypted /dev/sda2, /boot on unencrypted /dev/sda1)
I was able to manually enter the system by booting the installation disk then mounting the partition, VGs and the mapped drives. I chrooted into it and tried rebuilding initrd, however that did not work (I forgot the error message, this was done at work), even though I had the unencrypted boot partition mounted in /boot.
Anyway, this laptop is test so I am not too worried about recovering it as I can install the system from scratch there. But I don't want to touch the production machine before I know the upgrade will work!
Actually, thinking about it, if you're encrypting the LVM PV rather than the LVM LV then you shouldn't be hitting this issue. It's a problem that affects people who have an encrypted root partition, not an encrypted LVM PV, which sounds like what you have.
It might help if you give us a little more info about what you have in lilo.conf, and what mkinitrd command you used.
cat: /proc/partitions: No such file or directory
OK: /lib/modules/3.10.17/kernel/fs/mbcache.ko added.
OK: /lib/modules/3.10.17/kernel/fs/jbd2/jbd2.ko added.
OK: /lib/modules/3.10.17/kernel/fs/ext4/ext4.ko added.
OK: /lib/modules/3.10.17/kernel/drivers/usb/host/ehci-hcd.ko added.
OK: /lib/modules/3.10.17/kernel/drivers/usb/host/ehci-hcd.ko added.
OK: /lib/modules/3.10.17/kernel/drivers/usb/host/ehci-pci.ko added.
OK: /lib/modules/3.10.17/kernel/drivers/usb/host/uhci-pci.ko added.
OK: /lib/modules/3.10.17/kernel/drivers/hid/hid.ko added.
OK: /lib/modules/3.10.17/kernel/drivers/hid/hid-generic.ko added.
OK: /lib/modules/3.10.17/kernel/drivers/hid/hid.ko added.
OK: /lib/modules/3.10.17/kernel/drivers/hid/usbhid/usbhid.ko added.
cat: /proc/partitions: No such file or directory
26585 blocks
/boot/initrd.gz created.
Be sure to run lilo again if you use it.
I created /dev/cryptvg/root to fool lilo (since that volume is mounted outside this chroot), and then ran lilo.
exited chroot, removed volume, luksClose and rebooted.
No kernel panic this time, however it fails to mount /dev/cryptvg/root:
Code:
mount: mounting /dev/cryptvg/root on /mnt failed: No such file or directory
ERROR: No /sbin/init found on rootdev (or not mounted). Trouble ahead.
Note that I never got the prompt to enter the encryption password.
I guess I have to go back and use /dev/mapper/luksnnnn in lilo.conf for root ?
Any obvious flaws above?
exited chroot, removed volume, luksClose and rebooted.
yes I did vgremove on the volumes, so I can't try to sort this out anymore (should first learn LVM2 properly!)
But if you still have comments about this I would appreciate. I need to upgrade another laptop with the same configuration and I would like to do it successfully.
Oh well, it was indeed missing the "-C /dev/sda2" that was likely the problem this time.
Yes it is uk instead of en-gb ...
I cannot mark this solved, but I may go ahead and try the other laptop. I will need to do a full backup since I am not confident it will go without trouble.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.