aboutsummaryrefslogtreecommitdiffstats
path: root/main/openrc/0003-sysctl.Linux.in-fix-for-busybox-sysctl.patch
diff options
context:
space:
mode:
Diffstat (limited to 'main/openrc/0003-sysctl.Linux.in-fix-for-busybox-sysctl.patch')
-rw-r--r--main/openrc/0003-sysctl.Linux.in-fix-for-busybox-sysctl.patch42
1 files changed, 42 insertions, 0 deletions
diff --git a/main/openrc/0003-sysctl.Linux.in-fix-for-busybox-sysctl.patch b/main/openrc/0003-sysctl.Linux.in-fix-for-busybox-sysctl.patch
new file mode 100644
index 0000000000..22f1a626d8
--- /dev/null
+++ b/main/openrc/0003-sysctl.Linux.in-fix-for-busybox-sysctl.patch
@@ -0,0 +1,42 @@
+From 67cea9c310c90198f7f788d6ac1a90b8ed57183c Mon Sep 17 00:00:00 2001
+From: Natanael Copa <ncopa@alpinelinux.org>
+Date: Wed, 17 Aug 2016 17:14:37 +0200
+Subject: [PATCH 3/7] sysctl.Linux.in: fix for busybox sysctl
+
+busybox sysctl does not support --system
+---
+ init.d/sysctl.Linux.in | 17 ++++++++++++++---
+ 1 file changed, 14 insertions(+), 3 deletions(-)
+
+diff --git a/init.d/sysctl.Linux.in b/init.d/sysctl.Linux.in
+index f5e0ab6..e1a1932 100644
+--- a/init.d/sysctl.Linux.in
++++ b/init.d/sysctl.Linux.in
+@@ -17,10 +17,21 @@ depend()
+
+ start()
+ {
+- local quiet
++ local quiet rc=0
+ yesno $rc_verbose || quiet=-q
+
+ ebegin "Configuring kernel parameters"
+- sysctl ${quiet} --system
+- eend $? "Unable to configure some kernel parameters"
++ set --
++ for i in /run/sysctl.d/*.conf \
++ /etc/sysctl.d/*.conf \
++ /usr/local/lib/sysctl.d/*.conf \
++ /usr/lib/sysctl.d/*.conf \
++ /lib/sysctl.d/*.conf \
++ /etc/sysctl.conf; do
++ if [ -e "$i" ]; then
++ sysctl ${quiet} -p "$i"
++ rc=$(( $rc + $? ))
++ fi
++ done
++ eend $rc "Unable to configure some kernel parameters"
+ }
+--
+2.9.3
+