diff --git a/net-dns/dnsmasq/files/dnsmasq-init-dhcp-r1 b/net-dns/dnsmasq/files/dnsmasq-init-dhcp-r1 index b7cab78..bfb0abc 100644 --- a/net-dns/dnsmasq/files/dnsmasq-init-dhcp-r1 +++ b/net-dns/dnsmasq/files/dnsmasq-init-dhcp-r1 @@ -3,7 +3,7 @@ # Distributed under the terms of the GNU General Public License, v2 or later # $Id$ -extra_started_commands="reload" +extra_started_commands="reload rotate" pidfile="/var/run/dnsmasq.pid" command="/usr/sbin/dnsmasq" @@ -28,3 +28,9 @@ reload() { kill -HUP $(cat "${pidfile}") eend $? } + +rotate() { + ebegin "Reopening ${RC_SVCNAME} log file" + kill -USR2 $(cat "${pidfile}") + eend $? +} diff --git a/net-dns/dnsmasq/files/dnsmasq-init-r2 b/net-dns/dnsmasq/files/dnsmasq-init-r2 index 38a59a8..bed1a35 100644 --- a/net-dns/dnsmasq/files/dnsmasq-init-r2 +++ b/net-dns/dnsmasq/files/dnsmasq-init-r2 @@ -3,7 +3,7 @@ # Distributed under the terms of the GNU General Public License, v2 or later # $Id$ -extra_started_commands="reload" +extra_started_commands="reload rotate" pidfile="/var/run/dnsmasq.pid" command="/usr/sbin/dnsmasq" @@ -22,3 +22,9 @@ reload() { kill -HUP $(cat "${pidfile}") eend $? } + +rotate() { + ebegin "Reopening ${RC_SVCNAME} log file" + kill -USR2 $(cat "${pidfile}") + eend $? +}