[systemd-devel] Rate limiting socket-activating services that fail to start

Zbigniew Jędrzejewski-Szmek zbyszek at in.waw.pl
Mon Jun 17 06:48:22 PDT 2013

On Sat, Jun 15, 2013 at 10:51:55AM +0400, Andrey Borzenkov wrote:
> I was testing behavior when syslog.service fails to start and found
> systemd taking 100% of CPU (core) time - 50% user, 50% system. See
> Is it possible to rate limit socket activated service? I do not see any
> parameters in systemd.unit or systemd.socket.
I don't think anything changes in this respect recently, so I suspect
the behaviour you are observing with v195 is still happening. This
looks like a bug, and one that we should fix. Apart from eating CPU,
it has the potential to generate a log of logs, which is something
that annoys people a lot.

> I tried to rate limit rsyslog.service itself but it did not help. While
> service itself *is* rate-limited (it is not attempted to be started
> again before timeout) systemd still attempts to permanently start
> service, busy looping at it.
> This is openSUSE 12.3 with systemd 195 + various back ported fixes.

In http://marc.info/?l=opensuse&m=137127774415206&w=2 there's this quote:
> (unfortunately those lines are not usually visible in "systemctl
> status", not sure why).
Just show them with -o verbose and look for any of
a) _SYSTEMD_UNIT=rsyslogd.service
b) _PID=1 and UNIT=rsyslogd.service
c) COREDUMP_UNIT=rsyslogd.service anb MESSAGE_ID=<coredump>

In those cases journalctl and systemctl will show the message.
In this case a) should apply.


More information about the systemd-devel mailing list