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.
Errors with NFS
I’m at the step where I need to verify portmap is working OK on the box I want to share.
IN the process of preparing a FC3 Linux box to share a directory out.
I get this error when I run Rpcinfo –p:
can't contact portmapper: RPC: Remote system error- Connection denied
Researching articles on the web, I found out this could be because of some errors in hosts.allow/deny or my exports file.
I believe my syntax is correct & when I change it, I believe it exports OK, as I don’t get any errors (or anything else ) when I do this command:
Exportfs –r
When I run nfs restart all daemons start except portmap.
For that I get the following error:
RPC: failed to contact portmap (errno-5)
Then I tried exportfs –var
It seemed to work as it said:
“exporting *:/home/mark
Then running nfs restart does work
But I still get that error when running rpcinfo –p
And a portmapper failure error when running
Showmount -e
I’ve tried putting the FQH name & then the IP address for my share server in the exports file, that didn’t work so I took it out.
At one time I also changed my hosts.allow file to ALL: ALL
I’ve found out (correctly I hope) that even though I want portmap I need to have an entry in the hosts.deny file such as: portmap: ALL
But I’ve also tried it without this entry in here & it the hosts.allow file.
The box I’d like to share-out is 192.168.113.1
The box I’d like to connect to it is 192.168.113.2
I’ve included my hosts & exportfs files below.
Any information would be helpful.
I don’t know if this has anything to do with it, but my NIC doesn’t retain it’s values (ip/mask) info even though I put it in the /etc/sysconfig/network-scripts/ifcfg-eth0 file. But I do get IP by manually using the ifconfig command.
So I included that as well.
HOSTS.ALLOW
# hosts.allow This file describes the names of the hosts which are
# allowed to use the local INET services, as decided
# by the '/usr/sbin/tcpd' server.
#
ALL: 192.168.113.1
ALL: 192.168.113.2
portmap: 192.168.113.0/255.255.255.0
HOSTS.DENY
#
# hosts.deny This file describes the names of the hosts which are
# *not* allowed to use the local INET services, as decided
# by the '/usr/sbin/tcpd' server.
#
# The portmap line is redundant, but it is left to remind you that
# the new secure portmap uses hosts.deny and hosts.allow. In articular
# you should know that NFS uses portmap!
ALL:ALL
portmap: ALL
IFCFG-ETH0
#This should be autoconfiguring my card, but it's not!
DEVICE=eth0
IPADDR=192.168.113.1
NETMASK=255.255.255.0
ONBOOT=yes
TYPE=ethernet
This what I’ve done:
When I start portmap I get green [OK]
But rpcinfo –p still gives same error.
I did this too:
Rebooted
/sbin/service portmap start
rpcinfo –p (still same error)
exportfs –var (looks like it goes OK)
nfs restart (goes OK)
rpcinfo –p (still same error)
And I noticed this, even though my exports file only has this in it:
/home/mark *(no_root_squash)
When I go to /var/lib/nfs & look in the etab file I see:
/home/mark *(ro,sync,wdelay,hide,nocrossmnt,secure,no_root_squash,no_all_squash,subtree_check,secure_locks,mapp ing=identity,anonuid=-2
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.