You are not logged in.
I have accepted that my new computer is an UEFI-only zone. I installed Void Linux on it: partition 1 is the vfat[fat16] containing efi "stuff"; partition 2 contains the Void root file system. When it boots, I am presented with the GRUB menu showing Void.
I now want to install Devuan 4.0 on partition 3, but I am wary of messing up. Does the netinstall.iso installer work as I would expect: detects the Void system in partition 2, and constructs a combined grub.conf with Void and Devuan choices?
When I say "wary" I mean terrified, as I wasted 2 days trying and failing to convert the system from UEFI to MBR.
All my previous computers over 2.5 decades have been MBR-based, so this is all very new to me.
Thanks.
Offline
If you choose Expert install, you will get the choice of installing grub or not. If you let the installer install grub, it will make a boot entry for Void. If you don't let it add the bootloader, you will need to reboot into Void and do whatever it is you do there to add Devuan to the boot menu.
With uefi, each system that installs a bootloader will create a directory on the efi partition without removing any previous directoryies. If you install the Devuan bootloader and then want to go back to letting Void boot the computer, you can remove the Devuan entry with efibootmgr. It will be removed from the list of bootable devices that efibootmgr shows you, but the directory will still be there. You would have to do something extraordinary to screw it up permanently.
Offline
Well, in EFI mode the two installations are completely independent from each other. There is no detection of another Linux, this only works with Windose. You will either have to use the computers BIOS Boot override key or set up a manual grub config. With the downside that you have to modify this with every new kernel manually, there will be no automatic configuration possible.
Apart from that: use manual partitioning, make sure you hit p3 for Chimaera. Note: I have made the experience that with the first boot past the install the efivars are not mounted. I am adding that to the fstab. There are threads about that here in the forum.
If you have further questions, please ask.
rolfie
Offline
With the downside that you have to modify this with every new kernel manually, there will be no automatic configuration possible.
The OP can add a custom menuentry in Void for Devuan that boots from the /vmlinuz & /initrd.img symlinks in the Devuan root partition that always point to the latest version:
menuentry 'Devuan' {
search.fs_uuid $uuid
linux /vmlinuz ro quiet root=UUID=$uuid
initrd /initrd.img
}
Replace $uuid with the actual (filesystem) UUID of the Devuan root partition and put that stanza at the end of the file at /etc/grub.d/40_custom in Void then run this command in Void:
# grub-mkconfig -o /boot/grub/grub.cfg
Brianna Ghey — Rest In Power
Offline
Thanks for the replies.
@fsmithred: it sounds like the Devuan installer does the right thing. To be safe, I will use rsync on both partitions and "sgdisk --backup" to save the partition table.
@rolfie: I didn't understand your reply [my fault].
@head_on_a_stick? your solution implies that, as long as I don't allow the Devuan installer to install the GRUB bootloader, then I can create my own complete menuentry script for Devuan and append it to the end of the Void grub.cfg file [running grub_install from Void]. That sort of implies that I can replace the Void supplied monster grub.cfg with a simpler:
menuentry 'Void 5.9.16 runit restart [sda2]' {
insmod gzio
insmod part_msdos
insmod ext2
set root='hd0,msdos2'
linux /boot/vmlinuz-5.9.16_1 root=/dev/sda2 rootfstype=ext2 quiet ro nosmt
initrd /boot/initramfs-5.9.16_1.img
}
which makes no reference to UEFI! Or am I missing something?
Last edited by jacksprat (2022-03-02 21:39:40)
Offline
Put your custom menuentry in /etc/grub.d/40_custom and then run the grub-mkconfig command to regenerate the menu. If you modify grub.cfg directly, your edits will be overwritten the next time the menu gets updated.
And if you have more than one hard disk, you're better off using UUIDs instead of /dev/sda2, in case the drives don't always come up in the same order.
set root='hd0,msdos2'
Really? Not 'hd0,gpt2'? You have msdos partition table with uefi instead of gpt?
Offline
If you wanted to replace the grub-mkconfig generated /boot/grub/grub.cfg in Void then you would have to disable whatever automation Void is using to run grub-mkconfig whenever the kernel is updated and instead edit the file manually yourself to point to the new kernel & initramfs images.
I don't use Void so I have no idea if they have an equivalent to De{vu,bi}an's kernel & initramfs symlinks in the root partition.
But you probably don't need the insmod stuff anyway. In my experience GRUB is pretty good at autoloading modules.
EDIT: looks like the Void grub package uses this script in /etc/kernel.d/ so you could replace that with your own script to change the kernel & initramfs image names to match the new, updated versions. I presume a .post suffix for the script would cause it to be applied after any kernel upgrade.
Last edited by Head_on_a_Stick (2022-03-02 22:54:55)
Brianna Ghey — Rest In Power
Offline
@fsmithred: thanks, I am not aware of what would modify my custom grub.cfg file between boots; on Void grub.cfg persists until I install a new kernel and then I manually revise it. Probably Devuan does something different.
I take your point about using UUIDs when multiple drives are present.
The 177 line grub.cfg file created for Void has does not contain the strings "msdos" or "gpt", but I can see that msdos->gpt would be right; I assume that files in /etc/grub.d/ are used by grub-mkconfig to create grub.cfg. Unfortunately, I can't find out what Devuan would put here without actually letting the installer load the bootloader. Lots of thinking needed. Maybe a few experiments.
I am probably making too much of a meal of this and should just rsync backup everything to USB drive and let the Devuan installer run bootloader as its last step.
Last edited by jacksprat (2022-03-03 00:45:04)
Offline
All the Devuan installer will do is add a new directory to the EFI system partition and add a new boot entry to the top of the list in the motherboard NVRAM. You can always re-instate the Void GRUB menu by placing it at the top instead:
efibootmgr -o xxxx,yyyy
Replace xxxx & yyyy with the boot numbers for Void & Devuan, respectively. Running efibootmgr with no arguments will list the current NVRAM boot entries and their order.
Brianna Ghey — Rest In Power
Offline