Hi, * Salvatore Bonaccorso [Fri Nov 25, 2022 at 02:07:25PM +0100]: > sysctl settings (e.g. /etc/sysctl.conf and others) are normally loaded > once at boot. If the module that implements some settings is no yet > loaded, those settings don't get applied. > > Various NFS modules support various sysctl settings. If they are loaded > after boot, they miss out. > > Add a new udev rule configuration to udev/rules.d/60-nfs.rules to apply > the relevant settings when the module is loaded. > > Placing it in the systemd directory similarly as the coice for the > original commit afc7132dfb21 ("systemd: Apply all sysctl settings when > NFS-related modules are loaded"). [...] > --- /dev/null > +++ b/systemd/60-nfs.rules > @@ -0,0 +1,21 @@ > +# Ensure all NFS systctl settings get applied when modules load > + > +# sunrpc module supports "sunrpc.*" sysctls > +ACTION=="add", SUBSYSTEM=="module", KERNEL=="sunrpc", \ > + RUN+="/sbin/sysctl -q --pattern ^sunrpc --system" [...] Thanks for taking care of this problem, Salvatore! AFAICT even latest busybox's sysctl does not support the `--pattern` option yet: | sysctl: unrecognized option '--pattern' | BusyBox v1.35.0 (Debian 1:1.35.0-4) multi-call binary. | [....] So any initramfs that uses busybox and its sysctl (like in Debian) and trying to apply above udev rules might fail? regards -mika-
Attachment:
signature.asc
Description: PGP signature