mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-07-14 06:00:33 +03:00
grub: Do not check for duplicated devices in mirroredBoots on UEFI (#18625)
When Grub is to be used with UEFI, it is not going to write to any MBR of any disk. As such, it is safe to use multiple "nodev" device entries when mirroring the ESP partition to multiple disks. E.g.: ``` boot.loader.grub = { enable = true; version = 2; zfsSupport = true; efiSupport = true; mirroredBoots = [ { devices = [ "nodev" ]; path = "/boot1"; efiSysMountPoint = "/boot1"; } { devices = [ "nodev" ]; path = "/boot2"; efiSysMountPoint = "/boot2"; } { devices = [ "nodev" ]; path = "/boot3"; efiSysMountPoint = "/boot3"; } ]; }; boot.loader.efi.canTouchEfiVariables = true; ``` Fixes #18584
This commit is contained in:
parent
60f31c6077
commit
b12debc076
1 changed files with 1 additions and 1 deletions
|
@ -503,7 +503,7 @@ in
|
|||
+ "'boot.loader.grub.mirroredBoots' to make the system bootable.";
|
||||
}
|
||||
{
|
||||
assertion = all (c: c < 2) (mapAttrsToList (_: c: c) bootDeviceCounters);
|
||||
assertion = cfg.efiSupport || all (c: c < 2) (mapAttrsToList (_: c: c) bootDeviceCounters);
|
||||
message = "You cannot have duplicated devices in mirroredBoots";
|
||||
}
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue