PowerDNS: Difference between revisions

From Lolly's Wiki
Jump to navigationJump to search
(Die Seite wurde neu angelegt: „Kategorie: DNS =PowerDNS Server= ==Logging with systemd and syslog-ng== 1. Tell the journald of systemd to forward messages to syslog: In <i>/etc/system…“)
 
No edit summary
Line 7: Line 7:
1. Tell the journald of systemd to forward messages to syslog:
1. Tell the journald of systemd to forward messages to syslog:
In <i>/etc/systemd/journald.conf</i> set it from
In <i>/etc/systemd/journald.conf</i> set it from
<source>
<source lang=bash>
#ForwardToSyslog=yes
#ForwardToSyslog=yes
</source>
</source>
to
to
<source>
<source lang=bash>
ForwardToSyslog=yes
ForwardToSyslog=yes
</source>
</source>


Then restart the journald
Then restart the journald
<source>
<source lang=bash>
# systemctl restart systemd-journald.service
# systemctl restart systemd-journald.service
</source>
</source>
Line 23: Line 23:


Change the part in <i>/etc/syslog-ng/syslog-ng.conf</i> from
Change the part in <i>/etc/syslog-ng/syslog-ng.conf</i> from
<source>
<source lang=bash>
source s_src {
source s_src {
       system();
       system();
Line 30: Line 30:
</source>
</source>
to
to
<source>
<source lang=bash>
source s_src {
source s_src {
       system();
       system();

Revision as of 20:10, 30 June 2016

Kategorie: DNS

PowerDNS Server

Logging with systemd and syslog-ng

1. Tell the journald of systemd to forward messages to syslog: In /etc/systemd/journald.conf set it from

#ForwardToSyslog=yes

to

ForwardToSyslog=yes

Then restart the journald

# systemctl restart systemd-journald.service

2. Tell syslog-ng to take the dev-log-socket from journald as input:

Change the part in /etc/syslog-ng/syslog-ng.conf from

source s_src {
       system();
       internal();
};

to

source s_src {
       system();
       internal();
       unix-dgram ("/run/systemd/journal/dev-log"); 
};