the /etc/init.d/net.eth0 script on system shutdown brings down eth0 happily even though the system was booted diskless using nfsroot. needless to say the rest of the shutdown can't continue after the filesystem disappears. i put a hack in my iface_stop() to just not allow bringing eth0 down. a real solution would be to have it either check a config flag saying never to bring the interface down or check the current mounts and not bring it down if / is mounted via a network filesystem over than interface. Reproducible: Always Steps to Reproduce: 1. 2. 3.
Would you mind pasting the output of "cat /proc/mounts" here? Then I'll be able to fix this problem
here's my /proc/mounts output (2.4.2x based kernel): greg@monster greg $ cat /proc/mounts rootfs / rootfs rw 0 0 /dev/root / nfs rw,v3,rsize=8192,wsize=8192,hard,posix,udp,nolock,addr=192.168.2.200 0 0 none /dev devfs rw 0 0 none /proc proc rw 0 0 none /proc/bus/usb usbdevfs rw 0 0 none /dev/shm tmpfs rw 0 0 none /tmp tmpfs rw 0 0 192.168.2.200:/home/nfsroot/usr /usr nfs rw,v3,rsize=8192,wsize=8192,acregmin=300,acregmax=300,acdirmin=300,acdirmax=300,hard,intr,posix,tcp,lock,addr=192.168.2.200 0 0 192.168.2.200:/home/nfsroot/home /home nfs rw,v3,rsize=8192,wsize=8192,acregmin=300,acregmax=300,acdirmin=300,acdirmax=300,hard,intr,posix,tcp,lock,addr=192.168.2.200 0 0 I don't know why it lists rootfs / and /dev/root /. clearly the latter indicates nfsroot. (hmm unrelated side-note; interesting that it says 8k for rsize and wsize. i have 32k in my fstab. wonder if this kernel isn't patched for 32k r/wsize nfs)
Could this help? http://groups.google.com/groups?q=svc:+bad+direction&hl=en&lr=&ie=UTF-8&oe=UTF-8&scoring=d&selm=1rINI-3dU-23%40gated-at.bofh.it&rnum=1 From the few answers I have found out there, it does seem to be something to do with nfsd not liking some network traffic it's recieving. I was told to add: net.ipv4.ip_local_port_range = 49152 61000 to /etc/sysctl.conf But it didn't help in my case.
Ack, sorry.. wrong bug :/
i just upgraded my kernel. this still happens on a 2.6.8-gentoo-r7 kernel (without supermount; so its not supermount related) I still use this to iface_stop() in /etc/init.d/net.eth0 as a hack workaround for now: # XXX GPS start hack gentoo bug #53104 if [ "$IFACE" = "eth0" ]; then # XXX GPS this is a nfsroot system, don't allow the main iface to go down einfo "Not bringing ${IFACE} down, nfsroot needs it - gps" eend 0 return 0 fi # XXX GPS end hack
should be fixed in baselayout-1.11.x if you don't specify a predown() the default is now to check for NFS root and disallow downing any interfaces.
*** Bug 75408 has been marked as a duplicate of this bug. ***
sorry to say but this issue is NOT fixed in baselayout-1.11.x hotspareblade ~ # mount 19x.16x.11x.20x:/home/netboot/bladeS13 on / type nfs (rw,sync,hard,intr,nolock,rsize=8192,wsize=8192) none on /dev type devfs (rw) none on /proc type proc (rw) none on /dev/shm type tmpfs (rw) hotspareblade ~ # epm -q baselayout baselayout-1.11.8 /sbin/functions.sh: line 376: /var/lib/init.d/serial-8487: Read-only file system /sbin/functions.sh: line 383: /var/lib/init.d/serial-8487: No such file or directory * ERROR: "/etc/init.d/serial" has syntax errors in it; not executing... /sbin/functions.sh: line 376: /var/lib/init.d/sshd-8487: Read-only file system /sbin/functions.sh: line 383: /var/lib/init.d/sshd-8487: No such file or directory * ERROR: "/etc/init.d/sshd" has syntax errors in it; not executing... /sbin/functions.sh: line 376: /var/lib/init.d/urandom-8487: Read-only file system /sbin/functions.sh: line 383: /var/lib/init.d/urandom-8487: No such file or directory * ERROR: "/etc/init.d/urandom" has syntax errors in it; not executing... /sbin/rc: line 792: /var/lib/init.d/softlevel: Read-only file system rm: cannot remove `/var/lib/init.d/failed': Read-only file system rm: cannot remove `/var/lib/init.d/options'Power down. : Read-only file system rm: cannot remove `/var/lib/init.d/snapshot': Read-only file system rm: cannot remove `/var/lib/init.d/softlevel': Read-only file system rm: cannot remove `/var/lib/init.d/softscripts': Read-only file system rm: cannot remove `/var/lib/init.d/softscripts.new': Read-only file system rm: cannot remove `/var/lib/init.d/started': Read-only file system * Stopping devfsd ... [ ok ] * Deactivating swap ... [ ok ] * Unmounting filesystems ... [ ok ] * Remounting remaining filesystems readonly ... [ ok ] * Fsck will be skipped on next startup
uberlord: confirm/check ?
Created attachment 59932 [details, diff] fixes is_net_fs to report the type $1 was mounted and not how it was mounted I think I have found the flaw - the /etc/fstab file may not contain a line to indicate that / should be mounted nfs. Please test the patch and report back
Created attachment 59952 [details, diff] fixes is_net_fs to report the type $1 was mounted and not how it was mounted
baselayout-1.11.12-r4 is out with the patch re-open if it still doesn't work