Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I have two system, an Intel Core2 Duo system running the 32-bit version of Fedora 12, and a MacBook Pro running the 64-bit version of Fedora 12.
I'm using the Gnome desktop on each system. I have enabled all the services I believe are necessary to support NFS including nfs, rpcbind, rpcgssd, rpcidmapd, and rpcsvcgssd on each system.
I have added an entry to my /etc/exports file to export my home on each system, and if I type this command:
$ showmount -e localhost
I get a result like this:
Export list for localhost:
/home/tron 192.168.200.101,192.168.200.100
However when I issue this type of command:
$ showmount -e <remote host name>
I get this kind of result:
rpc mount export: RPC: Unable to receive; errno = No route to host
Research on the Internet indicates this is usually due to a firewall problem. However, I use the Firewall Configuration application to the disable the firewall on both systems, and I continue to get the same result.
What is needed so I can get this two machines to display their exported file shares remotely?
Looks like it is a firewall issue after all. It turns out I did not disable the firewall when I thought I had. Now that I'm certain the firewall is disabled on both systems, I'm able to get the showmount command to succeed.
You can use the security configuration gui control to add services to allow through your firewall and enable the firewall again. It should enable all the ports that you need open.
111 for rpcbind
2049 is used as well.
You can modify the ports that the client expects in the mount command as well. See the nfs manpage for details on mount options such as udp, tcp, port=n, proto= (nfs4). The sec=mode settings may require an addition port for authentication to work.
I'm not what the security configuration gui control is unless that refers to the Firewall Configuration application.
I have already configured that application to enable ports 111 and 2049 for the firewall.
I looked over the documentation of nfs, and it is not clear to me what I need to specify so the showmount command will succeed. Perhaps some examples would be useful.
However when I issue this type of command:
$ showmount -e <remote host name>
From which machine did you do this?
If you are saying that you can't use showmount -e using the computers own host name, I wonder if it even has one. Some installs will give the computer the name localhost.localdomain initially so that you don't have two hosts on the network with the same hostname.
What does running "hostname" return? If you are trying this from another computer, what does
getent hosts <HOSTNAME>
return. That test will work whether a host is on the LAN or the internet, and is a way of testing whether your name resolving works.
If you depend on avahi to resolve host names on the lan, use "showmount -e HOSTAME.local" instead.
From either computer and get the same result when <remote host name> is the name of the other computer.
Both computers have entries in their /etc/hosts files that specify the names and static IP addresses I applied to all the systems on my small home network.
Thanks. The first post didn't make that clear, and sometimes we find out later.
Quote:
I have enabled all the services I believe are necessary to support NFS including nfs, rpcbind, rpcgssd, rpcidmapd, and rpcsvcgssd on each system.
The last rpcgssd and rpcsvcgssd deal with authentication. If you don't use that type of authentication, you don't need them.
Code:
sec=mode The RPCGSS security flavor to use for accessing files on this mount point. If the sec option is not specified, or if sec=sys is specified, the NFS client uses
the AUTH_SYS security flavor for all NFS requests on this mount point. Valid security flavors are none, sys, krb5, krb5i, krb5p, lkey, lkeyi, lkeyp, spkm, spkmi,
and spkmp. Refer to the SECURITY CONSIDERATIONS section for details.
I found this webpage which explains which service matches which security model. http://www.vanemery.com/Linux/NFSv4/...no-rpcsec.html
A lot of what you selected are for NFSv4 and not NFSv3. I don't know which you are using. The chart on that page should help determine the services and ports you need.
You could use nmap on another computer to list the open ports on your nfs server. Another way is to use the telnet client:
Code:
telnet elite 111
Trying 192.168.1.106...
Connected to elite.
Escape character is '^]'.
telnet elite 2049
Trying 192.168.1.106...
Connected to elite.
Escape character is '^]'.
en
This only checks for TCP ports, not UDP.
You may also need udp for port 111.
Whether you need TCP or UDP for NFS depends on how you have it configured. I have port 111 open for both and 2049/tcp open.
Port 111 is the one that the showmount command uses. This is the sunrpc port.
The error you saw, "rpc mount export: RPC: Unable to receive; errno = No route to host" could mean that you don't have your network or interface configured correctly. Maybe all ports have this problem.
I am not certain if I am using NSFv4 or NSFv3. How would I determine such a thing?
I believe I will probably need NSFv3 because some of the systems on my network are Macintosh systems, and it is my understanding that Mac OS X does not support NSFv4.
In the Firewall Configuration application, I have NSF4 selected in the Trusted Services
I also have port 111 for both UDP and TCP added to Other Ports
nmap does not appear to be available on my system. I tried telnet, and it seems I could make a connection on both port 111 and 2049.
I do not I have a problem with ports in general. The systems can ping each other and they can connect via SSH.
I am not certain if I am using NSFv4 or NSFv3. How would I determine such a thing?
I believe I will probably need NSFv3 because some of the systems on my network are Macintosh systems, and it is my understanding that Mac OS X does not support NSFv4.
In the Firewall Configuration application, I have NSF4 selected in the Trusted Services
I also have port 111 for both UDP and TCP added to Other Ports
nmap does not appear to be available on my system. I tried telnet, and it seems I could make a connection on both port 111 and 2049.
I do not I have a problem with ports in general. The systems can ping each other and they can connect via SSH.
#
# Define which protocol versions mountd
# will advertise. The values are "no" or "yes"
# with yes being the default
#MOUNTD_NFS_V1="no"
#MOUNTD_NFS_V2="no"
#MOUNTD_NFS_V3="no"
#
#
# Path to remote quota server. See rquotad(8)
#RQUOTAD="/usr/sbin/rpc.rquotad"
# Port rquotad should listen on.
#RQUOTAD_PORT=875
# Optinal options passed to rquotad
#RPCRQUOTADOPTS=""
#
#
# Optional arguments passed to in-kernel lockd
#LOCKDARG=
# TCP port rpc.lockd should listen on.
#LOCKD_TCPPORT=32803
# UDP port rpc.lockd should listen on.
#LOCKD_UDPPORT=32769
#
#
# Optional arguments passed to rpc.nfsd. See rpc.nfsd(8)
# Turn off v2 and v3 protocol support
#RPCNFSDARGS="-N 2 -N 3"
# Turn off v4 protocol support
#RPCNFSDARGS="-N 4"
# Number of nfs server processes to be started.
# The default is 8.
#RPCNFSDCOUNT=8
# Stop the nfsd module from being pre-loaded
#NFSD_MODULE="noload"
#
#
# Optional arguments passed to rpc.mountd. See rpc.mountd(8)
#RPCMOUNTDOPTS=""
# Port rpc.mountd should listen on.
#MOUNTD_PORT=892
#
#
# Optional arguments passed to rpc.statd. See rpc.statd(8)
#STATDARG=""
# Port rpc.statd should listen on.
#STATD_PORT=662
# Outgoing port statd should used. The default is port
# is random
#STATD_OUTGOING_PORT=2020
# Specify callout program
#STATD_HA_CALLOUT="/usr/local/bin/foo"
#
#
# Optional arguments passed to rpc.idmapd. See rpc.idmapd(8)
#RPCIDMAPDARGS=""
#
# Set to turn on Secure NFS mounts.
#SECURE_NFS="yes"
# Optional arguments passed to rpc.gssd. See rpc.gssd(8)
#RPCGSSDARGS=""
# Optional arguments passed to rpc.svcgssd. See rpc.svcgssd(8)
#RPCSVCGSSDARGS=""
#
#
# Define which protocol versions mountd
# will advertise. The values are "no" or "yes"
# with yes being the default
#MOUNTD_NFS_V1="no"
#MOUNTD_NFS_V2="no"
#MOUNTD_NFS_V3="no"
#
#
# Path to remote quota server. See rquotad(8)
#RQUOTAD="/usr/sbin/rpc.rquotad"
# Port rquotad should listen on.
#RQUOTAD_PORT=875
# Optinal options passed to rquotad
#RPCRQUOTADOPTS=""
#
#
# Optional arguments passed to in-kernel lockd
#LOCKDARG=
# TCP port rpc.lockd should listen on.
#LOCKD_TCPPORT=32803
# UDP port rpc.lockd should listen on.
#LOCKD_UDPPORT=32769
#
#
# Optional arguments passed to rpc.nfsd. See rpc.nfsd(8)
# Turn off v2 and v3 protocol support
#RPCNFSDARGS="-N 2 -N 3"
# Turn off v4 protocol support
#RPCNFSDARGS="-N 4"
# Number of nfs server processes to be started.
# The default is 8.
#RPCNFSDCOUNT=8
# Stop the nfsd module from being pre-loaded
#NFSD_MODULE="noload"
#
#
# Optional arguments passed to rpc.mountd. See rpc.mountd(8)
#RPCMOUNTDOPTS=""
# Port rpc.mountd should listen on.
#MOUNTD_PORT=892
#
#
# Optional arguments passed to rpc.statd. See rpc.statd(8)
#STATDARG=""
# Port rpc.statd should listen on.
#STATD_PORT=662
# Outgoing port statd should used. The default is port
# is random
#STATD_OUTGOING_PORT=2020
# Specify callout program
#STATD_HA_CALLOUT="/usr/local/bin/foo"
#
#
# Optional arguments passed to rpc.idmapd. See rpc.idmapd(8)
#RPCIDMAPDARGS=""
#
# Set to turn on Secure NFS mounts.
#SECURE_NFS="yes"
# Optional arguments passed to rpc.gssd. See rpc.gssd(8)
#RPCGSSDARGS=""
# Optional arguments passed to rpc.svcgssd. See rpc.svcgssd(8)
#RPCSVCGSSDARGS=""
#
Now I can mount and access the NFS share from my Macintosh, however I have to have root access (i.e. I prefix commands like ls, cp, etc. with sudo). It is not perfect, however it will get the job done.
Now I can mount and access the NFS share from my Macintosh, however I have to have root access (i.e. I prefix commands like ls, cp, etc. with sudo). It is not perfect, however it will get the job done.
It's most likely a permissions issue...
Do both users exist on both hosts? Both with the same uid/gid?
I used the same account name on all my systems. I don't know that they all have the same user and group identifier. I forget how to check that. I suspect there may be some differences.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.