mirror of
git://git.openwrt.org/openwrt/openwrt.git
synced 2024-12-12 01:44:54 +00:00
dbeb780ba4
We can use /etc/sysctl.d/* for package-supplied sysctl snippets, giving admins the option to use /etc/sysctl.conf to override settings. Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
10 lines
236 B
Bash
10 lines
236 B
Bash
#!/bin/sh
|
|
|
|
if [ "$ACTION" = add ]; then
|
|
for CONF in /etc/sysctl.d/*.conf /etc/sysctl.conf; do
|
|
[ ! -f "$CONF" ] && continue;
|
|
sed -ne "/^[[:space:]]*net\..*\.$DEVICENAME\./p" "$CONF" | \
|
|
sysctl -e -p - | logger -t sysctl
|
|
done
|
|
fi
|