Permission Denied on NFS Mount

  • Follow


Hi,

On the host containing the filesystem, I added a line to
/etc/exports as follows:

/<fs> -root=<client>, access=<client>

I executed /usr/sbin/exportfs -a

On the client, I added a line in /etc/fstab as follows;

<host>:/<fs> /<fs> nfs defaults 0 0

On the client, I executed 'mount <serverhost>:/<fs>', but
HP-UX (v11.11) responded with 'Permission Denied'.

I am root in both client and server. Root has full permission
on the filesystems. (I set the permissions to 777).

I can telnet, ftp, etc.. from the server to the client, and
vice-versa.

What could be causing the 'Permission Denied' response?



Thanks,
BASIS Consultant

0
Reply basis_consultant (53) 5/25/2005 12:47:05 PM

In article <1117025225.525038.169930@o13g2000cwo.googlegroups.com>,
basis_consultant@hotmail.com wrote:
> Hi,
> 
> On the host containing the filesystem, I added a line to
> /etc/exports as follows:
> 
> /<fs> -root=<client>, access=<client>
                       ^

Not sure if that space is valid or not...

> I executed /usr/sbin/exportfs -a
> 
> On the client, I added a line in /etc/fstab as follows;
> 
><host>:/<fs> /<fs> nfs defaults 0 0
> 
> On the client, I executed 'mount <serverhost>:/<fs>', but
> HP-UX (v11.11) responded with 'Permission Denied'.
> 
> I am root in both client and server. Root has full permission
> on the filesystems. (I set the permissions to 777).
> 
> I can telnet, ftp, etc.. from the server to the client, and
> vice-versa.

Not really relevant to NFS mounting.

> What could be causing the 'Permission Denied' response?

The server thinks you are not authorized to access, which means that if your
exports file is correct it is not resolving you host name correctly or the
client is attempting to mount from the wrong server.

To figure out what host name the server needs to see, try the following:

1) telnet from client to server and log in
2) run 'who -a | grep $LOGNAME'
3) look for the 1st entry (most recent timestanp)
4) the last field shows the host you are connecting from - that is what exports
needs to have

Be aware that the last field can be truncated, so you might have to still
figure out the correct name.

You can always put the IP address of the client in exports - it should always
work.

Kevin

-- 
Unix Guy Consulting, LLC
Unix and Linux Automation, Shell, Perl and CGI scripting
http://www.unix-guy.com
0
Reply Kevin 5/25/2005 2:30:35 PM


Get to the server
nslookup <client>

should answer an ip adresse

now do:
nslookup <ipadress>

does it return the exact string or something else? e.g. the full 
qualified domainname instead of the short name?

/etc/exports needs the name, which is replied to namelookups on the 
ip-adress.


btw:
 > /<fs> -root=<client>, access=<client>
                        ^No Blank here!

basis_consultant@hotmail.com wrote:

> Hi,
> 
> On the host containing the filesystem, I added a line to
> /etc/exports as follows:
> 
> /<fs> -root=<client>, access=<client>
> 
> I executed /usr/sbin/exportfs -a
> 
> On the client, I added a line in /etc/fstab as follows;
> 
> <host>:/<fs> /<fs> nfs defaults 0 0
> 
> On the client, I executed 'mount <serverhost>:/<fs>', but
> HP-UX (v11.11) responded with 'Permission Denied'.
> 
> I am root in both client and server. Root has full permission
> on the filesystems. (I set the permissions to 777).
> 
> I can telnet, ftp, etc.. from the server to the client, and
> vice-versa.
> 
> What could be causing the 'Permission Denied' response?
> 
> 
> 
> Thanks,
> BASIS Consultant
> 
0
Reply Florian 5/25/2005 3:02:29 PM

<basis_consultant@hotmail.com> wrote in message
news:1117025225.525038.169930@o13g2000cwo.googlegroups.com...
> Hi,
>
> On the host containing the filesystem, I added a line to
> /etc/exports as follows:
>
> /<fs> -root=<client>, access=<client>
>
> I executed /usr/sbin/exportfs -a
>
> On the client, I added a line in /etc/fstab as follows;
>
> <host>:/<fs> /<fs> nfs defaults 0 0
>
> On the client, I executed 'mount <serverhost>:/<fs>', but
> HP-UX (v11.11) responded with 'Permission Denied'.
>
> I am root in both client and server. Root has full permission
> on the filesystems. (I set the permissions to 777).
>
> I can telnet, ftp, etc.. from the server to the client, and
> vice-versa.
>
> What could be causing the 'Permission Denied' response?
>
>
>
> Thanks,
> BASIS Consultant
>

I think Florian and Kevin's replies are both on track, but if that doesn't
pan out, I was wondering if the / directory might be the problem.  Try
mounting the server / onto /mnt or some other non-"/" directory on the
client.


0
Reply Eigenvector 5/26/2005 1:22:56 AM

Hi,

Thanks to all who replied. 'nslookup', as well as 'who', indicated
that /etc/exports and /etc/fstab did have the correct hostname.

I solved the problem by issuing the command 'exportfs -i /<fs>' on the
host.

The mount command then worked on the client.

Had nobody been on the system, and the applications been stopped,
I would have umounted and remounted  /<fs> on the host. Perhaps
the NFS mount would have worked. (HP-UX did indicate that
/<fs> was previously exported, though it did not have an
entry in /etc/exportfs).


Thanks,
BASIS Consultant

0
Reply basis_consultant 5/26/2005 2:28:00 PM

Hi

 > (HP-UX did indicate that
 > /<fs> was previously exported, though it did not have an
 > entry in /etc/exportfs).
an NFS export may be setup by an cluster script. If you are running a 
cluster on this machine, you should always be very careful with fixed 
entries in /etc/exports !

Florian

0
Reply Florian 5/30/2005 12:32:50 PM

5 Replies
2057 Views

(page loaded in 0.007 seconds)

Similiar Articles:













7/20/2012 8:42:58 AM


Reply: