rebuild mtab during boot
authorChristian Hofstaedtler <ch@grml.org>
Mon, 9 May 2011 21:09:24 +0000 (23:09 +0200)
committerChristian Hofstaedtler <ch@grml.org>
Mon, 9 May 2011 21:09:24 +0000 (23:09 +0200)
As more and more tmpfs filesystems get mounted during boot, we can't
really ship a static /etc/mtab. Switch to the standard Debian way.

etc/grml/fai/config/files/etc/runlevel.conf/GRMLBASE
etc/grml/fai/config/scripts/GRMLBASE/02-mtab [deleted file]

index 49e4444..c1b968a 100644 (file)
@@ -21,8 +21,9 @@
 01     0,1,6   -               /etc/init.d/haltlocal.first
 02     -       S               /etc/init.d/mountkernfs.sh
 02     -       S               /etc/init.d/hostname.sh
-03     -       S               /etc/init.d/grml-udev
-04     -       S               /etc/init.d/mountdevsubfs.sh
+03     -       S               /etc/init.d/mtab.sh
+04     -       S               /etc/init.d/grml-udev
+05     -       S               /etc/init.d/mountdevsubfs.sh
 18     -       S               /etc/init.d/ifupdown-clean
 29     -       2               /etc/init.d/bootlocal.middle
 30     -       2,3,4,5         /etc/init.d/grml-autoconfig
diff --git a/etc/grml/fai/config/scripts/GRMLBASE/02-mtab b/etc/grml/fai/config/scripts/GRMLBASE/02-mtab
deleted file mode 100755 (executable)
index 76814dd..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-#!/bin/bash
-# Filename:      /etc/grml/fai/config/scripts/GRMLBASE/02-mtab
-# Purpose:       create mtab if it does not yet exist
-# Authors:       grml-team (grml.org), (c) Michael Prokop <mika@grml.org>
-# Bug-Reports:   see http://grml.org/bugs/
-# License:       This file is licensed under the GPL v2 or any later version.
-################################################################################
-
-set -u
-set -e
-
-[ -r /etc/grml/grml-live.conf ]  && . /etc/grml/grml-live.conf
-[ -r /etc/grml/grml-live.local ] && . /etc/grml/grml-live.local
-
-# newer debootstrap does not create an mtab.
-# create it and fill it with what is probably already mounted.
-if [ ! -e $target/etc/mtab ] ; then
-  cat > $target/etc/mtab << EOF
-proc /proc proc rw 0 0
-sysfs /sys sysfs rw 0 0
-/dev /dev tmpfs rw 0 0
-devpts /dev/pts devpts rw 0 0
-EOF
-fi
-
-## END OF FILE #################################################################
-# vim:ft=sh expandtab ai tw=80 tabstop=4 shiftwidth=3