diff --git a/nixos/doc/manual/release-notes/rl-1909.xml b/nixos/doc/manual/release-notes/rl-1909.xml
index ca2f26ec4a82..4fe82e10ae6d 100644
--- a/nixos/doc/manual/release-notes/rl-1909.xml
+++ b/nixos/doc/manual/release-notes/rl-1909.xml
@@ -435,6 +435,14 @@
idiom or extract that anonymous mapping function to a named one. Both can still be used
but lib.forEach is preferred over lib.flip map.
+
+ The /etc/sysctl.d/nixos.conf file containing all the options set via
+ boot.kernel.sysctl was moved to
+ /etc/sysctl.d/60-nixos.conf, as
+ sysctl.d5
+ recommends prefixing all filenames in /etc/sysctl.d with a
+ two-digit number and a dash to simplify the ordering of the files.
+
diff --git a/nixos/modules/config/sysctl.nix b/nixos/modules/config/sysctl.nix
index 0c6a7e2431aa..112e5e744d4c 100644
--- a/nixos/modules/config/sysctl.nix
+++ b/nixos/modules/config/sysctl.nix
@@ -42,14 +42,14 @@ in
config = {
- environment.etc."sysctl.d/nixos.conf".text =
+ environment.etc."sysctl.d/60-nixos.conf".text =
concatStrings (mapAttrsToList (n: v:
optionalString (v != null) "${n}=${if v == false then "0" else toString v}\n"
) config.boot.kernel.sysctl);
systemd.services.systemd-sysctl =
{ wantedBy = [ "multi-user.target" ];
- restartTriggers = [ config.environment.etc."sysctl.d/nixos.conf".source ];
+ restartTriggers = [ config.environment.etc."sysctl.d/60-nixos.conf".source ];
};
# Enable hardlink and symlink restrictions. See