Friday, 30 July 2010

Linux NFS Communication Common Problems

Today, I've been asked some questions about NFS communication problems, the very first was: RPC: Program Not Registered.
This is caused mainly by the fact that NFS service is not running on the server, you can run the service using: "/etc/init.d/nfs start"
For a comprehensive list of error, have a look at: NFS Troubleshooting Guide
Another common problem is permission and access problems, such as: System Error: No route to host.
The resolve this, simply check whether you can ping the server or not, if you can ping, then the problem is with your servers firewall configuration. For a detailed manual on how to configure firewall, have a look at: How To Configure NFS, appendix A. (If you can not ping the server either, refer to the NFS Troubleshooting Guide to find the cause and a workaround to solve it)
In case of firewall blocking, you can simply turnoff the firewall using "service iptables stop". Although this is the easiest way, but also the worst way! You can go further and disable the iptables firewall service from boot time using "ntsysv" command. (Not recommended at all!)
If you would like to read a comprehensive guide about setting up NSF and better understand things, have a look at this manual.