diff --git a/modules/system/boot/stage-2-init.sh b/modules/system/boot/stage-2-init.sh index 3f76b165a27..0cc09caebba 100644 --- a/modules/system/boot/stage-2-init.sh +++ b/modules/system/boot/stage-2-init.sh @@ -27,9 +27,10 @@ setPath "@path@" # Mount special file systems. mkdir -m 0755 -p /etc test -e /etc/fstab || touch /etc/fstab # to shut up mount +[ -s /etc/mtab ] && rm /etc/mtab # while installing a symlink is created (see man mount), if it's still there for whateever reason remove it +rm -f /etc/mtab* # not that we care about stale locks mkdir -m 0755 -p /proc mount -n -t proc none /proc -[ -s /etc/mtab ] && rm /etc/mtab # while installing a symlink is created (see man mount), if it's still there for whateever reason remove it rm -f /etc/mtab cat /proc/mounts > /etc/mtab