init: create /run tmpfs in init

The filesystem options are set to match what systemd is using when
it would create the /run tmpfs, see src/core/mount-setup.c in
systemd source code.

Signed-off-by: Matthias Reichl <hias@horus.com>
This commit is contained in:
Matthias Reichl 2021-02-03 12:22:41 +01:00
parent df1905c9c2
commit cf763e204f

View File

@ -14,6 +14,7 @@
/usr/bin/busybox mkdir -p /flash /usr/bin/busybox mkdir -p /flash
/usr/bin/busybox mkdir -p /sysroot /usr/bin/busybox mkdir -p /sysroot
/usr/bin/busybox mkdir -p /storage /usr/bin/busybox mkdir -p /storage
/usr/bin/busybox mkdir -p /run
# temp mountpoint for updates # temp mountpoint for updates
/usr/bin/busybox mkdir -p /update /usr/bin/busybox mkdir -p /update
@ -22,6 +23,8 @@
/usr/bin/busybox mount -t devtmpfs devtmpfs /dev /usr/bin/busybox mount -t devtmpfs devtmpfs /dev
/usr/bin/busybox mount -t proc proc /proc /usr/bin/busybox mount -t proc proc /proc
/usr/bin/busybox mount -t sysfs sysfs /sys /usr/bin/busybox mount -t sysfs sysfs /sys
# /run options have to match what systemd uses by default
/usr/bin/busybox mount -t tmpfs -o mode=755,size=20%,nr_inodes=800k,nosuid,nodev,strictatime tmpfs /run
UPDATE_ROOT=/storage/.update UPDATE_ROOT=/storage/.update
UPDATE_DIR="$UPDATE_ROOT" UPDATE_DIR="$UPDATE_ROOT"