git.iko.soy/typeable/nixpkgs
on master help sign in
nixos/nscd: no longer need to wait for readiness

This postStart step was introduced on 2014-04-24 with the comment that "Nscd forks into the background before it's ready to accept connections." However, that was fixed upstream almost two months earlier, on 2014-03-03, with the comment that "This, along with setting the nscd service type to forking in its systemd configuration file, allows systemd to be certain that the nscd service is ready and is accepting connections." The fix was released several months later in glibc 2.20, which was merged in NixOS sometime before 15.09, so it certainly should be safe to remove this workaround by now.

commit93f185df6555de235e7d188682ea54767d8cfbc2 authorJamey Sharp <jamey@minilop.net> dateWed 3 Jul 2019, 12:26 (7 years ago) parent48afae7
1 file changed−9
nixos/modules/services/system/nscd.nix−9
nixos/modules/services/system/nscd.nix−9
@@ -75,15 +75,6 @@ in
7575 "${pkgs.glibc.bin}/sbin/nscd --invalidate hosts"
7676 ];
7777 };
78−
79− # Urgggggh... Nscd forks before opening its socket and writing
80− # its pid. So wait until it's ready.
81− postStart =
82− ''
83− while ! ${pkgs.glibc.bin}/sbin/nscd -g > /dev/null; do
84− sleep 0.2
85− done
86− '';
8778 };
8879
8980 };