24.05 install fails "swapon failed"

G’day,

I’m new to Nix and NixOS, but really impressed so far.

Using 23.11 the installer was great, but I’ve tried 24.05 on a couple of machines now. The installation fails “swapon failed to active swap”. This is repeatable across multiple machines, so I don’t think it’s machine dependent. Not sure the best way to file this issue.

Thanks,
Dave

Another thing I noticed is that on install NixOS creates /etc/nixos/configuration.nix, but this configuration.nix has an error that nix then complains about

building Nix…
building the system configuration…
trace: warning: The option services.xserver.xkbVariant' defined in /etc/nixos/configuration.nix’ has been renamed to services.xserver.xkb.variant'. trace: warning: The option services.xserver.layout’ defined in /etc/nixos/configuration.nix' has been renamed to services.xserver.xkb.layout’.

I had the same problem when I tried to install NixOS around three days ago. I had to install it via terminal commands instead of the graphical installer, only then the installation worked.

1 Like