-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Description
Link: https://www.linode.com/docs/guides/install-nixos-on-linode/
Issue
When following these instructions, I ran into this error when running the NixOS installer nixos-install.
Error snippet:
The option fileSystems."/".device has conflicting definition values:
- configuration.nix: /dev/sda
- hardware-configuration.nix: /dev/disk/by-uuid/...
Suggested Fix
Recommend removing the 'Rewrite Device Identifiers' section and its code. You're defining the same option twice:
- hardware-configuration.nix (generated by nixos-generate-config) already sets
fileSystems."/".deviceto a stable path like/dev/disk/by-uuid/.... - The guide then has you set it again in configuration.nix to /dev/sda, which creates a conflict
The fix was to remove the fileSystems."/" block and swapDevices block that the guide tells you to add to /mnt/etc/nixos/configuration.nix. Leave the entries in /mnt/etc/nixos/hardware-configuration.nix as-is (UUID-based). Re-run nixos-install
There are potential overrides but it works fine without those configuration settings.
All other instructions worked fine, except the installer disk size which has already been reported in issues 7348 and 7361. Thanks! Great guide.