LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 01-06-2016, 11:31 PM   #1
beckwith
Member
 
Registered: Nov 2002
Location: Western Australia
Distribution: Mint / ubuntu
Posts: 118

Rep: Reputation: 15
configuring nfs


I have two machines (desktop named palantir, and laptop named randir).
Both are running Linux Mint 17.2.
I have done everything I can think of, I'm trying to share the
home filesystem on palantir with randir. This is what I have done on
palantir
Quote:
Script started on Thu 07 Jan 2016 11:57:32 AWST
palantir beckwith #
palantir beckwith # # I have installed nfs-common & nfs-kernel-server
palantir beckwith #
palantir beckwith # rpcinfo -p | grep nfs
100003 2 tcp 2049 nfs
100003 3 tcp 2049 nfs
100003 4 tcp 2049 nfs
100003 2 udp 2049 nfs
100003 3 udp 2049 nfs
100003 4 udp 2049 nfs
palantir beckwith #
palantir beckwith # cat /proc/filesystems | grep nfs
nodev nfs
nodev nfs4
nodev nfsd
palantir beckwith #
palantir beckwith # rpcinfo -p | grep portmap
100000 4 tcp 111 portmapper
100000 3 tcp 111 portmapper
100000 2 tcp 111 portmapper
100000 4 udp 111 portmapper
100000 3 udp 111 portmapper
100000 2 udp 111 portmapper
palantir beckwith #
palantir beckwith # cat /etc/exports
# /etc/exports: the access control list for filesystems which may be exported
# to NFS clients. See exports(5).
#
# Example for NFSv2 and NFSv3:
# /srv/homes hostname1(rw,sync,no_subtree_check) hostname2(ro,sync,no_subtree_check)
#
# Example for NFSv4:
# /srv/nfs4 gss/krb5i(rw,sync,fsid=0,crossmnt,no_subtree_check)
# /srv/nfs4/homes gss/krb5i(rw,sync,no_subtree_check)
#
/home *(rw,sync,subtree_check)
/big *(rw,sync,subtree_check)
/fat *(rw,sync,subtree_check)
palantir beckwith #
palantir beckwith # cat /etc/hosts.allow
# /etc/hosts.allow: list of hosts that are allowed to access the system.
# See the manual pages hosts_access(5) and hosts_options(5).
#
# Example: ALL: LOCAL @some_netgroup
# ALL: .foobar.edu EXCEPT terminalserver.foobar.edu
#
# If you're going to protect the portmapper use the name "rpcbind" for the
# daemon name. See rpcbind(8) and rpc.mountd(8) for further information.
#
sendmail: all
rpcbind mountd nfsd statd lockd rquotad : \
192.168.0.2 192.168.0.3 192.168.0.4 192.168.0.5 192.168.0.6
palantir[01;34m beckwith #
palantir[01;34m beckwith # cat /etc/hosts.deny
# /etc/hosts.deny: list of hosts that are _not_ allowed to access the system.
# See the manual pages hosts_access(5) and hosts_options(5).
#
# Example: ALL: some.host.name, .some.domain
# ALL EXCEPT in.fingerd: other.host.name, .other.domain
#
# If you're going to protect the portmapper use the name "rpcbind" for the
# daemon name. See rpcbind(8) and rpc.mountd(8) for further information.
#
# The PARANOID wildcard matches any host whose name does not match its
# address.
#
# You may wish to enable this to ensure any programs that don't
# validate looked up hostnames still leave understandable logs. In past
# versions of Debian this has been the default.
# ALL: PARANOID
rpcbind mountd nfsd statd lockd rquotad : ALL
palantir beckwith #
palantir beckwith # /etc/init.d/nfs-kernel-server restart
* Stopping NFS kernel daemon [ OK ]
* Unexporting directories for NFS kernel daemon... [ OK ]
* Exporting directories for NFS kernel daemon... [ OK ]
* Starting NFS kernel daemon [ OK ]
palantir beckwith #
palantir beckwith # exportfs -ra
palantir beckwith #
palantir beckwith # exit
exit

Script done on Thu 07 Jan 2016 12:01:34 AWST
This is what I have done on randir

Quote:
Script started on Thu 07 Jan 2016 11:20:36 AWST
randir beckwith #
randir beckwith # # I have installed nfs-common & nfs-kernel-server
randir beckwith # #
randir beckwith # rpcinfo -p | grep nfs
100003 2 tcp 2049 nfs
100003 3 tcp 2049 nfs
100003 4 tcp 2049 nfs
100003 2 udp 2049 nfs
100003 3 udp 2049 nfs
100003 4 udp 2049 nfs
randir beckwith #
randir beckwith # cat /proc/filesystems | grep nfs
nodev nfs
nodev nfs4
nodev nfsd
randir beckwith #
randir beckwith # rpcinfo -p |grep portmap
100000 4 tcp 111 portmapper
100000 3 tcp 111 portmapper
100000 2 tcp 111 portmapper
100000 4 udp 111 portmapper
100000 3 udp 111 portmapper
100000 2 udp 111 portmapper
randir beckwith #
randir beckwith # cd /etc
randir etc # cat exports
# /etc/exports: the access control list for filesystems which may be exported
# to NFS clients. See exports(5).
#
# Example for NFSv2 and NFSv3:
# /srv/homes hostname1(rw,sync,no_subtree_check) hostname2(ro,sync,no_subtree_check)
#
# Example for NFSv4:
# /srv/nfs4 gss/krb5i(rw,sync,fsid=0,crossmnt,no_subtree_check)
# /srv/nfs4/homes gss/krb5i(rw,sync,no_subtree_check)
#
/home *(rw,sync,subtree_check)
randir etc #
randir etc # cat hosts.allow
# /etc/hosts.allow: list of hosts that are allowed to access the system.
# See the manual pages hosts_access(5) and hosts_options(5).
#
# Example: ALL: LOCAL @some_netgroup
# ALL: .foobar.edu EXCEPT terminalserver.foobar.edu
#
# If you're going to protect the portmapper use the name "rpcbind" for the
# daemon name. See rpcbind(8) and rpc.mountd(8) for further information.
#
randir etc #
randir etc # cat hosts.deny
# /etc/hosts.deny: list of hosts that are _not_ allowed to access the system.
# See the manual pages hosts_access(5) and hosts_options(5).
#
# Example: ALL: some.host.name, .some.domain
# ALL EXCEPT in.fingerd: other.host.name, .other.domain
#
# If you're going to protect the portmapper use the name "rpcbind" for the
# daemon name. See rpcbind(8) and rpc.mountd(8) for further information.
#
# The PARANOID wildcard matches any host whose name does not match its
# address.
#
# You may wish to enable this to ensure any programs that don't
# validate looked up hostnames still leave understandable logs. In past
# versions of Debian this has been the default.
# ALL: PARANOID

randir etc # tail fstab
#
# <file system> <mount point> <type> <options> <dump> <pass>
# / was on /dev/sda1 during installation
UUID=7b463346-db17-46f4-a8fa-bb1c8c0e4397 / ext4 errors=remount-ro 0 1
# /home was on /dev/sda3 during installation
UUID=e4e2e3f6-9334-451c-9adb-2f3ce4b4b0e6 /home ext4 defaults 0 2
# swap was on /dev/sda5 during installation
UUID=387f886c-5288-4df3-a31b-ba38b65c5e2b none swap sw 0 0
#
palantir:/home /palantir-home nfs noatime,nodiratime,rsize=32768,wsize=32768,async,timeo=14,intr,tcp,vers=3 0 0
randir etc #
randir etc # /etc/init.d/nfs-kernel-server restart
* Stopping NFS kernel daemon [ OK ]
* Unexporting directories for NFS kernel daemon... [ OK ]
* Exporting directories for NFS kernel daemon... [ OK ]
* Starting NFS kernel daemon [ OK ]
rabdir etc #
randir etc # mount palantir:/home
mount.nfs: Connection timed out
randir etc #
randir etc # exit
Script done on Thu 07 Jan 2016 11:27:41 AWST
this is what happens when I add "-v" to the mount command

Quote:
randir beckwith # mount -v palantir:/home
mount.nfs: timeout set for Thu Dec 17 10:37:34 2015
mount.nfs: trying text-based options 'rsize=32768,wsize=32768,async,timeo=14,intr,tcp,vers=3,addr=192.168.0.2'
mount.nfs: prog 100003, trying vers=3, prot=6
mount.nfs: portmap query failed: RPC: Unable to receive
What am I missing?
 
Old 01-07-2016, 07:34 PM   #2
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
I believe your problem is in the hosts.allow and hosts.deny settings, or the firewall on the NFS server. What happens if you remove hosts.deny?

Also, did you run showmount -e on the server?

See also http://community.linuxmint.com/tutorial/view/2009.
 
Old 01-07-2016, 08:12 PM   #3
beckwith
Member
 
Registered: Nov 2002
Location: Western Australia
Distribution: Mint / ubuntu
Posts: 118

Original Poster
Rep: Reputation: 15
configure nfs

Quote:
palantir etc # showmount -e
Export list for palantir:
/fat *
/big *
/home *
palantir etc #
Removing the line in /etc/hosts.deny now yields this meassage to mount -v

"mount.fs: portmap query failed: RPC Unable to receive."
 
Old 01-07-2016, 11:55 PM   #4
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
It turns out that you are not the only one with this problem. Put the error message into your favourite search engine and receiv tons of hits. One common issue is portmap not running, for example here: http://www.linuxquestions.org/questi...-5-nfs-483343/. The trouleshooting tool is rpcinfo, which you should run on the server and perhaps the client as well, but also netstat or its successor ss to see if somebody listens on port 111.

Perhaps something goes wrong when you start the NFS server services, or you need to start another service.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Configuring NFS . gardenair Linux - Networking 7 04-28-2010 05:45 AM
configuring nfs in linux ah_gal06 Linux - Newbie 3 08-09-2009 07:35 PM
Configuring NFS for TCP? Dox Systems - Brian SUSE / openSUSE 3 12-26-2007 10:39 AM
configuring NFS Client a_geek Linux - Networking 1 09-14-2003 04:54 PM
need help configuring NFS Shailendra Singh Linux - Networking 3 03-20-2001 03:15 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 06:28 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration