Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Can't access NAS via nfs (SOLVED)
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
andrewwalker27
l33t
l33t


Joined: 27 Jun 2005
Posts: 660

PostPosted: Fri May 08, 2009 9:13 pm    Post subject: Can't access NAS via nfs (SOLVED) Reply with quote

I'm having major trouble connecting my NAS box to my Gentoo box via nfs. Here's the error I get

athlon64 fred # mount -t nfs 192.168.0.9:/mnt/ide3/fred /home/fred/nfs
mount.nfs: an incorrect mount option was specified
athlon64 fred #

The mount point is correct, I can telnet into the NAS box to check and can access the files so why is nfs complaining? I've checked portmap is working and I'm logged in as root. I've even checked the NAS box /etc/exports script, here it is.

/mnt/ide3/fred 192.168.0.0/255.255.255.0(rw,root_squash) 192.168.0.3(rw,root_squash)

Anyone know where to go from here? I can access the NAS box with samba ok but nfs is driving me mad. I'm running ~x86_64 and kernel 2.6.29-gentoo-r4 but this problem has been going on for months. I can access the NAS via nfs on a Ubuntu box so why not Gentoo?
Any help would be greatly appreciated!


Last edited by andrewwalker27 on Mon May 18, 2009 6:29 pm; edited 1 time in total
Back to top
View user's profile Send private message
Hu
Administrator
Administrator


Joined: 06 Mar 2007
Posts: 23192

PostPosted: Fri May 08, 2009 10:54 pm    Post subject: Reply with quote

What is the output of rc-update show | nl ; emerge --pretend --verbose net-fs/nfs-utils on the Gentoo client? Are any packets sent from the Gentoo machine to the NAS when you run the mount command? Can the Gentoo system mount shares from any other system, such as the Ubuntu client?
Back to top
View user's profile Send private message
cyrillic
Watchman
Watchman


Joined: 19 Feb 2003
Posts: 7313
Location: Groton, Massachusetts USA

PostPosted: Sat May 09, 2009 12:44 am    Post subject: Re: Can't access NAS via nfs Reply with quote

andrewwalker27 wrote:
I'm logged in as root ...

/etc/exports wrote:
... root_squash

Could permissions have something to do with the problem you are having ?
Back to top
View user's profile Send private message
Hu
Administrator
Administrator


Joined: 06 Mar 2007
Posts: 23192

PostPosted: Sat May 09, 2009 3:17 pm    Post subject: Reply with quote

That may cause him problems later, but root squashing should only be meaningful when root tries to access a file/directory exported via the NFS mount. So far, the NFS mount has not even completed, so he has not gotten far enough for root squashing to break anything.
Back to top
View user's profile Send private message
Sven Vermeulen
Retired Dev
Retired Dev


Joined: 29 Aug 2002
Posts: 1345
Location: Mechelen, Belgium

PostPosted: Sat May 09, 2009 8:08 pm    Post subject: Reply with quote

What information do you get when you add the -v option (to have mount be more verbose)?
_________________
Please add "[solved]" to the initial topic title when it is solved.
Back to top
View user's profile Send private message
andrewwalker27
l33t
l33t


Joined: 27 Jun 2005
Posts: 660

PostPosted: Sun May 17, 2009 5:13 pm    Post subject: Reply with quote

Thanks for the response, sorry it's taken me so long to reply!
Here's the info as requested
athlon64 fred # rc-update show | nl ; emerge --pretend --verbose net-fs/nfs-utils
1 bootmisc | boot
2 fsck | boot
3 hostname | boot
4 root | boot
5 gpm | default
6 local | default nonetwork
7 localmount | boot
8 swap | boot
9 sysctl | boot
10 urandom | boot
11 hwclock | boot
12 consolefont | boot
13 keymaps | boot
14 modules | boot
15 mtab | boot
16 sshd | default
17 procfs | boot
18 termencoding | boot
19 net.lo | boot
20 hdparm | boot
21 syslog-ng | default
22 vixie-cron | default
23 hotplug | default
24 xdm | default
25 dbus | default
26 cupsd | default
27 samba | default
28 hald | default
29 udev | sysinit
30 lircd | default
31 portmap | default
32 hddtemp | default
33 ntpd | default
34 lm_sensors | default
35 ntp-client | default
36 devfs | sysinit
37 acpid | default
38 cpudyn | default
39 device-mapper | boot
40 fbcondecor | boot default
41 net.eth0 | default
42 lcd4linux | default
43 dmesg | sysinit
44 savecache | shutdown
45 killprocs | shutdown
46 mount-ro | shutdown

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild R ] net-fs/nfs-utils-1.1.6 USE="tcpd -kerberos -nonfsv4" 0 kB

Total: 1 package (1 reinstall), Size of downloads: 0 kB
athlon64 fred #

I've tried re-building nfs-utils but no change.
The -v option doesn't anything more useful I'm afraid.

athlon64 fred #
mount -v -t nfs 192.168.0.9:/mnt/ide3/fred /home/fred/nfs
mount.nfs: timeout set for Sun May 17 18:11:12 2009
mount.nfs: text-based options: 'addr=192.168.0.9'
mount.nfs: mount(2): Operation not supported
mount.nfs: an incorrect mount option was specified
athlon64 fred #

I'm out of ideas!
Back to top
View user's profile Send private message
Nerevar
l33t
l33t


Joined: 31 May 2008
Posts: 720

PostPosted: Sun May 17, 2009 5:28 pm    Post subject: Reply with quote

Confirm you have support built into your kernel:
Code:
grep NFS /usr/src/linux/.config

http://en.gentoo-wiki.com/wiki/NFS/Client
Back to top
View user's profile Send private message
andrewwalker27
l33t
l33t


Joined: 27 Jun 2005
Posts: 660

PostPosted: Sun May 17, 2009 5:34 pm    Post subject: Reply with quote

Looks like it is,
CONFIG_NFS_FS=y
CONFIG_NFS_V3=y
# CONFIG_NFS_V3_ACL is not set
# CONFIG_NFS_V4 is not set
CONFIG_ROOT_NFS=y
CONFIG_NFSD=y
CONFIG_NFSD_V3=y
# CONFIG_NFSD_V3_ACL is not set
# CONFIG_NFSD_V4 is not set
CONFIG_NFS_COMMON=y
Back to top
View user's profile Send private message
krinn
Watchman
Watchman


Joined: 02 May 2003
Posts: 7471

PostPosted: Sun May 17, 2009 8:49 pm    Post subject: Reply with quote

result of
Code:
rpcinfo -p 192.168.0.9
Back to top
View user's profile Send private message
andrewwalker27
l33t
l33t


Joined: 27 Jun 2005
Posts: 660

PostPosted: Sun May 17, 2009 8:57 pm    Post subject: Reply with quote

Here we are

athlon64 fred # rpcinfo -p 192.168.0.9
program vers proto port
100000 2 tcp 111 portmapper
100000 2 udp 111 portmapper
100003 2 udp 2049 nfs
100003 3 udp 2049 nfs
100021 1 udp 1024 nlockmgr
100021 3 udp 1024 nlockmgr
100021 4 udp 1024 nlockmgr
100005 1 udp 600 mountd
100005 1 tcp 603 mountd
100005 2 udp 600 mountd
100005 2 tcp 603 mountd
100005 3 udp 600 mountd
100005 3 tcp 603 mountd
athlon64 fred #
Back to top
View user's profile Send private message
krinn
Watchman
Watchman


Joined: 02 May 2003
Posts: 7471

PostPosted: Sun May 17, 2009 9:10 pm    Post subject: Reply with quote

ok then try
Code:
mount -v -o proto=udp -t nfs 192.168.0.9:/mnt/ide3/fred /home/fred/nfs
Back to top
View user's profile Send private message
andrewwalker27
l33t
l33t


Joined: 27 Jun 2005
Posts: 660

PostPosted: Sun May 17, 2009 9:17 pm    Post subject: Reply with quote

Well don't know quite why but that worked!
Any idea what this proves?

athlon64 fred # mount -v -o proto=udp -t nfs 192.168.0.9:/mnt/ide3/fred /home/fred/nfs
mount.nfs: timeout set for Sun May 17 22:17:01 2009
mount.nfs: text-based options: 'proto=udp,addr=192.168.0.9'
192.168.0.9:/mnt/ide3/fred on /home/fred/nfs type nfs (rw,proto=udp)
athlon64 fred #
Back to top
View user's profile Send private message
krinn
Watchman
Watchman


Joined: 02 May 2003
Posts: 7471

PostPosted: Sun May 17, 2009 9:19 pm    Post subject: Reply with quote

andrewwalker27 wrote:

100003 2 udp 2049 nfs
100003 3 udp 2049 nfs


It prove you have a dirty nas that should also handle tcp instead of only udp
you should have seen
Code:
    100003    2   udp   2049  nfs
    100003    3   udp   2049  nfs
    100003    2   tcp   2049  nfs
    100003    3   tcp   2049  nfs


this is a know bug, that should have been fix in nfs-utils, the proto detectioin is bork because the mountd in your NAS do handle tcp
Back to top
View user's profile Send private message
andrewwalker27
l33t
l33t


Joined: 27 Jun 2005
Posts: 660

PostPosted: Sun May 17, 2009 9:30 pm    Post subject: Reply with quote

Many thanks, should I report this as a bug even though it's a known one?
I'm using a 35HD-DUAL-NAS if anyone else is following this thread (centroid chipset and sausalito firmware).
I've heard a rumour Debian can be run on this box, maybe that may be a good solution!
Back to top
View user's profile Send private message
krinn
Watchman
Watchman


Joined: 02 May 2003
Posts: 7471

PostPosted: Sun May 17, 2009 9:47 pm    Post subject: Reply with quote

i'm not quiet sure what was the fix.
2 issues were found : issue 1: can't mount without udp, issue2: crash when detecting.

So it was fix, but i don't know witch one was fix, considering your case, i suppose the crash was fix, but not the proto detection.

As far as i know, using udp doesn't disturb operations, it's just you have to force the proto to udp (witch is nothing to do when you know you should do it, can't really say adding -o proto=udp or proto=udp in fstab is something hard to do :D )

I don't have a nas personnaly, but if you think this might cause trouble to many users, you could still file bug it, i suppose it will endup in vapier's hands and he kick ass at nfs trouble.
a won't fix/invalid won't kill you no ?

edit: at least, adding solve to your thread will help next nas user find that thread got a solve with a nas problem
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum