mirror of
https://github.com/systemd/systemd-stable.git
synced 2025-06-06 23:17:07 +03:00
mount: use /dev/.run as an early boot alias for /var/run
During early boot, mount a tmpfs to /dev/.run and then bind mount it to /var/run as soon as /var is available. This makes it possible for programs involved in early boot to put runtime data in /dev/.run which later on will show up in /var/run like any other. This can be used to solve the early-boot D-Bus problem: D-Bus may start up with its socket bound to /dev/.run/dbus/system_bus_socket and after /var it will also be available under the traditional name /var/run/dbus/system_bus_socket. This also is intended to be used as a better place for systemd, mount, mdadm, blkid, plymouth, bootchart and dracut runtime data, which is currently stored in various places in /dev/.xxx.
This commit is contained in:
parent
1de4d79bf5
commit
cc5524ecc6
@ -54,6 +54,7 @@ static const MountPoint mount_table[] = {
|
|||||||
{ "devtmpfs", "/dev", "devtmpfs", "mode=755", MS_NOSUID, true },
|
{ "devtmpfs", "/dev", "devtmpfs", "mode=755", MS_NOSUID, true },
|
||||||
{ "tmpfs", "/dev/shm", "tmpfs", "mode=1777", MS_NOSUID|MS_NODEV, true },
|
{ "tmpfs", "/dev/shm", "tmpfs", "mode=1777", MS_NOSUID|MS_NODEV, true },
|
||||||
{ "devpts", "/dev/pts", "devpts", "mode=620,gid=" STRINGIFY(TTY_GID), MS_NOSUID|MS_NOEXEC, false },
|
{ "devpts", "/dev/pts", "devpts", "mode=620,gid=" STRINGIFY(TTY_GID), MS_NOSUID|MS_NOEXEC, false },
|
||||||
|
{ "tmpfs", "/dev/.run", "tmpfs", "mode=755", MS_NOSUID|MS_NOEXEC|MS_NODEV, true },
|
||||||
{ "tmpfs", "/sys/fs/cgroup", "tmpfs", "mode=755", MS_NOSUID|MS_NOEXEC|MS_NODEV, true },
|
{ "tmpfs", "/sys/fs/cgroup", "tmpfs", "mode=755", MS_NOSUID|MS_NOEXEC|MS_NODEV, true },
|
||||||
{ "cgroup", "/sys/fs/cgroup/systemd", "cgroup", "none,name=systemd", MS_NOSUID|MS_NOEXEC|MS_NODEV, true },
|
{ "cgroup", "/sys/fs/cgroup/systemd", "cgroup", "none,name=systemd", MS_NOSUID|MS_NOEXEC|MS_NODEV, true },
|
||||||
};
|
};
|
||||||
|
@ -10,7 +10,7 @@ Description=Runtime Directory
|
|||||||
Before=local-fs.target
|
Before=local-fs.target
|
||||||
|
|
||||||
[Mount]
|
[Mount]
|
||||||
What=tmpfs
|
What=/dev/.run
|
||||||
Where=/var/run
|
Where=/var/run
|
||||||
Type=tmpfs
|
Type=bind
|
||||||
Options=mode=755,nosuid,nodev,noexec
|
Options=bind
|
||||||
|
Loading…
x
Reference in New Issue
Block a user