Re: RPC: sendmsg returned error 101

Bill Rugolsky Jr. (rugolsky@ead.dsa.com)
Tue, 24 Aug 1999 12:13:18 -0400


--5vNYLRcllDrimb99
Content-Type: text/plain; charset=us-ascii

On Tue, Aug 24, 1999 at 03:06:21PM +0100, Alan Cox wrote:
> > >>>>> " " == Werner Almesberger <almesber@lrc.di.epfl.ch> writes:
> > > A practical solution may be simply to forcibly unmount all
> > > stuck file systems. In any case it's better than forcing the
> > > user to press the reset button.
>
> You can only do that for NFS
>
> > Isn't this what the new umount was supposed to give us? Does anybody
> > know why it is not being used?
>
> I've been using it for a while. umount -f on NFS, followed by a 10 second
> wait if it fails then an fuser -k then a couple of umount -f's with a second
> gap.
>
> Seems to work

Thanks. I can't say I like it, but the included init script patch
seems to work for me.

Bill Rugolsky
rugolsky@ead.dsa.com

--5vNYLRcllDrimb99
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="netfs.patch"

--- /etc/rc.d/init.d/netfs.0 Fri Mar 26 17:56:03 1999
+++ /etc/rc.d/init.d/netfs Tue Aug 24 12:09:11 1999
@@ -39,7 +39,25 @@
action "Mounting other filesystems" mount -a
;;
stop)
- [ -n "$NFSMTAB" ] && action "Unmounting NFS filesystems" umount -a -t nfs
+ if [ $# -eq 1 ]; then
+ sig=
+ retry=3
+ remaining=`awk '!/^#/ && $3 ~ /^nfs/ {print $2}' /proc/mounts`
+ while [ -n "$remaining" -a "$retry" -gt 0 ]
+ do
+ umount -f -a -t nfs
+ sleep 10
+ remaining=`awk '!/^#/ && $3 ~ /^nfs/ {print $2}' /proc/mounts`
+ [ -z "$remaining" ] && break
+ lsof -N
+ fuser -k -m $sig $remaining >/dev/null
+ sleep 5
+ retry=`expr $retry - 1`
+ sig=-9
+ done
+
+ fi
+ [ -n "$NFSMTAB" ] && action "Unmounting NFS filesystems" umount -f -a -t nfs
[ -n "$SMBMTAB" ] && action "Unmounting SMB filesystems" umount -a -t smbfs
[ -n "$NCPMTAB" ] && action "Unmounting NCP filesystems" umount -a -t ncpfs
rm -f /var/lock/subsys/netfs
@@ -75,7 +93,7 @@
fi
;;
restart)
- $0 stop
+ $0 stop restart
$0 start
;;
reload)

--5vNYLRcllDrimb99--

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/