K 10 svn:author V 7 mandree K 8 svn:date V 27 2020-04-04T15:41:26.794546Z K 7 svn:log V 970 net-mgmt/netdata rc script overhaul, fix termination, user config This script overhaul does the following: - Read "run as user" from the netdata configuration file, and use that to override the default user "netdata", in case it is not set in /etc/rc.conf* and friends. - Kill all children of the PID in the netdata_pid file, too, because 1.20.0 would leave some plugin processing lingering. - Timeout the termination after (configurable) 30 seconds and issue SIGKILL - Cleanup the netdata_pid file after stop, so that a subsequent start with a less privileged user (say, start as root, stop, start as netdata) will work properly. - Document all variables, including the all-new netdata_stop_maxwait, in the header of the script. - Quote parameter expansions where appropriate. PR: 235006 Reported by: Dries Michiels Reviewed by: Dries Michiels Approved by: maintainer timeout (mmohki@, ~ 1 year) END