From 643bfecc67504d3765307534307c818441553081 Mon Sep 17 00:00:00 2001 From: Tom Gundersen Date: Fri, 1 Apr 2011 15:30:25 +0200 Subject: /run: mount /run if it is not already mounted This is in accordance with the new "standard" agreed on by the major distros, and discussed on our mailinglists. This folder will be used by udev/mdadm and other tools rather than putting things in /dev/.XXX. In the future we might symlink /var/{run,lock} to /run/{,lock} as the other distros are intending to do. First, we would have to make sure that /var/{run,lock} can be mounted as tmpfs without problems. Signed-off-by: Tom Gundersen --- rc.sysinit | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/rc.sysinit b/rc.sysinit index e855e0d..1c1697d 100755 --- a/rc.sysinit +++ b/rc.sysinit @@ -16,10 +16,7 @@ run_hook sysinit_start # export standard PATH (will be overridden later when /etc/profile is sourced, but is usefull for UDev) export PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" -# mount /proc, /sys and our RAM /dev -/bin/mountpoint -q /proc || /bin/mount -n -t proc proc /proc -o nosuid,noexec,nodev -/bin/mountpoint -q /sys || /bin/mount -n -t sysfs sysfs /sys -o nosuid,noexec,nodev - +# mount /dev, /proc, /sys, /run (the api filesystems) if ! /bin/mountpoint -q /dev; then if grep -q devtmpfs /proc/filesystems 2>/dev/null; then /bin/mount -n -t devtmpfs udev /dev -o mode=0755,size=10M,nosuid @@ -28,6 +25,12 @@ if ! /bin/mountpoint -q /dev; then fi fi +/bin/mkdir -p /dev/{pts,shm} + +/bin/mountpoint -q /proc || /bin/mount -n -t proc proc /proc -o nosuid,noexec,nodev +/bin/mountpoint -q /sys || /bin/mount -n -t sysfs sysfs /sys -o nosuid,noexec,nodev +/bin/mountpoint -q /run || /bin/mount -n -t tmpfs tmpfs /run -o mode=755,size=10M,nosuid,noexec,nodev + # start up our mini logger until syslog takes over /sbin/minilogd -- cgit v1.2.3