[OpenWrt-Devel] [PATCH 3/6] base-files: set kernel.core_pattern in sysctl.conf
Yousong Zhou
yszhou4tech at gmail.com
Tue Sep 1 08:14:43 EDT 2015
Move the pattern setting from netifd's service script to
/etc/sysctl.conf. Put the timestamp component '%t' just after
executable name '%e' for more natural order from output of ls command.
Signed-off-by: Yousong Zhou <yszhou4tech at gmail.com>
---
package/base-files/files/etc/sysctl.conf | 2 ++
package/network/config/netifd/files/etc/init.d/network | 1 -
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/package/base-files/files/etc/sysctl.conf b/package/base-files/files/etc/sysctl.conf
index 8f3de1a..2ea1f1a 100644
--- a/package/base-files/files/etc/sysctl.conf
+++ b/package/base-files/files/etc/sysctl.conf
@@ -1,4 +1,6 @@
kernel.panic=3
+kernel.core.pattern=/tmp/%e.%t.%p.%s.core
+
net.ipv4.conf.default.arp_ignore=1
net.ipv4.conf.all.arp_ignore=1
net.ipv4.ip_forward=1
diff --git a/package/network/config/netifd/files/etc/init.d/network b/package/network/config/netifd/files/etc/init.d/network
index 542fc08..bdadbbc 100755
--- a/package/network/config/netifd/files/etc/init.d/network
+++ b/package/network/config/netifd/files/etc/init.d/network
@@ -21,7 +21,6 @@ start_service() {
procd_set_param watch network.interface
[ -e /proc/sys/kernel/core_pattern ] && {
procd_set_param limits core="unlimited"
- echo '/tmp/%e.%p.%s.%t.core' > /proc/sys/kernel/core_pattern
}
procd_close_instance
}
--
1.7.10.4
_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
More information about the openwrt-devel
mailing list