Last change
on this file since 11bb814 was 77aff82, checked in by William Harrington <kb0iic@…>, 11 years ago |
Add directory housing the scripts for the boot-method currently used in the systemd book.
|
-
Property mode
set to
100644
|
File size:
1.2 KB
|
Line | |
---|
1 | #!/bin/bash
|
---|
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 | . /tools/etc/sysconfig/rc
|
---|
16 | . ${rc_functions}
|
---|
17 |
|
---|
18 | case "${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}
|
---|
24 | mount -n -o nosuid,noexec,nodev -t proc proc /proc || failed=1
|
---|
25 | fi
|
---|
26 |
|
---|
27 | if ! mountpoint /sys >/dev/null; then
|
---|
28 | boot_mesg -n " /sys" ${NORMAL}
|
---|
29 | mount -n -o nosuid,noexec,nodev -t sysfs sys /sys || failed=1
|
---|
30 | fi
|
---|
31 | if ! mountpoint /run >/dev/null; then
|
---|
32 | boot_mesg -n " /run" ${NORMAL}
|
---|
33 | mount -n -o mode=0755,nosuid,nodev -t tmpfs run /run || failed=1
|
---|
34 | fi
|
---|
35 | if ! mountpoint /dev >/dev/null; then
|
---|
36 | boot_mesg -n " /dev" ${NORMAL}
|
---|
37 | mount -n -o mode=0755,nosuid -t devtmpfs dev /dev || failed=1
|
---|
38 | fi
|
---|
39 | (exit ${failed})
|
---|
40 |
|
---|
41 | mkdir -m 1777 /run/lock
|
---|
42 | mkdir -p /dev/{pts,shm}
|
---|
43 | ;;
|
---|
44 |
|
---|
45 | *)
|
---|
46 | echo "Usage: ${0} {start}"
|
---|
47 | exit 1
|
---|
48 | ;;
|
---|
49 | esac
|
---|
50 |
|
---|
51 | # End $rc_base/init.d/mountkernfs
|
---|
Note:
See
TracBrowser
for help on using the repository browser.