installer-iso: force script stage 1 — systemd initrd has no findiso
terra booted the staged installer this time but dropped to an emergency shell: stage 1 mounted /sysroot, then timed out on /sysroot/nix/.ro-store waiting for /dev/disk/by-label/nixos-minimal-26.05-x86_64. findiso= is handled only in the scripted stage-1-init.sh, which loop-mounts the file the param points at and symlinks it to /dev/root. The systemd initrd — the default since 26.05 — has no findiso handling at all: iso-image.nix mounts /iso directly from /dev/disk/by-label/<volumeID>, a label that only exists when the ISO is the physical boot medium. Booted as kernel + initrd off the ESP with the iso as a plain file on another partition, that label never appears, so the store squashfs never mounts. The entire `install <config> localhost` path is built on findiso, so pin the installer to script stage 1. Verified: /iso device flips to /dev/root, root=LABEL=... is added to the params, the rebuilt initrd's /init is stage-1-init.sh and carries the findiso logic. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -145,6 +145,15 @@ kept its ssh host key. Run it after ANY change to the kexec paths.
|
||||
rather than `--print-boot-path` in that mode. `homelab-auto-install.service` deletes
|
||||
the leftover NVRAM entry as soon as it boots; both it and the script match the label
|
||||
`Homelab Installer` EXACTLY (a prefix match would delete the Windows or Limine entry).
|
||||
- **`installer-iso` must force `boot.initrd.systemd.enable = false`.** `findiso=` is a
|
||||
SCRIPT-stage-1 feature (`stage-1-init.sh` loop-mounts the file it points at and
|
||||
symlinks it to `/dev/root`). The systemd initrd — default since 26.05 — has NO findiso
|
||||
path: it mounts `/iso` straight from `/dev/disk/by-label/<volumeID>` (iso-image.nix),
|
||||
a label that only exists when the ISO is the physical boot medium. EFI-stub-booted off
|
||||
the ESP with the iso as a plain file on another fs, that label never appears; stage 1
|
||||
mounts `/sysroot` fine, then times out on `/sysroot/nix/.ro-store` waiting for
|
||||
`/dev/disk/by-label/nixos-minimal-…` and drops to an emergency shell. The whole
|
||||
`install <config> localhost` findiso path depends on script stage 1.
|
||||
- **The staging-dir guard must fail CLOSED, and `findmnt` needs `--nofsroot`**: on btrfs
|
||||
`findmnt -no SOURCE` prints `/dev/sdb2[/@]`, which `lsblk` cannot open, so a naive
|
||||
parent-device lookup comes back empty. Treating empty as "different disk" silently
|
||||
|
||||
Reference in New Issue
Block a user