aboutsummaryrefslogtreecommitdiffstats
path: root/bootscripts
diff options
context:
space:
mode:
authorBruce Dubbs <bdubbs@linuxfromscratch.org>2011-08-30 22:54:52 +0000
committerBruce Dubbs <bdubbs@linuxfromscratch.org>2011-08-30 22:54:52 +0000
commit5bc19fc1e562db0a9587b355419076daa75788e2 (patch)
tree307afd70b29d9ed9db5ca6fafa48387e3ec8be1b /bootscripts
parentc0ad0ec4ad231d7d4d13e673db729393c0ada18d (diff)
Update to linux-3.0.4 and util-linux-2.20.
Fix minor bootscript problems. git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@9587 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689
Diffstat (limited to 'bootscripts')
-rw-r--r--bootscripts/lfs/init.d/cleanfs138
-rw-r--r--bootscripts/lfs/init.d/mountfs2
-rw-r--r--bootscripts/lfs/sysconfig/createfiles28
3 files changed, 84 insertions, 84 deletions
diff --git a/bootscripts/lfs/init.d/cleanfs b/bootscripts/lfs/init.d/cleanfs
index 09fd4d449..f480c40ce 100644
--- a/bootscripts/lfs/init.d/cleanfs
+++ b/bootscripts/lfs/init.d/cleanfs
@@ -30,87 +30,87 @@
# Function to create files/directory on boot.
create_files() {
- # Read in the configuration file.
- exec 9>&0 < /etc/sysconfig/createfiles
- while read name type perm usr grp dtype maj min junk
- do
- # Ignore comments and blank lines.
- case "${name}" in
- ""|\#*) continue ;;
- esac
+ # Read in the configuration file.
+ exec 9>&0 < /etc/sysconfig/createfiles
+ while read name type perm usr grp dtype maj min junk
+ do
+ # Ignore comments and blank lines.
+ case "${name}" in
+ ""|\#*) continue ;;
+ esac
- # Ignore existing files.
- if [ ! -e "${name}" ]; then
- # Create stuff based on its type.
- case "${type}" in
- dir)
- mkdir "${name}"
- ;;
- file)
- :> "${name}"
- ;;
- dev)
- case "${dtype}" in
- char)
- mknod "${name}" c ${maj} ${min}
- ;;
- block)
- mknod "${name}" b ${maj} ${min}
- ;;
- pipe)
- mknod "${name}" p
- ;;
- *)
- boot_mesg -n "\nUnknown device type: ${dtype}" ${WARNING}
- boot_mesg "" ${NORMAL}
- ;;
- esac
- ;;
- *)
- boot_mesg -n "\nUnknown type: ${type}" ${WARNING}
- boot_mesg "" ${NORMAL}
- continue
- ;;
- esac
+ # Ignore existing files.
+ if [ ! -e "${name}" ]; then
+ # Create stuff based on its type.
+ case "${type}" in
+ dir)
+ mkdir "${name}"
+ ;;
+ file)
+ :> "${name}"
+ ;;
+ dev)
+ case "${dtype}" in
+ char)
+ mknod "${name}" c ${maj} ${min}
+ ;;
+ block)
+ mknod "${name}" b ${maj} ${min}
+ ;;
+ pipe)
+ mknod "${name}" p
+ ;;
+ *)
+ boot_mesg -n "\nUnknown device type: ${dtype}" ${WARNING}
+ boot_mesg "" ${NORMAL}
+ ;;
+ esac
+ ;;
+ *)
+ boot_mesg -n "\nUnknown type: ${type}" ${WARNING}
+ boot_mesg "" ${NORMAL}
+ continue
+ ;;
+ esac
- # Set up the permissions, too.
- chown ${usr}:${grp} "${name}"
- chmod ${perm} "${name}"
- fi
- done
- exec 0>&9 9>&-
+ # Set up the permissions, too.
+ chown ${usr}:${grp} "${name}"
+ chmod ${perm} "${name}"
+ fi
+ done
+ exec 0>&9 9>&-
}
case "${1}" in
- start)
- boot_mesg -n "Cleaning file systems:" ${INFO}
+ start)
+ boot_mesg -n "Cleaning file systems:" ${INFO}
if [ "${SKIPTMPCLEAN}" = "" ]; then
- boot_mesg -n " /tmp" ${NORMAL}
- cd /tmp &&
- find . -xdev -mindepth 1 ! -name lost+found -delete || failed=1
+ boot_mesg -n " /tmp" ${NORMAL}
+ cd /tmp &&
+ find . -xdev -mindepth 1 ! -name lost+found -delete || failed=1
fi
- > /var/run/utmp
+ > /var/run/utmp
- if grep -q '^utmp:' /etc/group ; then
- chmod 664 /var/run/utmp
- chgrp utmp /var/run/utmp
- fi
+ if grep -q '^utmp:' /etc/group ; then
+ chmod 664 /var/run/utmp
+ chgrp utmp /var/run/utmp
+ fi
- (exit ${failed})
- evaluate_retval
+ (exit ${failed})
+ evaluate_retval
- if egrep -qv '^(#|$)' /etc/sysconfig/createfiles 2>/dev/null; then
- boot_mesg "Creating files and directories..."
- create_files
- evaluate_retval
- fi
- ;;
- *)
- echo "Usage: ${0} {start}"
- exit 1
- ;;
+ if egrep -qv '^(#|$)' /etc/sysconfig/createfiles 2>/dev/null; then
+ boot_mesg "Creating files and directories..."
+ create_files
+ evaluate_retval
+ fi
+ ;;
+ *)
+ echo "Usage: ${0} {start}"
+ exit 1
+ ;;
esac
# End cleanfs
diff --git a/bootscripts/lfs/init.d/mountfs b/bootscripts/lfs/init.d/mountfs
index b0e6d2737..c88a6386f 100644
--- a/bootscripts/lfs/init.d/mountfs
+++ b/bootscripts/lfs/init.d/mountfs
@@ -57,7 +57,7 @@ case "${1}" in
stop)
boot_mesg "Unmounting all other currently mounted file systems..."
- umount -a -d -r >/dev/null
+ umount -a -d -r -t notmpfs >/dev/null
evaluate_retval
;;
diff --git a/bootscripts/lfs/sysconfig/createfiles b/bootscripts/lfs/sysconfig/createfiles
index 8d1f89dc6..8320c79ae 100644
--- a/bootscripts/lfs/sysconfig/createfiles
+++ b/bootscripts/lfs/sysconfig/createfiles
@@ -8,21 +8,21 @@
# Version : 00.00
#
# Notes : The syntax of this file is as follows:
-# if type is equal to "file" or "dir"
-# <filename> <type> <permissions> <user> <group>
-# if type is equal to "dev"
-# <filename> <type> <permissions> <user> <group> <devtype> <major> <minor>
+# if type is equal to "file" or "dir"
+# <filename> <type> <permissions> <user> <group>
+# if type is equal to "dev"
+# <filename> <type> <permissions> <user> <group> <devtype> <major> <minor>
#
-# <filename> is the name of the file which is to be created
-# <type> is either file, dir, or dev.
-# file creates a new file
-# dir creates a new directory
-# dev creates a new device
-# <devtype> is either block, char or pipe
-# block creates a block device
-# char creates a character deivce
-# pipe creates a pipe, this will ignore the <major> and <minor> fields
-# <major> and <minor> are the major and minor numbers used for the device.
+# <filename> is the name of the file which is to be created
+# <type> is either file, dir, or dev.
+# file creates a new file
+# dir creates a new directory
+# dev creates a new device
+# <devtype> is either block, char or pipe
+# block creates a block device
+# char creates a character deivce
+# pipe creates a pipe, this will ignore the <major> and <minor> fields
+# <major> and <minor> are the major and minor numbers used for the device.
########################################################################
# End /etc/sysconfig/createfiles