mirror of
https://github.com/NLnetLabs/unbound.git
synced 2025-12-23 00:00:51 -05:00
- Fix use-systemd readiness signalling, only when use-systemd is yes
and not in signal handler. git-svn-id: file:///svn/unbound/trunk@4797 be551aaa-1e26-0410-a405-d3ace91eadb9
This commit is contained in:
parent
ae1790b8e8
commit
40abe08ac8
2 changed files with 13 additions and 13 deletions
|
|
@ -182,15 +182,8 @@ static void
|
||||||
signal_handling_playback(struct worker* wrk)
|
signal_handling_playback(struct worker* wrk)
|
||||||
{
|
{
|
||||||
#ifdef SIGHUP
|
#ifdef SIGHUP
|
||||||
if(sig_record_reload) {
|
if(sig_record_reload)
|
||||||
# ifdef HAVE_SYSTEMD
|
|
||||||
sd_notify(0, "RELOADING=1");
|
|
||||||
# endif
|
|
||||||
worker_sighandler(SIGHUP, wrk);
|
worker_sighandler(SIGHUP, wrk);
|
||||||
# ifdef HAVE_SYSTEMD
|
|
||||||
sd_notify(0, "READY=1");
|
|
||||||
# endif
|
|
||||||
}
|
|
||||||
#endif
|
#endif
|
||||||
if(sig_record_quit)
|
if(sig_record_quit)
|
||||||
worker_sighandler(SIGTERM, wrk);
|
worker_sighandler(SIGTERM, wrk);
|
||||||
|
|
@ -657,15 +650,18 @@ daemon_fork(struct daemon* daemon)
|
||||||
|
|
||||||
/* Start resolver service on main thread. */
|
/* Start resolver service on main thread. */
|
||||||
#ifdef HAVE_SYSTEMD
|
#ifdef HAVE_SYSTEMD
|
||||||
|
if(daemon->cfg->use_systemd)
|
||||||
sd_notify(0, "READY=1");
|
sd_notify(0, "READY=1");
|
||||||
#endif
|
#endif
|
||||||
log_info("start of service (%s).", PACKAGE_STRING);
|
log_info("start of service (%s).", PACKAGE_STRING);
|
||||||
worker_work(daemon->workers[0]);
|
worker_work(daemon->workers[0]);
|
||||||
#ifdef HAVE_SYSTEMD
|
#ifdef HAVE_SYSTEMD
|
||||||
|
if(daemon->cfg->use_systemd) {
|
||||||
if (daemon->workers[0]->need_to_exit)
|
if (daemon->workers[0]->need_to_exit)
|
||||||
sd_notify(0, "STOPPING=1");
|
sd_notify(0, "STOPPING=1");
|
||||||
else
|
else
|
||||||
sd_notify(0, "RELOADING=1");
|
sd_notify(0, "RELOADING=1");
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
log_info("service stopped (%s).", PACKAGE_STRING);
|
log_info("service stopped (%s).", PACKAGE_STRING);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,7 @@
|
||||||
|
23 July 2018: Wouter
|
||||||
|
- Fix use-systemd readiness signalling, only when use-systemd is yes
|
||||||
|
and not in signal handler.
|
||||||
|
|
||||||
20 July 2018: Wouter
|
20 July 2018: Wouter
|
||||||
- Fix #4130: print text describing -dd and unbound-checkconf on
|
- Fix #4130: print text describing -dd and unbound-checkconf on
|
||||||
config file read error at startup, the errors may have been moved
|
config file read error at startup, the errors may have been moved
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue