You are not logged in.
Hi everyone,
I'm hoping to get a sanity check/procedural advice before upgrading mkinitcpio from v40 to v41.
System setup
My system is a dual-boot arch laptop (2 arch OSes: arch1 and arch2).
- It uses systemd-boot instead of grub as the boot manager.
- Each OS is contained within its own LUKS container (arch1 -> arch1_luks, arch2 -> arch2_luks).
- Each LUKS contains its own LVM (arch1_luks -> arch1_lvm, arch2_luks -> arch2_lvm).
- Each OS is installed in it's own LVM (arch1 OS -> arch1_lvm), (arch2 OS -> arch2_lvm).
- Each OS has both the regular and LTS kernels installed.
- Each OS has a pacman hook that moves the initramfs and vmlinuz files from /boot to an appropriate boot folder (/boot/arch1, /boot/arch2) when pacman installs latest versions of the files. This is to make sure that arch1 and arch2 are not sharing the same files in /boot.
- Everything is working fine with both OSes as I write this.
Current mkinitcpio config
Arch1 currently has mkinitcpio v40 and I'm expecting it to upgrade to v41 next time I run pacman -Syu. I'm also expecting LUKS to fall over with v41 unless I prepare in advance.
Arch2 was installed after v41 was released so it's already running happily and (in my head at least) should be a viable template for configuring arch1.
Arch1 current configuration:
mkinitcpio.conf (The lines shown here are the only lines edited in the file. Everything else in the file are default values):
MODULES=(dm_mod)
HOOKS=(base udev autodetect microcode modconf kms keyboard keymap consolefont block encrypt lvm2 filesystems fsck)/boot/loader/entries/arch1.conf (arch1-lts.conf is essentially the same except it references LTS versions of files) :
title Arch1
linux /arch1/vmlinuz-linux
initrd /arch1/initramfs-linux.img
options cryptdevice=/dev/nvme0n1p2:arch1_vg root=/dev/arch1_vg/arch1_root rwArch2 current configuration:
mkinitcpio.conf. (The lines shown here are the only lines edited in the file. Everything else in the file are default values):
NOTE: This configuration works fine.
MODULES=(dm_mod)
HOOKS=(base systemd autodetect microcode modconf kms keyboard keymap block sd-encrypt lvm2 filesystems fsck)/boot/loader/entries/arch2.conf (arch2-lts.conf is essentially the same except it references LTS version of files):
title Arch2
linux /arch2/vmlinuz-linux
initrd /arch2/initramfs-linux.img
options root=/dev/arch2_vg/arch2_root rwMy plan for arch1
1. Backup /etc/mkinitcpio.conf, /boot/loader/entries/arch1.conf, /boot/loader/entries/arch1-lts.conf
2. Modify arch1 mkinitcpio.conf HOOKS to replicate arch2. Arch2 is a known working configuration so logically it should be fine in arch1.
3. Modify /boot/entries/arch1(-lts).conf to set sd-encrypt compliant options:
From
"options cryptdevice=/dev/nvme0n1p2:arch1_vg root=/dev/arch1_vg/arch1_root rw"To:
"options root=/dev/arch1_vg/arch1_root rw"4. Run sudo pacman -Syu.
5. Run sudo mkinitcpio -P to regenerate intramfs for both kernels.
6. Reboot and pray.
My questions
1. Does the proposed order of steps in the plan make sense? I'm not 100% sure if running pacman should be done earlier in the process.
2. Have I overlooked anything obvious?
Thanks in advance.
Offline
You can just keep the busybox setup, otherwise see https://bbs.archlinux.org/viewtopic.php?id=310004
Offline
Thanks for the link, Seth.
Since posting earlier I've been playing around with a similar config to what I have on my laptop in a virtualbox vm and finally got it working there. I'll give it a go on my laptop in the next day or two and see where i find myself.
Offline