SIGQUIT vs SIGTERM
Dag-Erling Smørgrav
des at des.no
Wed Oct 14 11:44:27 UTC 2015
Traditionally, Unix daemons will reload their configuration upon
receiving SIGHUP and terminate gracefully upon receiving SIGTERM.
Unbound follows this tradition, but in addition, it treats SIGINT
(Ctrl-C when not daemonized) and SIGQUIT (Ctrl-\ when not daemonized) as
equivalent to SIGTERM. The man page documents SIGQUIT as the correct
way to terminate Unbound.
Setting aside the question of wheter intercepting SIGQUIT is a good idea
(I don't think it is, but it's probably too late to change it), this
state of affairs seems to confuse users. Consider this FreeBSD bug
report from a user who claims that Unbound terminates cleanly when it
receives SIGQUIT, but not when it receives SIGTERM:
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=203580
In addition, some platforms don't even have SIGQUIT (cf r1097).
I therefore propose to change the man page so that it mentions SIGTERM
instead of SIGQUIT:
Index: doc/unbound.conf.5.in
===================================================================
--- doc/unbound.conf.5.in (revision 3504)
+++ doc/unbound.conf.5.in (working copy)
@@ -481,7 +481,7 @@
.fi
triggers a reload,
.nf
-kill \-QUIT `cat @UNBOUND_PIDFILE@`
+kill \-TERM `cat @UNBOUND_PIDFILE@`
.fi
gracefully terminates.
.TP
DES
--
Dag-Erling Smørgrav - des at des.no
More information about the Unbound-users
mailing list