]> git.ipfire.org Git - people/teissler/ipfire-2.x.git/blame - src/initscripts/init.d/mountkernfs
initscripts: Fix syntax error when mounting /run.
[people/teissler/ipfire-2.x.git] / src / initscripts / init.d / mountkernfs
CommitLineData
73d9a908
MT
1#!/bin/sh
2########################################################################
3# Begin $rc_base/init.d/mountkernfs
4#
5# Description : Mount proc and sysfs
6#
7# Authors : Gerard Beekmans - gerard@linuxfromscratch.org
8#
9# Version : 00.00
10#
11# Notes :
12#
13########################################################################
14
15. /etc/sysconfig/rc
16. ${rc_functions}
17
18case "${1}" in
19 start)
20 boot_mesg -n "Mounting kernel-based file systems:" ${INFO}
21
22 if ! mountpoint /proc &> /dev/null; then
23 boot_mesg -n " /proc" ${NORMAL}
3a3759c6 24 mount -n -t proc /proc /proc || failed=1
73d9a908
MT
25 fi
26
27 if ! mountpoint /sys &> /dev/null; then
28 boot_mesg -n " /sys" ${NORMAL}
3a3759c6 29 mount -n -t sysfs /sys /sys || failed=1
73d9a908
MT
30 fi
31
b8e2d108
AF
32 if ! mountpoint /run &> /dev/null; then
33 boot_mesg -n " /run" ${NORMAL}
fd75e5e7 34 mount -n -t tmpfs -o nosuid,nodev,mode=755 /run /run || failed=1
b8e2d108
AF
35 fi
36
73d9a908
MT
37 boot_mesg "" ${NORMAL}
38
39 (exit ${failed})
40 evaluate_retval
41 ;;
42
43 *)
44 echo "Usage: ${0} {start}"
45 exit 1
46 ;;
47esac
48
49# End $rc_base/init.d/mountkernfs