diff options
author | Hannu Nyman <hannu.nyman@iki.fi> | 2016-02-03 18:51:17 +0200 |
---|---|---|
committer | Hannu Nyman <hannu.nyman@iki.fi> | 2016-02-03 19:00:14 +0200 |
commit | a62ff02b8dec94a8153b42677c3795dcb93a5e7b (patch) | |
tree | d040f7ad4cca701c36925246c10e1c67c1f0ebb1 | |
parent | 11d3b989504c57cd5a641fc0d2548e3a8bb5200a (diff) |
collectd: use procd
Change collectd to use procd for startup.
Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
-rw-r--r-- | utils/collectd/files/collectd.init | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/utils/collectd/files/collectd.init b/utils/collectd/files/collectd.init index 8204c38ac..727e020aa 100644 --- a/utils/collectd/files/collectd.init +++ b/utils/collectd/files/collectd.init @@ -1,15 +1,13 @@ #!/bin/sh /etc/rc.common -# Copyright (C) 2006-2011 OpenWrt.org +# Copyright (C) 2006-2016 OpenWrt.org START=80 -SERVICE_USE_PID=1 +USE_PROCD=1 -start() { - mkdir -m 0755 -p /var/lib/collectd - service_start /usr/sbin/collectd +start_service() { + procd_open_instance + procd_set_param command /usr/sbin/collectd -f + procd_close_instance } -stop() { - service_stop /usr/sbin/collectd -} |