systemd PathExists triggers

Brian Murray brian at ubuntu.com
Wed Sep 30 17:42:19 UTC 2020


Recently there was a systemd change regarding PathExists for
systemd.path units that made systemd behave the way it was documented to
work. The effect being that if the PathExists or PathExistsGlob
condition is met the service is continually started which may not be the
behavior some packages expect as it didn't used to work that way.

As an example apport's autoreport service uses PathExistsGlob to check
for a .crash file and then calls whoopsie-upload-all which used to run
once when the .crash file appeared. As of Groovy whoopsie-upload-all was
called continuously thereby causing systemd to use 100% of your CPU[1].

While this is resolved for apport's case, the Foundation's team thought
it was worth mentioning as other package's services may also be
impacted.

An archive search[2] (thanks Seth!) was done of services which are
Type=oneshot or utilize a PathExists or PathExistsGlob. Briefly scanning
the list the following packages should probably be looked at:

mandos-client
ostree
python-diskimage-builder
ubuntu-report

[1] http://launchpad.net/bugs/1891657
[2] https://paste.ubuntu.com/p/k5Gj7rQ9FX/

Cheers,
--
Brian Murray



More information about the ubuntu-devel mailing list