]> git.ipfire.org Git - thirdparty/systemd.git/commit
units: use SuccessExitStatus to ignore syntax errors in tmpfiles
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Wed, 22 Nov 2017 13:18:25 +0000 (14:18 +0100)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Fri, 1 Dec 2017 17:58:54 +0000 (18:58 +0100)
commitcd9f5b68ce08375eb1d68a4ddaa7a24a5092d7ba
tree5ad7c72490ae123366efae336dd68cfdec22c078
parentd9daae55d5d7d7cfe4edcc70fb120f28d5ba5dc5
units: use SuccessExitStatus to ignore syntax errors in tmpfiles

This makes sense from the point of view of the whole distribution:
if there are some specific files that have syntax problems, or unknown
users or groups, or use unsupported features, failing the whole service
is not useful.

In particular, services with tmpfiles --boot should not be started after boot.
The premise of --boot is that there are actions which are only safe to do once
during boot, because the state evolves later through other means and re-running
the boot-time setup would destroy it. If services with --boot fail in the
initial transaction, they would be re-run later on when a unit which
(indirectly) depends on them is started, causing problems.

Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1507501.

(If we had a mode where a service would at most run once, and would not be
started in subsequent transactions, that'd be a good additional safeguard.
Using ExecStart=-... is a bit like that, but it causes all failure to be
ignored, which is too big of a hammer.)
units/systemd-tmpfiles-clean.service.in
units/systemd-tmpfiles-setup-dev.service.in
units/systemd-tmpfiles-setup.service.in