Error:
On Client (192.169.32.17)
# mount 192.169.32.10:/export/home/deepak /mnt
mount.nfs: access denied by server while mounting 192.169.32.10:/export/home/deepak
On NFS Server (192.169.32.10)
# tail -n 1 /var/log/messages
Sep 13 00:00:32 cc01-nds-ins rpc.mountd[29613]: refused mount request from 192.169.32.17 for /export/home/deepak (/export/home/deepak): unmatched host
Solution:
This error is occurring because the NFS server is unaware of the client network attempting to access the NFS shares.As for my case below are the list of directories which are shared using NFS server
As you see the directories are shared for 10.10.10.0/255.0.0.0 subnet while my client server IP is in a different subnet 192.169.32.0/255.255.255.224
So I need to add this subnet in my exports share
On NFS Server (192.169.32.10)
Add a new line in /etc/exports file as shown below# vi /etc/exports
/export/home/deepak 192.169.32.0/255.255.255.224(ro,sync,no_subtree_check)
Refresh the share
# exportfs -ra
List the updated share information
Let us re-attempt to access the NFS share from our client
On Client (192.169.32.17)
# mount -t nfs 192.169.32.10:/export/home/deepak /mnt
# mount | grep export
192.169.32.10:/export/home/deepak on /mnt type nfs (rw,addr=192.169.32.10)
I hope this tutorial was helpful.
Follow the below links for more tutorials:
Configure Red Hat Cluster using VMware, Quorum Disk, GFS2, Openfiler
Why is Linux more secure than windows and any other OS
What is the difference between "su" and "su -" in Linux?
What is swappiness and how do we change its value?
How to log iptables messages in different log file
What are the s and k scripts in the etc rcx.d directories
How to check all the currently running services in Linux
How to auto start service after reboot in Linux
What is virtual memory, paging and swap space?
How to extract files to different directory using tar in Unix/Linux
How to preserve Symbolic links with tar command in Unix/Linux
How to give permission to user to run some commands in Linux
How to set environment (PATH) variable permanently in Linux
Why is Linux more secure than windows and any other OS
What is the difference between "su" and "su -" in Linux?
What is swappiness and how do we change its value?
How to log iptables messages in different log file
What are the s and k scripts in the etc rcx.d directories
How to check all the currently running services in Linux
How to auto start service after reboot in Linux
What is virtual memory, paging and swap space?
How to extract files to different directory using tar in Unix/Linux
How to preserve Symbolic links with tar command in Unix/Linux
How to give permission to user to run some commands in Linux
How to set environment (PATH) variable permanently in Linux