summaryrefslogtreecommitdiffstats
path: root/initramfs/initrd-stuff/init
diff options
context:
space:
mode:
authorOliver Tappe2007-07-06 23:52:59 +0200
committerOliver Tappe2007-07-06 23:52:59 +0200
commitbf54c1f9d725c85a12fd3791ed35cc54a5cb6241 (patch)
treefc44b5f10810cf27426241ae3add633a1c3e5583 /initramfs/initrd-stuff/init
parent* now the contents of initramfs-setup are dumped to machine-setup, too, (diff)
downloadcore-bf54c1f9d725c85a12fd3791ed35cc54a5cb6241.tar.gz
core-bf54c1f9d725c85a12fd3791ed35cc54a5cb6241.tar.xz
core-bf54c1f9d725c85a12fd3791ed35cc54a5cb6241.zip
* fixed timing problems when trying to unmount the modules folder
* minor clarification git-svn-id: http://svn.openslx.org/svn/openslx/trunk@1229 95ad53e4-c205-0410-b2fa-d234c58c8868
Diffstat (limited to 'initramfs/initrd-stuff/init')
-rwxr-xr-xinitramfs/initrd-stuff/init12
1 files changed, 7 insertions, 5 deletions
diff --git a/initramfs/initrd-stuff/init b/initramfs/initrd-stuff/init
index 160cb2c3..e3b64ceb 100755
--- a/initramfs/initrd-stuff/init
+++ b/initramfs/initrd-stuff/init
@@ -267,9 +267,10 @@ if [ -n "$nodhcp" -a -z "$ldap" -a -z "$ipinfo" ] ; then
clients. You\n# might want to add the token 'dhcp' for DHCP configuration, \
'file(=source)'\n# for config file get via TFTP or 'ldap(=source)' for LDAP \
configuration to\n# your kernel command line." >> /etc/machine-setup
- if strinfile "clientip" /etc/machine-setup ; then
+ if strinfile "clientip" /etc/initramfs-setup ; then
# IP configuration seems to be present in machine-setup file
- . /etc/machine-setup
+ # TODO: FIX this, as it will clobber all kernel-cmdline values!
+ . /etc/initramfs-setup
ipinfo="ip=$clientip:$serverip:$gateway:$subnet_mask"
else
error "$init_errip"
@@ -745,12 +746,13 @@ postinit
# unmount the bind mounted modules directory
export ticks
-for ticks in 0 400 1000 2000 5000 10000 ; do
- usleep $ticks && umount -n /lib/modules/${KERNEL} 2>/dev/null && break
+for ticks in 0 1 2 5 10 20 30; do
+ sleep $ticks && umount -n /lib/modules/${KERNEL} 2>/dev/null && break
error "$init_wait" nonfatal
done
-[ $ticks -gt 1000 ] && error "$init_errumnt"
+mount 2>/dev/null | grep /lib/modules/${KERNEL} >/dev/null 2>&1 \
+ && error "$init_errumnt"
# check for inittab file (might fail for new style init -> upstart)
test -f /mnt/etc/inittab || test -d /mnt/etc/event.d || error "$init_erritab"
# close runlevel script for stuff to execute during early bootup