From e21f2e5093a027058a685f09a4b9d0151bb4dafd Mon Sep 17 00:00:00 2001 From: Matthias Hentges Date: Tue, 4 Apr 2006 12:07:29 +0000 Subject: altboot: - Allow a basic reconfiguration of non-flash based installations: - Move /home from flash into the image - Remove SD / CF / /home ipkg dests - Move ipkg package data from RAM into the image - All of the above is _optional_ - Be a little bit less verbose. - Yet _again_ change the way we detect wheter we are called by the kernel or the user...this is driving me nuts. --- packages/altboot/files/altboot-menu/Advanced/40-bootNFS | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'packages/altboot/files/altboot-menu') diff --git a/packages/altboot/files/altboot-menu/Advanced/40-bootNFS b/packages/altboot/files/altboot-menu/Advanced/40-bootNFS index baa426218b..e01af7faad 100644 --- a/packages/altboot/files/altboot-menu/Advanced/40-bootNFS +++ b/packages/altboot/files/altboot-menu/Advanced/40-bootNFS @@ -20,11 +20,11 @@ run_module() { init_rootfs # Needed for NFS - /etc/init.d/portmap start >/dev/tty1 2>&1 || die "/etc/init.d/portmap start failed!" + /etc/init.d/portmap start >/dev/null 2>&1 || die "/etc/init.d/portmap start failed!" # For some reason NFS mounts hang if /e/i/networking is not run. # For the time beeing I'm too lazy to investigate ;) - /etc/init.d/networking start || die "/etc/init.d/networking start failed!" + /etc/init.d/networking start >/dev/null 2>&1 || die "/etc/init.d/networking start failed!" sleep 2 @@ -126,6 +126,15 @@ run_module() { mkdir -p /media/nfsroot || die "mkdir -p /media/nfsroot failed!" echo -n "Mounting NFS root..." + + if ( mount | grep -q "/media/nfsroot" ) + then + echo "/media/nfsroot already used, tying to umount..." + umount /media/image + losetup -d /dev/loop0 + umount /media/nfsroot || die "umount failed!" + fi + mount -t nfs "$selection" /media/nfsroot && echo ok || die "mount -t nfs "$selection" /media/nfsroot failed!" # Use configured resolv.conf in the pivoted rootfs -- cgit v1.2.3