nixos-generate-config
generates duplicate boot.initrd.luks.devices...
entries which causes installation to fail
#38564
Labels
2.status: stale
https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md
Issue description
nixos-generate-config
generates duplicateboot.initrd.luks.devices...
entries inhardware-configuration.nix
if a LUKS-encrypted Btrfs partition contains multiple subvolumes.Steps to reproduce
Encrypt a partition using LUKS and create a Btrfs filesystem, as described in the manual.
Create two Btrfs subvolumes in the Btrfs filesystem, named
root
andhome
, and mount them as/mnt
and/mnt/home
, respectively.Run
nixos-generate-config --root /mnt
and inspect/mnt/etc/nixos/hardware-configuration.nix
. There should be two identical entries which setboot.initrd.luks.devices."crypted".device
.Run
nixos-install
. It should complain thatboot.initrd.luks.devices."crypted".device
is set multiple times and abort installation.Workaround
Edit
/mnt/etc/nixos/hardware-configuration.nix
and remove duplicate entries.Technical details
Graphical live CD, 64-bit Intel/AMD
The text was updated successfully, but these errors were encountered: