Describe the bug
nixos-install fails when using the boot.loader.systemd-boot.xbootldrMountPoint parameter.
Steps To Reproduce
Steps to reproduce the behaviour:
- Create a custom ISO with
nixpkgs-unstable
- Partition disk to use
a. a 512GB 8300 partition ext4 formatted mounted at /
b. a 4GB EF02 partition fat32 formatted mounted at /boot
c. a 512MB EF00 partition fat32 formatted mounted at /boot/efi
- Modify
configuration.nix to add the boot.loader.efi.efiSysMountPoint = "/boot/efi"; and boot.loader.systemd-boot.xbootldrMountPoint = "/boot"; lines
- Use
nixos-install
Expected behaviour
2 things here.
- I expected the nixos installer to raise an error and quit after the
bootctl install command failed. It raised an error and still continued with the installation. But that is not the reason I'm here.
- I'm unable to understand this
Partition has wrong PART_ENTRY_TYPE=c12a7328-f81f-11d2-ba4b-00a0c93ec93b for XBOOTLDR partition error. Also c12a7328-f81f-11d2-ba4b-00a0c93ec93b does not match the UUID of any of my partitions.
Screenshots
[nixos@nixos:/mnt]$ sudo nix-install
installing the boot loader...
setting up /etc...
Initializing machine ID from random generator.
/dev/nvme0n1p2: Partition has wrong PART_ENTRY_TYPE=c12a7328-f81f-11d2-ba4b-00a0c93ec93b for XBOOTLDR partition.
Traceback (most recent call last):
File "/nix/store/712p6sw61vw33f5dcqrf7ryv9gmg5lkg-systemd-boot/bin/systemd-boot-builder", line 394, in <module>
main()
File "/nix/store/712p6sw61vw33f5dcqrf7ryv9gmg5lkg-systemd-boot/bin/systemd-boot-builder", line 377, in main
install_bootloader(args)
File "/nix/store/712p6sw61vw33f5dcqrf7ryv9gmg5lkg-systemd-boot/bin/systemd-boot-builder", line 292, in install_bootloader
subprocess.check_call([f"{SYSTEMD}/bin/bootctl", f"--esp-path={EFI_SYS_MOUNT_POINT}"] + bootctl_flags + ["install"])
File "/nix/store/3v2ch16fkl50i85n05h5ckss8pxx6836-python3-3.11.8/lib/python3.11/subprocess.py", line 413, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['/nix/store/klc3y2c97sc22wsv1cjwf4dfwcws095l-systemd-255.2/bin/bootctl', '--esp-path=/boot/efi', '--boot-path=/boot', 'install']' returned non-zero exit status 1.
setting up /etc...
setting up /etc...
setting root password...
New password:
Retype new password:
passwd: password updated successfully
installation finished!
Additional context
Referencing this PR #285401, since that is the feature I'm trying to use.
I would've preferred to use ext4 for the /boot partition, and I did, but that too had failed, only to later realize systemd-boot in and of itself still doesn't have an ext4/btrfs/non-fat driver. (Ref)
I'm unsure if my partitioning scheme is incorrect, or if I need to add any additional configuration. Please do ask for any other information to help debug the issue.
Also, just a sidenote, I'm not using ext4 for /. I'm using BTRFS on LUKS. I mentioned ext4 for simplicity. But I don't think it should be relevant in this case. Please do ask for more information if needed.
Notify maintainers
@sdht0
Metadata
Please run nix-shell -p nix-info --run "nix-info -m" and paste the result.
[nixos@nixos:~]$ nix-shell -p nix-info --run "nix-info -m"
- system: `"x86_64-linux"`
- host os: `Linux 6.6.21, NixOS, 24.05 (Uakari), 24.05.20240312.0ad13a6`
- multi-user?: `yes`
- sandbox: `yes`
- version: `nix-env (Nix) 2.18.1`
- channels(root): `"nixos-24.05.20240312.0ad13a6"`
- nixpkgs: `/nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs`
Add a 👍 reaction to issues you find important.
Describe the bug
nixos-installfails when using theboot.loader.systemd-boot.xbootldrMountPointparameter.Steps To Reproduce
Steps to reproduce the behaviour:
nixpkgs-unstablea. a
512GB8300partitionext4formatted mounted at/b. a
4GBEF02partitionfat32formatted mounted at/bootc. a
512MBEF00partitionfat32formatted mounted at/boot/eficonfiguration.nixto add theboot.loader.efi.efiSysMountPoint = "/boot/efi";andboot.loader.systemd-boot.xbootldrMountPoint = "/boot";linesnixos-installExpected behaviour
2 things here.
bootctl installcommand failed. It raised an error and still continued with the installation. But that is not the reason I'm here.Partition has wrong PART_ENTRY_TYPE=c12a7328-f81f-11d2-ba4b-00a0c93ec93b for XBOOTLDR partitionerror. Alsoc12a7328-f81f-11d2-ba4b-00a0c93ec93bdoes not match the UUID of any of my partitions.Screenshots
Additional context
Referencing this PR #285401, since that is the feature I'm trying to use.
I would've preferred to use
ext4for the/bootpartition, and I did, but that too had failed, only to later realizesystemd-bootin and of itself still doesn't have an ext4/btrfs/non-fat driver. (Ref)I'm unsure if my partitioning scheme is incorrect, or if I need to add any additional configuration. Please do ask for any other information to help debug the issue.
Also, just a sidenote, I'm not using
ext4for/. I'm usingBTRFSonLUKS. I mentionedext4for simplicity. But I don't think it should be relevant in this case. Please do ask for more information if needed.Notify maintainers
@sdht0
Metadata
Please run
nix-shell -p nix-info --run "nix-info -m"and paste the result.Add a 👍 reaction to issues you find important.