diff options
author | Robby Workman <rworkman@slackbuilds.org> | 2013-06-11 17:46:20 -0500 |
---|---|---|
committer | Niels Horn <niels.horn@slackbuilds.org> | 2013-06-15 23:00:05 -0300 |
commit | 97b17aea081d7e613f5c7d8e26a83bfa900337e4 (patch) | |
tree | df58ccecae4842a23d07cb6ab30287fba6dfd695 /network/radvd/rc.radvd.new | |
parent | c5027f3395fb5833b8b8d8eb5ffde43ffb48d420 (diff) | |
download | slackbuilds-97b17aea081d7e613f5c7d8e26a83bfa900337e4.tar.gz |
network/radvd: Create piddir and chown before start()
Since the radvd daemon drops privileges when starting, and
it doesn't write its pidfile until *after* dropping privs,
it is unable to do so if /var/run/radvd does not already
exist with daemon:daemon ownership. Even if this directory
is created during packaging, there's no guarantee that it
will persist, as /var/run on tmpfs is quite common these
days (as that's how this problem was discovered here).
Signed-off-by: Robby Workman <rworkman@slackbuilds.org>
Diffstat (limited to 'network/radvd/rc.radvd.new')
-rw-r--r-- | network/radvd/rc.radvd.new | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/network/radvd/rc.radvd.new b/network/radvd/rc.radvd.new index 9fbc597893..a68c057eab 100644 --- a/network/radvd/rc.radvd.new +++ b/network/radvd/rc.radvd.new @@ -13,6 +13,8 @@ radvd_start() { if [ -x /usr/sbin/radvd ]; then echo "Starting radvd..." echo 1 > /proc/sys/net/ipv6/conf/all/forwarding + mkdir -p /var/run/radvd + chown daemon:daemon /var/run/radvd /usr/sbin/radvd -u daemon fi } |