Nixos-rebuild switch --upgrade error directory contains user files. Symlinking may fail


#1

Anybody encounter the error during “nixos-rebuild switch --upgrade”

I am getting
unpacking channels…
building Nix…
building the system configuration…
updating GRUB 2 menu…
activating the configuration…
setting up /etc…
/etc/fonts directory contains user files. Symlinking may fail. at /nix/store/amhpx347b7n6m2bq24siw0qq27w3np8n-setup-etc.pl line 114.
/etc/zoneinfo directory contains user files. Symlinking may fail. at /nix/store/amhpx347b7n6m2bq24siw0qq27w3np8n-setup-etc.pl line 114.
/etc/kbd directory contains user files. Symlinking may fail. at /nix/store/amhpx347b7n6m2bq24siw0qq27w3np8n-setup-etc.pl line 114.
/etc/dbus-1 directory contains user files. Symlinking may fail. at /nix/store/amhpx347b7n6m2bq24siw0qq27w3np8n-setup-etc.pl line 114.
/etc/terminfo directory contains user files. Symlinking may fail. at /nix/store/amhpx347b7n6m2bq24siw0qq27w3np8n-setup-etc.pl line 114.
/etc/systemd/system-generators directory contains user files. Symlinking may fail. at /nix/store/amhpx347b7n6m2bq24siw0qq27w3np8n-setup-etc.pl line 114.
/etc/systemd/system directory contains user files. Symlinking may fail. at /nix/store/amhpx347b7n6m2bq24siw0qq27w3np8n-setup-etc.pl line 114.
/etc/systemd/user directory contains user files. Symlinking may fail. at /nix/store/amhpx347b7n6m2bq24siw0qq27w3np8n-setup-etc.pl line 114.
/etc/udev/rules.d directory contains user files. Symlinking may fail. at /nix/store/amhpx347b7n6m2bq24siw0qq27w3np8n-setup-etc.pl line 114.
/etc/profiles/per-user/mudrii directory contains user files. Symlinking may fail. at /nix/store/amhpx347b7n6m2bq24siw0qq27w3np8n-setup-etc.pl line 114.
reloading user units for mudrii…
setting up tmpfiles

NOTE: No manual files was added to any /etc folder


#2

I’ve just reverted https://github.com/NixOS/nixpkgs/pull/54980 which caused this. The warnings should go when this revert reaches channels