Skip to content

Latest commit

 

History

History
74 lines (45 loc) · 6.11 KB

installer.md

File metadata and controls

74 lines (45 loc) · 6.11 KB

Installer

The live ISO installs Garuda with Calamares, from the calamares-garuda package. garuda-tools generated its configuration at build time. image-builder ships it as static files in the live layer instead.

Configuration

The configuration files, relative to mkosi.images/live/mkosi.extra/:

Path Content
etc/calamares/settings.conf the module sequence, branding and general switches
etc/calamares/modules/<module>.conf one file per configured module
usr/share/calamares/branding/garuda/branding.desc product names, window size, sidebar colours

<module> is the Calamares module name, for example users.

Change a setting for all editions

Edit the file in mkosi.images/live/mkosi.extra/etc/calamares/.

Change a setting for one edition

Copy the file to the same path under mkosi.images/live/mkosi.profiles/<edition>/mkosi.extra/ and edit the copy. The copy replaces the shared file in that edition, see Common tasks#Override a shared file in one edition. As of November 2026, only dr460nized-gaming does this, with modules/users.conf for its extra groups.

Change the module sequence

Edit settings.conf. Each module in the exec part that needs settings has a file in modules/.

Validate a changed file

Check that a changed file is valid YAML before building, for example with yq:

$ yq eval . mkosi.images/live/mkosi.extra/etc/calamares/modules/users.conf >/dev/null

Then rebuild and test an installation, see Testing#Live ISO.

The codename in branding.desc is the placeholder @CODENAME@. mkosi.postinst.chroot of the live layer replaces it with DISTRIB_CODENAME from /etc/lsb-release of the garuda-lsb package.

Installation process

The installer works offline:

  1. The partition and mount modules create the Garuda btrfs subvolumes @, @home, @root, @srv, @cache, @log and @tmp. With Erase disk, the root partition gets the x86-64 root type of the Discoverable Partitions Specification and the label garuda (partitionLayout in partition.conf), so that the signed generic UKIs find it without root=. In manual partitioning, the type is up to the user.
  2. unpackfs copies /run/garuda/install, the root and desktop layers of the ISO, with rsync (sourcefs: "file").
  3. ghtcfg installs the drivers from the offline repository /opt/ght/pkg of the drivers layer.
  4. services-systemd only sets the graphical target. All other services come from the preset files, which were already applied in the copied layers.
  5. postcfg creates the pacman keyring of the new system and rebuilds the initramfs: it removes the microcode package of the other CPU vendor, which triggers the dracut pacman hook, or runs dracut-rebuild itself when the vendor is unknown.
  6. bootloader installs systemd-boot on the ESP at /efi (2 GiB in automatic partitioning, at least 1 GiB when an existing ESP is picked), writes /etc/kernel/cmdline and runs kernel-install add for every kernel, which builds the UKIs with the configuration in /etc/kernel/, see Architecture#systemd-boot. The new system carries no GRUB.
  7. shellprocess@snapshot creates the /.snapshots subvolume and a permanent snapper snapshot "Fresh install", pinned with the userdata sdboot=pin, then runs snapper-sdboot sync to add its boot entry. Failures do not stop the installation.
  8. preservefiles copies the installer log to /var/log/Calamares-install.log of the new system.

The initramfs images in /boot are built in the root layer and rebuilt by postcfg for the installed system. No separate dracut module runs.

Encryption

The UKIs sit on the ESP, which is not encrypted, and contain the initramfs. The luksbootkeyfile and dracutlukscfg modules are therefore not in the sequence: they create /crypto_keyfile.bin and put it into the initramfs, so anyone with the disk could read it from the ESP and unlock the root partition. GRUB needed the keyfile to avoid a second passphrase prompt after it had unlocked the encrypted /boot. With systemd-boot, the initramfs asks for the passphrase, from rd.luks.uuid= on the kernel command line, and fstab writes none as the key of /etc/crypttab.

The installed loader.conf has default @saved, set with loaderDefault of the patched bootloader module. systemd-boot starts the entry that booted last again, for example Windows. A snapshot picked at the boot menu would stay the default as well, so snapper-sdboot-reset-saved.service removes the saved entry when it names a snapshot. The next boot then starts the first entry, the newest kernel. One-shot boots with snapper-sdboot boot-once are never saved, see Architecture#Snapshot entries.

A failed boot ends in emergency mode. garuda-boot-failure.service of garuda-dracut-support then logs the failed units with priority emerg, which systemd-bsod shows full screen with a QR code of the message, in the initramfs and in the installed system. systemd-bsod does not run in virtual machines (ConditionVirtualization=no).

The installed loader.conf has editor no, so the kernel command line cannot be changed at the boot menu, for example to init=/bin/bash. Without Secure Boot this does not stop someone who can write to the ESP. To change the options, edit /etc/kernel/cmdline and rebuild the UKIs with kernel-install add for each kernel, or boot the live ISO when the system does not start.

Known issues

The installer supports offline installation only. The garuda-tools options for netinstall, OEM mode and ZFS are not ported.

See also