summaryrefslogtreecommitdiff
path: root/src/machine-id-setup.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2011-03-09 22:45:47 +0100
committerLennart Poettering <lennart@poettering.net>2011-03-09 22:45:47 +0100
commitb925e72633bf98438f56a140520e07ec8c959e46 (patch)
tree7daba41fbb22be20a8a094fa792407a036b26ff1 /src/machine-id-setup.c
parent29d958ce2ba49794fa92dd77b2f9a9bdc941f493 (diff)
dev: use /dev/.run/systemd as runtime directory, instead of /dev/.systemd
Diffstat (limited to 'src/machine-id-setup.c')
-rw-r--r--src/machine-id-setup.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/machine-id-setup.c b/src/machine-id-setup.c
index 65792e9b84..59a14249e4 100644
--- a/src/machine-id-setup.c
+++ b/src/machine-id-setup.c
@@ -142,20 +142,20 @@ int machine_id_setup(void) {
fd = -1;
/* Hmm, we couldn't write it? So let's write it to
- * /dev/.systemd/machine-id as a replacement */
+ * /dev/.run/systemd/machine-id as a replacement */
- mkdir_p("/dev/.systemd", 0755);
+ mkdir_p("/dev/.run/systemd", 0755);
- if ((r = write_one_line_file("/dev/.systemd/machine-id", id)) < 0) {
- log_error("Cannot write /dev/.systemd/machine-id: %s", strerror(-r));
+ if ((r = write_one_line_file("/dev/.run/systemd/machine-id", id)) < 0) {
+ log_error("Cannot write /dev/.run/systemd/machine-id: %s", strerror(-r));
- unlink("/dev/.systemd/machine-id");
+ unlink("/dev/.run/systemd/machine-id");
goto finish;
}
/* And now, let's mount it over */
- r = mount("/dev/.systemd/machine-id", "/etc/machine-id", "bind", MS_BIND|MS_RDONLY, NULL) < 0 ? -errno : 0;
- unlink("/dev/.systemd/machine-id");
+ r = mount("/dev/.run/systemd/machine-id", "/etc/machine-id", "bind", MS_BIND|MS_RDONLY, NULL) < 0 ? -errno : 0;
+ unlink("/dev/.run/systemd/machine-id");
if (r < 0)
log_error("Failed to mount /etc/machine-id: %s", strerror(-r));