LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat
User Name
Password
Red Hat This forum is for the discussion of Red Hat Linux.

Notices


Reply
  Search this Thread
Old 03-09-2011, 10:58 PM   #1
axel_2078
LQ Newbie
 
Registered: Jun 2010
Location: Fairview Heights, IL
Distribution: Fedora
Posts: 8

Rep: Reputation: 0
(Scientific Linux 6)- can't mount nfs shares


For some strange reason, I can't seem to be able to mount the nfs share from my FreeNAS system on SL6. I'm able to do it just fine from Ubuntu 10.04, Linux mint 9, Fedora 14, CentOS 5.5, and OS X Snow Leopard, so it has to be something specific to SL6. The below command does not work:
mount freenas:/mnt/share /test
I get a mount.nfs error message that says "requested NFS version or transport protocol is not supported."
I also tried this command which yielded the same result:
mount -t nfs FreeNAS:/mnt/share /test

Am I doing something wrong or is this just a bug with SL6?
 
Old 03-11-2011, 08:43 AM   #2
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 6,197
Blog Entries: 9

Rep: Reputation: 832Reputation: 832Reputation: 832Reputation: 832Reputation: 832Reputation: 832Reputation: 832
Quote:
requested NFS version or transport protocol is not supported
That is telling you there is a mismatch in the NFS version.

You can specify nfs version on the mount command. On your SL system type "man mount.nfs" to see what versions it supports. I don't use SL - the man page on my CentOS5 system says in part:

Quote:
version
Specify NFS file system version. Either nfs4 or nfs. If the
command is mount.nfs4 or the vfstype option of mount(8) command
is nfs4, then version 4 is used, else version 3 or 2 is used.
 
Old 03-15-2011, 08:56 AM   #3
mikey99
Member
 
Registered: Nov 2008
Location: UK
Distribution: RHEL, Fedora
Posts: 68

Rep: Reputation: 12
Quote:
Originally Posted by MensaWater View Post
That is telling you there is a mismatch in the NFS version.
Correct. Don't forget, the default in RHEL6 (and I presume SL6) is NFSv4. For RHEL6 clients, you can just use the mount command with no options. If you use -t nfs it attempts to connect using nfs4 and if not available, drops to nfs3.

If you want to force the client to mount using version3, then mount using the vers=3 option in fstab. Look in /proc/mount (specifically vers= option) to see which version a mount is using.
 
Old 03-16-2011, 08:54 AM   #4
axel_2078
LQ Newbie
 
Registered: Jun 2010
Location: Fairview Heights, IL
Distribution: Fedora
Posts: 8

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by mikey99 View Post
Correct. Don't forget, the default in RHEL6 (and I presume SL6) is NFSv4. For RHEL6 clients, you can just use the mount command with no options. If you use -t nfs it attempts to connect using nfs4 and if not available, drops to nfs3.

If you want to force the client to mount using version3, then mount using the vers=3 option in fstab. Look in /proc/mount (specifically vers= option) to see which version a mount is using.
The problem is, I don't think the latest stable FreeNAS supports NFSv4 exports...only nfs3. So how would I force SL6 to try to mount the nfs share on FreeNAS? I have a feeling I'll run into the same problem when CentOS 6 rolls out too (5.5 works just fine though). Would I use the below command?

mount vers=3 freenas:/mnt/data /test
 
Old 03-16-2011, 06:05 PM   #5
axel_2078
LQ Newbie
 
Registered: Jun 2010
Location: Fairview Heights, IL
Distribution: Fedora
Posts: 8

Original Poster
Rep: Reputation: 0
SOLVED! Guys, my sincerest apologies. This turned out to be simply a ID10T error. I just re-examined my /etc/auto.nfs file and found a typo in the path of my nfs export from the server. It was set to mount a directory that didn't exist on the server. I was tired when I set this up and had a lot on my mind. Once I changed it to the correct path, everything worked and I was able to mount it via automount.
 
Old 03-17-2011, 04:11 PM   #6
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 6,197
Blog Entries: 9

Rep: Reputation: 832Reputation: 832Reputation: 832Reputation: 832Reputation: 832Reputation: 832Reputation: 832
Glad you solved it. Please go to Thread Tools and mark it Resolved. That way anyone else having an issue in the future can see your solution.

FYI: When you are testing something like automounter a good sanity check is to simply try mounting the filesystem manually at another mount point. That way you can determine if it truly is an NFS issue or an automounter issue. (That is to say it sometimes helps to go to basic tools when you're having an issue with complex ones to help narrow the problem down.)
 
Old 03-18-2011, 09:00 AM   #7
axel_2078
LQ Newbie
 
Registered: Jun 2010
Location: Fairview Heights, IL
Distribution: Fedora
Posts: 8

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by MensaWater View Post
FYI: When you are testing something like automounter a good sanity check is to simply try mounting the filesystem manually at another mount point. That way you can determine if it truly is an NFS issue or an automounter issue. (That is to say it sometimes helps to go to basic tools when you're having an issue with complex ones to help narrow the problem down.)
That's very good advice and that's actually what I did to discover the problem. I had been trying to get this working with automount for a couple days and was almost ready to pull my hair out. Then, the next day, I tried doing it manually using the mount command and mounted it to a test directory I had created and it worked! I then unmounted it and tried mounting it to another directory and it worked again! Then I decided to look over my /etc/auto.master and /etc/auto.nfs files again. The auto.master file was fine, but the auto.nfs file had the wrong directory path in it. That one mistake cost me several hours of troubleshooting.
 
Old 06-25-2014, 04:42 PM   #8
davinken
LQ Newbie
 
Registered: Aug 2011
Location: Texas, USA
Distribution: CentOS, Fedora
Posts: 6

Rep: Reputation: Disabled
Wink Non-existent share - same symptom

Old thread but relevant - got the same error when trying to mount a CentOS 6.5 share from a Fedora 20 box. It was as simple as a non-existent share, but the error message was misleading. Once corrected, it worked like charm...

E.g. i meant to test the "nuclear" share from "bonn" but forgot that I was testing "robotics" shared from other machine before.

Code:
[root@calgary /mnt]$ mount bonn:/export/research/robotics test1/
mount.nfs: requested NFS version or transport protocol is not supported
[root@calgary /mnt]$ mount bonn:/export/research/nuclear test1/
[root@calgary /mnt]$ cd test1
[root@calgary /mnt/test1]$ l
total 20
4 drwxrwxrwx  2 root root 4096 Jun 25 16:27 .
4 drwxr-xr-x. 4 root root 4096 Apr 23 16:52 ..
4 -rw-r--r--  1 root root  133 Jun 25 16:27 helium
4 -rw-r--r--  1 root root  133 Jun 25 16:27 hydrogen
4 -rw-r--r--  1 root root 2048 Jun 25 16:27 oxygen
Just my half cent...
 
1 members found this post helpful.
  


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
How to mount NFS shares on clients when server starts? HellesAngel Linux - Server 4 05-03-2010 02:55 PM
why do I have to mount NFS shares manually in ubuntu 9.04? lxuser Linux - Networking 3 07-12-2009 11:55 PM
Mount foreign NFS shares gypsy_rabbi Linux - Laptop and Netbook 1 04-07-2005 12:45 PM
automatically mount NFS shares turbo_acura Linux - Networking 1 10-28-2004 05:33 PM
How do you mount NFS shares? Thaidog Linux - Newbie 1 04-04-2004 09:48 PM


All times are GMT -5. The time now is 03:36 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration