Access denied by Server

Issues related to configuring your network
Post Reply
mohanpothula
Posts: 3
Joined: 2015/04/18 15:25:42

Access denied by Server

Post by mohanpothula » 2015/04/18 15:35:01

Hi,
I am tring to configure NFS serve using the below procedure but when trying to mount it saying that access denied by server ,Any one any idea what could be the cause of this error


server:
On the NFS server we run:
yum install nfs-utils nfs-utils-lib

client:
On the client we can install NFS as follows (this is actually the same as on the server):
yum install nfs-utils nfs-utils-lib

server:
mkdir /var/nfs
chown 65534:65534 /var/nfs
chmod 755 /var/nfs

vi /etc/exports

/home 192.168.21.100(rw,sync,no_root_squash,no_subtree_check)
/var/nfs 192.168.21.100(rw,sync,no_subtree_check)

Mounting The NFS Shares On The Client

client:
First we create the directories where we want to mount the NFS shares, e.g.:
mkdir -p /mnt/nfs/home
mkdir -p /mnt/nfs/var/nfs

Afterwards, we can mount them as follows:
mount 192.168.21.100:/home /mnt/nfs/home
mount 192.168.21.100:/var/nfs /mnt/nfs/var/nfs

[root@nfsclient nfs]# mount 192.168.21.100:/var/nfs /mnt/nfs/var/nfs
mount.nfs: access denied by server while mounting nfsserver:/var/nfs


When using debug mode

[root@nfsclient nfs]# mount -v -o 'vers=3' 192.168.21.100:/home /mnt/nfs/home
mount: no type was given - I'll assume nfs because of the colon
mount.nfs: timeout set for Sat Apr 18 08:22:13 2015
mount.nfs: trying text-based options 'vers=3,addr=192.168.21.100'
mount.nfs: prog 100003, trying vers=3, prot=6
mount.nfs: trying 192.168.21.100 prog 100003 vers 3 prot TCP port 2049
mount.nfs: prog 100005, trying vers=3, prot=17
mount.nfs: trying 192.168.21.100 prog 100005 vers 3 prot UDP port 59447
mount.nfs: mount(2): Permission denied
mount.nfs: access denied by server while mounting 192.168.21.100:/home

Thanks ,
Mohan

gerald_clark
Posts: 10642
Joined: 2005/08/05 15:19:54
Location: Northern Illinois, USA

Re: Access denied by Server

Post by gerald_clark » 2015/04/18 16:26:46

Did you start the nfs service on the server?
Did you open the firewall ports?
Please read /etc/sysconfig/nfs and the documentation at
https://access.redhat.com/site/document ... index.html

mohanpothula
Posts: 3
Joined: 2015/04/18 15:25:42

Re: Access denied by Server

Post by mohanpothula » 2015/04/19 09:57:18

Thaks for your inputs ,after restatinh the NFS i can able to mount now .
Btw I want to access shared path through client Web browser(hhttp apache web server) ,any idea how to configure


Thanks ,
MOhan

Post Reply