Skip to contentSkip to conversation

busybox: minor fixes to S01logging bootscript

PATCH New Javier Viguera 2 participants 2 messages Nov 6, 2013

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 busybox: minor fixes to S01logging bootscript

* The PID file is not created unless the '-m' option is passed to start-stop-daemon.

* Remove the mark '-m 0' option as it's not supported by busybox's syslogd.

* Syslogd and Klogd forks to background by default giving as a result that the pid stored in the PID file is not correct. Let the background job be done by 'start-stop-daemon' by passing '-n' (foreground) to the daemons and '-b' to start-stop-daemon. This way the pid stored in the PID files is correct.

---
 package/busybox/S01logging | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
package/busybox/S01logging +2 -2
index 37a2c11..b7af2a7 100644
@@ -6,8 +6,8 @@
 case "$1" in
   start)
 	echo -n "Starting logging: "
-	start-stop-daemon -S -q -p /var/run/syslogd.pid --exec /sbin/syslogd -- -m 0
-	start-stop-daemon -S -q -p /var/run/klogd.pid --exec /sbin/klogd
+	start-stop-daemon -b -S -q -m -p /var/run/syslogd.pid --exec /sbin/syslogd -- -n
+	start-stop-daemon -b -S -q -m -p /var/run/klogd.pid --exec /sbin/klogd -- -n
 	echo "OK"
 	;;
   stop)
#1 lore raw

PATCH 1/1 busybox: minor fixes to S01logging bootscript

Quoted 5 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Javier" == Javier Viguera <[email protected]> writes:

* The PID file is not created unless the '-m' option is passed to start-stop-daemon.

Quoted 8 lines

* Remove the mark '-m 0' option as it's not supported by busybox's syslogd.

* Syslogd and Klogd forks to background by default giving as a result that the pid stored in the PID file is not correct. Let the background job be done by 'start-stop-daemon' by passing '-n' (foreground) to the daemons and '-b' to start-stop-daemon. This way the pid stored in the PID files is correct.

Committed, thanks.

Signature · 1 line
Bye, Peter Korsgaard