[systemd-devel] help on syslog-ng and systemd-kmsg-syslogd.service
Mathieu Bridon
bochecha at fedoraproject.org
Mon Dec 12 02:39:37 PST 2011
On Mon, 2011-12-12 at 18:12 +0800, microcai wrote:
> Hi guys.
>
> I had this issue since the release of systemd-37.
>
> system start up hang on syslog-ng
>
> If I comment out ExecStartPre=/bin/systemctl stop systemd-kmsg-syslogd.service
> then system boots successfull. But, dbus-daemon keep on poluting my screens.
> dbus became quiet while I manully stop systemd-kmsg-syslogd.service.
>
> So, that's why we need "ExecStartPre=/bin/systemctl stop
> systemd-kmsg-syslogd.service" in the first place.
No, the why is so that systemd-kmsg-syslog leaves the /dev/log socket
alone, so that your syslog implementation can use it.
The fact that "dbus became quiet while [you] manually stop
systemd-kmsg-syslogd.service" is because once systemd-kmsg-syslog is
gone, the messages sent to /dev/log are not redirected to kmsg anymore,
and thus they don't appear on your tty anymore.
> Question is , why system hang when I have "ExecStartPre=/bin/systemctl stop
> systemd-kmsg-syslogd.service" in syslog-ng.service ?
I **think** it's because something is trying to write synchronously
to /dev/log, but there's nothing listening on it yet (since you stop
systemd-kmsg-syslogd).
My guess is that syslog-ng.service doesn't have StandardOutput=null, so:
- systemd sends its stdout to syslog
- but nothing is listening on syslog
- syslog-ng waits for something to ack its messages sent to /dev/log
- but nothing ever acks the messages, since that's syslog-ng's job, and
it's waiting for its messages to be acked.
Happened to me in the past. ;)
--
Mathieu
More information about the systemd-devel
mailing list