Bug 53948 - systemd-tmpfiles-setup.service fails to create file under /run/lock on boot
Summary: systemd-tmpfiles-setup.service fails to create file under /run/lock on boot
Status: RESOLVED FIXED
Alias: None
Product: systemd
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
Hardware: All All
: medium normal
Assignee: systemd-bugs
QA Contact: systemd-bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-08-22 18:53 UTC by Ramana Kumar
Modified: 2014-06-25 09:38 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description Ramana Kumar 2012-08-22 18:53:13 UTC
With the following /etc/tmpfiles.d/clock.conf:
f /run/lock/clock - ramana users

I get this error (in journalctl) on boot:
systemd-tmpfiles: Failed to create file /run/lock/clock: No such file or directory

However, manually running systemctl restart systemd-tmpfiles-setup.service after boot up creates the file without an error.

The same error if I use this:
F /run/lock/clock - ramana users

Finally, if I use:
d /run/lock
f /run/lock/clock - ramana users

The file gets created on boot as desired, but I get a different error about conflicting lines for /run/lock.

What is the correct configuration? (The man page is unclear about whether f and F create parent directories.)

What is the correct behaviour?
I expect to be able to use the f configuration and get the file created without any errors.
Comment 1 Lennart Poettering 2013-01-15 01:20:51 UTC
Hmm, which distro is this?

/usr/lib/tmpfiles.d/legacy.conf is usually responsible for creating /run/lock
Comment 2 Ramana Kumar 2013-01-18 13:09:06 UTC
The distro is Parabola (a derivative of Arch Linux).
Comment 3 Zbigniew Jedrzejewski-Szmek 2013-12-26 16:56:28 UTC
It should probably work if you rename clock.conf to something that sorts after legacy.conf. E.g. x-clock.conf should work.
Comment 4 Lennart Poettering 2014-06-25 09:38:18 UTC
Versions in systemd git will automatically order creation of files by the prefix used. I.e. /a/b/c will always be created after /a/b, even if listed in the opposite order.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.