DISQUS

Homo-Adminus Blog: How to unmount NFS share mounted with hard option

  • Mikael · 2 years ago
    cool doc
  • Andre-Sebastian · 2 years ago
    I recommend using 'lsof' to check which processes is using the nfs share before killing one.

    i.e. if one has a nfs share mounted on /netfs the syntax would be:
    lsof +f -- /netfs
    (for more examples consult the lsof man pages)
  • LAMEtHIng · 2 years ago
    Finally the answer! Thanks a lot man I was looking everywhere for this! The key for me was the 'D' state. I had an vsftpd process AND lsof process holding up the NFS umount. What happened was that I lost connection to my NFS server and then my IP changed. I couldn't even run fuser OR lsof as it would just freeze and never timeout. I tried restarting all the rpc.nfs stuff and the ftp server to no avail. Finally this works, thanks a ton man!
  • Yordan · 1 year ago
    man: umount
    ---------------
    -f Force unmount (in case of an unreachable NFS system). (Requires kernel 2.1.116 or later.)

    -l Lazy unmount. Detach the filesystem from the filesystem hierarchy now, and cleanup all references to the filesystem as
    soon as it is not busy anymore. (Requires kernel 2.4.11 or later.)
    ------------------
  • ray · 1 year ago
    umount -f does not work when NFS mount is stuffed due to the NFS server rebooting or something like that. The only thing which worked for me was what was posted here by Scoundrel. Thanks a million it helped me finally sorting this out without rebooting all involved servers. Triple kudos.