Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

default configuration and systemd results in duplicate log messages #96

Closed
asciiprod opened this issue Apr 21, 2020 · 2 comments
Closed

Comments

@asciiprod
Copy link

nsd, per default, logs both to stderr and syslog. As systemd forwards
both into journal all messages are included twice.

Ideally one could make nsd just use syslog and nothing else but
this does not seem to be possible.

This bug has been filed in Debian as
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=803683

Also originally reported in https://www.nlnetlabs.nl/bugs-script/show_bug.cgi?id=4198

@asciiprod
Copy link
Author

Wouter, this is amazingly fast ;-)

@wcawijngaards
Copy link
Member

Thanks for the report, I added the option log-only-syslog, that you can enable. That should solve the duplicate log item issue. I do not want to change the default log outputs, because other users may depend on it. So this new item allows to choose between log both syslog and stderr, log to only the logfile (with the logfile option) or log only to syslog with the added log-only-syslog: yes option.

Before syslog takes effect, in the startup sequence, it uses stderr still. This is only when errors cause failure, mostly. But because syslog is not opened yet, that would only print to stderr and thus also no duplicates.

gearnode pushed a commit to gearnode/nsd that referenced this issue May 3, 2020
  that the default configuration and systemd results in duplicate
  log messages.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants