2
nfs server *** not responding
nfs server *** not responding
nfs server *** not responding
nfs server *** not responding
nfs server *** not responding
nfs server *** not responding

I am getting this repeatedly and machine is hung. How can I stop that request?

I cannot initiate a new ssh connection also.

JeffG
  • 1,194
  • 6
  • 18
hari
  • 270
  • 1
  • 4
  • 17

4 Answers4

5

You can try using umount -f to forcibly unmount. Depending on disk activity, it hasn't always worked for me; sometimes I've had to cycle the machine (unless I could restore the service).

For the future, you can look into whether mount_nfs arguments -i (interruptible), -s (soft mount), or -Rn (maximum retry count) are appropriate for your environment.

I wasn't able to quickly tease out a gold standard for this, but here are some related items:

2

umount -l /mnt/nfs is very handy in situations like this as it will basically umount and ask questions later. What it does is immediately umount the file system, and leave any open files hangining. As it can it will kill off any open files to the dead nfs mount.

Niall Donegan
  • 3,869
  • 20
  • 17
1

Mike's answer is correct. I would add, that lsof is helpful to see what processes have files open on the NFS mount. I've always had to kill -9 those pids and quickly umount -f immediately after. Sometimes it doesn't work and you have to reboot and reset.

benjarrell
  • 188
  • 1
  • 8
0

Getting to a point where you can manipulate fstab is important here.

You will need to boot the machine with a rescue disk, then edit the /etc/fstab to remove the line that is automounting the volume. Then you should be able to restart the machine and make appropriate changes mentioned by the other posters.

Mike
  • 802
  • 4
  • 5
  • Sorry may have misread the question. I thought, for some reason, that the machine was hanging during boot. Sorry if it isn't. – Mike Mar 07 '11 at 19:14