summaryrefslogtreecommitdiff
path: root/src/main.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2011-03-04 21:53:19 +0100
committerLennart Poettering <lennart@poettering.net>2011-03-04 21:53:19 +0100
commitd7ccca2e3f86feb81a48e243d8bad78814659a74 (patch)
tree93f0063f961ec21b31546778add98c3b1cfe5c21 /src/main.c
parent63a723f3a7caf4eb1bc46a3849f59f27337924b7 (diff)
main: introduce /etc/machine-id
This is supposed to play the same roles /var/lib/dbus/machine-id, however fixes a couple of problems: - It is available during early boot since it is stored in /etc - Removes the ID from the D-Bus context and moves it into a system context, thus hopefully lowering hesitation by people to use it. - It is generated at installation time. If the file is empty at boot time it will be mounted over with a randomly generated ID, which is not saved to disk. This is useful to support state-less machines with no transient or writable /etc configuration.
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/main.c b/src/main.c
index ef6e681771..a041a22eda 100644
--- a/src/main.c
+++ b/src/main.c
@@ -41,6 +41,7 @@
#include "kmod-setup.h"
#include "locale-setup.h"
#include "selinux-setup.h"
+#include "machine-id-setup.h"
#include "load-fragment.h"
#include "fdset.h"
#include "special.h"
@@ -1127,6 +1128,7 @@ int main(int argc, char *argv[]) {
kmod_setup();
hostname_setup();
+ machine_id_setup();
loopback_setup();
mkdir_p("/dev/.systemd/ask-password/", 0755);