[systemd-devel] tmpfiles chicken-egg problem

Ulrich Windl Ulrich.Windl at rz.uni-regensburg.de
Wed Aug 26 06:37:55 UTC 2020


Hi!

I see this problem in SLES12 (systemd-228-157.12.5.x86_64): On boot systemd tries to use LDAP to resolve user names, resulting in an error like this:
systemd-tmpfiles: nss-ldap: do_open: do_start_tls failed:stat=-1

Eventually:
systemd-tmpfiles: nss_ldap: could not search LDAP server - Server is unavailable

And:
systemd[1]: systemd-tmpfiles-setup.service: Main process exited, code=exited, status=1/FAILURE


Aboput 15 minutes later I see this message:
systemd[1]: Started Cleanup of Temporary Directories.

So Cleanup succeeds while setup failed?

OK, basically I have this problem: One of my services implicitly requires tmpfiles. So it fails when tmpfiles is unavailable.
However when I started tmpfiles manually (after network and thus LDAP are up), my service did not start automatically.
Should I add an explicit dependency for tmpfiles?

Also, can I re-trigger the tmpfiles once network (and LDAP) are up? (In a cluster software we had, yu would just reset the "failure flag", and then the software would try a restart (up to the next failure)

Regards,
Ulrich





More information about the systemd-devel mailing list