aboutsummaryrefslogtreecommitdiffstats
path: root/package/netifd/files
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2011-10-26 18:30:55 +0000
committerFelix Fietkau <nbd@openwrt.org>2011-10-26 18:30:55 +0000
commit803c7edcb3dfbf34f591f75e420f387649708e55 (patch)
tree4e2228f83d3eb098c39b31ea02433bca23f94d61 /package/netifd/files
parent883272696f62f8596598809c3ec277fe8eff9e7b (diff)
downloadupstream-803c7edcb3dfbf34f591f75e420f387649708e55.tar.gz
upstream-803c7edcb3dfbf34f591f75e420f387649708e55.tar.bz2
upstream-803c7edcb3dfbf34f591f75e420f387649708e55.zip
netifd: if core dump support is enabled, use it. also add some delay after start to avoid race conditions with other init scripts
SVN-Revision: 28611
Diffstat (limited to 'package/netifd/files')
-rwxr-xr-xpackage/netifd/files/etc/init.d/netifd5
1 files changed, 5 insertions, 0 deletions
diff --git a/package/netifd/files/etc/init.d/netifd b/package/netifd/files/etc/init.d/netifd
index e1047e7a81..23b7186333 100755
--- a/package/netifd/files/etc/init.d/netifd
+++ b/package/netifd/files/etc/init.d/netifd
@@ -4,7 +4,12 @@ PIDFILE=/var/run/netifd.pid
start() {
stop
+ [ -e /proc/sys/kernel/core_pattern ] && {
+ ulimit -c unlimited
+ echo '/tmp/%e.%p.%s.%t.core' > /proc/sys/kernel/core_pattern
+ }
start-stop-daemon -S -b -m -p $PIDFILE -x /sbin/netifd
+ sleep 1
}
reload() {