kill -9 always works… except when it doesn’t. It also so seems that 99% of the time, when it doesn’t work, this is because the process is trying to access an NFS mount. This is handled in the Linux kernel and (unless you mount NFS with the
soft option) it will retry forever.
If you can reboot your Linux machine, just do that. It’ s easier. If not, you can trick the process into timing out. To do that, you need to add the IP of the NFS mount locally and temporarily run an NFS server. If your NFS server is at IP 188.8.131.52, you would do:
apt-get install nfs-kernel-server
Now wait a moment and your stuck process should exit. Now you can clean up:
apt-get --purge remove nfs-kernel-server