5

I can't imagine there isn't a simple strategy to solve this issue of stale nfs handles preventing a machine from shutting down normally, but I'm not sure what that would be. It's pretty annoying to have to force a reboot just because a wifi connection dropped out at some point while watching endless 'waiting for nfsmount' messages.

3
  • What's your distribution? – daisy Mar 10 '13 at 14:39
  • it's a gentoo based sabayon – barrymac Mar 10 '13 at 14:55
  • Try add -f for netfs (modify the mount command), I couldn't remember the exact name of the service – daisy Mar 10 '13 at 15:08
3

What are your mount options?

You should experiment with "hard,intr", or "soft" (with "timeo"), and possibly "retrans" depending on your client options. Using TCP instead of UDP may also help. The default is usually "hard".

Using "soft" is usually advised against, it can result in written data being lost. It's safe to use as read-only.

On latter linux kernels (2.6.25) NFS clients "intr" is deprecated, sigkill should just work. "umount -f" and "umount -l" can help.

See also Stop broken NFS mounts from locking a directory? and https://serverfault.com/questions/365149/how-do-i-forcibly-unmount-when-im-getting-stale-nfs-file-handles .

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.