Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

Unable to mount a folder from other machine

Posted on 2005-05-02
8
Medium Priority
?
353 Views
Last Modified: 2013-12-27
Hi,

I have two machines

M1 and M2

M1 - Solaris 5.8
M2 - Solaris 5.9

I have to moount a folder from M1 on M2

With a root login on Machine M2 I issue the following command

mount M1:/folder1/folder2 /folder1/folder2

I get the following error
nfs mount:  M1:/folder1/folder2: permission denied

How can I resolve this ? can two different O/S may be the problem

0
Comment
Question by:anshuma
8 Comments
 
LVL 7

Expert Comment

by:pshattuck
ID: 13911249
Ok here's a checklist to answer


1) Is NFS running on M1 .. whats the output of ps -ef | grep nfs

2) If NFS is running is the M1:/folder1/folder2 shared.  Do a dfshares command on M1 and verify if it is shared

3) If 2 is yes then what's the ouput of the dfshares command on M1 and if they are a permanent share what's the output of /etc/dfs/dfmounts and do they have any restrictions on the mounts

4) Can these systems talk to each other at all? (IE Could this be a network or firewall issue)

5) on M2 does the directory /folder1/folder2 exist? If not create it and then try to mount

That should be enough to work with. Waiting on your reply

0
 

Author Comment

by:anshuma
ID: 13911564
I have done all the checks

1.The directory is shared
2. The directories are created
3.Both the machine can ping each other, I even modified the hosts file on both the machines

I think this might help but I don't know how to add an FQDN to      /etc/dfs/dfstab

(could someone help)

also visit http://www.brandonhutchinson.com/NFS_Permission_denied_errors.html

Thanks

0
 
LVL 7

Expert Comment

by:pshattuck
ID: 13912710
FQDN would be the domain your servers are running on

If you were Ebay then your FQDN for those servers would be M12.ebay.com and M2.ebay.com


Try putting the IP address instead of the hostname when mounting the share

Ex.

instead of  mount m1:/folder1/folder2 /folder1/folder2

try

mount xxx.xxx.xxx.xxx:/folder1/folder2 /folder1/folder2

where xxx.xxx.xxx.xxx would be M1's IP address
0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 

Author Comment

by:anshuma
ID: 13916959
I have already tried the IP address approach. I dunno what's wrong
0
 
LVL 7

Assisted Solution

by:pshattuck
pshattuck earned 500 total points
ID: 13918785
Did you try the FQDN?

Are these machines on a network?

Is there a correct IP address in the /etc/resolv.conf?

is the /etc/netmask entries correct?

is the /etc/defaultrouter file correct?


0
 

Expert Comment

by:ddavis42
ID: 13940200
Have you shared M1:/folder1/folder2 yet?
0
 
LVL 17

Accepted Solution

by:
Hanno P.S. earned 1000 total points
ID: 13996251
On the client machine M2 do this (as any user):
 user@client>  showmount -e M1       # what is exported on M2, and how
If you get an error, start the NFS server on M1 (as root):
 root@server>  /etc/init.d/nfs.server start
and check the shared directories
 root@server>  share
Now, try to access it from M2:
 root@client> mkdir /local-dir
 root@client> mount M1:/export/remote-dir  /local-dir

Also, note that access as root via NFS is being mapped to anonymous access (for security!)

If there are still problems, post the messages from the abovementioned command, please.
0
 
LVL 10

Assisted Solution

by:neteducation
neteducation earned 500 total points
ID: 13998983
From the Error Message most probably the error is on the server side.

I suppose you already checked it is not a IP-Address-issue.. so you are talking to the right server.

The error message
nfs mount:  M1:/folder1/folder2: permission denied

means

- mountdaemon on M1 is running
- rpc on M1 is also running
- eigther M1 does not share /folder1/folder2 or it does not allow M2 to mount it.

Most often the problem is a naming issue. On M1, did you share the directory to everyone or only to a specific machine ? If to a specific machine, then the name must match the reverse lookup of it's IP-Address.

On M1 do the following:

getent hosts <ipaddress_of_m2>

the name you get there must match exactly the name you specify in your share-command (if you do specify something).

If this does not help, can you post the contenct of M1's /etc/dfs/dfstab and the ouput of the command (run on M2) of showmount -e M1 ?

0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This tech tip describes how to install the Solaris Operating System from a tape backup that was created using the Solaris flash archive utility. I have used this procedure on the Solaris 8 and 9 OS, and it shoudl also work well on the Solaris 10 rel…
Using libpcap/Jpcap to capture and send packets on Solaris version (10/11) Library used: 1.      Libpcap (http://www.tcpdump.org) Version 1.2 2.      Jpcap(http://netresearch.ics.uci.edu/kfujii/Jpcap/doc/index.html) Version 0.6 Prerequisite: 1.      GCC …
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
Suggested Courses
Course of the Month15 days, 13 hours left to enroll

581 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question