Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Can someone comment on how things like kernels, kernel modules, and bootloaders work in Guix? It seems like these sorts of things wouldn't be possible to handle in a purely functional manner since, for example, you can only install one bootloader to a disk, and you can only boot into one kernel.


Disclaimer: I haven't ever used Guix, but I've used NixOS which builds on the same roots.

Typically your total system-configuration can be divided into a few distinct parts: bootloader and filesystem-partitions, kernel and software.

These features are to some extent dependent on each other, but not in any way which breaks dependency management or causes conflict, and thus can mostly be treated distinctly.

Basically you configure A bootloader, not several. The configuration is about which one that is and where you put it. Depending on if you use UEFI or not, this is either 100% tied to the filesystem layout, or just 99%.

Then the rest of the tooling just uses that info to populate the boot menu. In functional terms, a bootloader should have no side-effects on the system booted, so as long it boots the system, you should be fine.

The kernel doesn't really care about what bootloader you use as, as long as it boots it with the correct parameters. You can have several kernel-configurations in parallell which are accessible from the same bootloader-menu, but as you say, you cannot be booted into several versions at the same time.

That's not really a real-world problem though, because software very rarely depend on a specific kernel-version, they just depend on having a kernel. If a package depends on specific kernel modules, it's free to add these as dependencies, which will be resolved.

This means you can have a 100% functionally constructed system on top of a few config-files, with minimal chance of crafting a configuration which is internally incompatible. If it is, the tooling will tell you, and your system build will fail.

You can also have several mututally incompatible configurations within the same filesystem and boot between or chroot into these. It's an incredibly powerful concept.

The only reason I'm not running NixOS today on my laptop is that I need 100% end-user finish with regard to a "just works" desktop, and I'm not willing to build that myself, one package at a time, with the limited spare-time I have.

So I appreciate and respect both NixOS and GUIX and the work being invested in them, but for now I run Fedora :)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: