LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   mount.nfs: an incorrect mount option was specified (https://www.linuxquestions.org/questions/linux-newbie-8/mount-nfs-an-incorrect-mount-option-was-specified-4175477848/)

boby.kumar 09-20-2013 05:35 AM

mount.nfs: an incorrect mount option was specified
 
Hi

Getting the following error while mounting in linux:

[root@localhost ~]# mount -t nfs 10.20.30.12:/home/Team/EXT -o username=rncit,password=abc123 /var/log/new

mount.nfs: an incorrect mount option was specified.

/etc/exports file has following entry at remote machine(10.20.30.12)

/home/Team/ 10.127.154.0/24(rw,no_root_squash)

both machine is wrorking and mount point is ok.


Any idea about this? i am totally stucked here.

Thanks In Advance

zhjim 09-20-2013 06:58 AM

check man nfs for valid mount options

MensaWater 09-20-2013 07:22 AM

Quote:

Originally Posted by zhjim (Post 5031310)
check man nfs for valid mount options

Really? You couldn't have offered even a LITTLE guidance as to the issue? This site isn't really just to post RTFM messages is it?
You didn't even bother to direct him to look at mount or mount.nfs man pages which would have been more to the point.

boby.kumar:
Your issue appears to be the use "-o username=rncit,password=abc123".
That syntax isn't really for NFS mounts - its for Samba/SMB/CIFS mounts (i.e. shares from Windows to Linux) where you're required to have the username and password to get permission to the share. For NFS mounts you typically don't specify even username (though you can for a different purpose as outlined in the mount man) page and you do not specify username.

As zhjim points out there are man(ual) pages for most commands so often typing "man <command>" will get you started on the right path (i.e. "man mount").

boby.kumar 09-20-2013 08:30 AM

Thanks MensaWater.

when i try to mount it with cifs getting another error:

[root@localhost ~]# mount -t cifs //10.20.30.12/Team/EXT /var/log/new/ -o username=rncit,password=abc123
mount error(112): Host is down
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)

Both machines are addressable to each other. no network issue .

can you comment why i have this type of problem?

lleb 09-20-2013 09:06 AM

Quote:

Originally Posted by boby.kumar (Post 5031354)
Thanks MensaWater.

when i try to mount it with cifs getting another error:

[root@localhost ~]# mount -t cifs //10.20.30.12/Team/EXT /var/log/new/ -o username=rncit,password=abc123
mount error(112): Host is down
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)

Both machines are addressable to each other. no network issue .

can you comment why i have this type of problem?

ok, you can not use cifs to mount a NFS share, they are not the same technology. think of it like a Radio vs a TV. you can not use a standard radio receiver to pick up TV wave lengths or vis a vis for that matter.

You can not use SAMBA/CIFS to access NFS shares or vis a vis.

post your /etc/exports of the server as well as the output of export -a from the workstation you are trying to connect from. please use code flags as it will make life much simpler to read.

sorry my access to my home server is down or i would show you examples, but you can use the search function for these forums to look up my user name and NFS there are several examples out there. also google on howto mount NFS shares <foo> were foo is your distro. you might even want to look on google for some basic information about the server to verify it is properly configured.

MensaWater 09-20-2013 02:54 PM

In my prior answer I was saying the syntax you used is for SMB/CIFS/SAMBA not for NFS.

As Llieb points out you're trying to mix CIFS and NFS and they aren't the same.

Your original post shows you're apparently sharing out an NFS mount (that is what /etc/exports is used for) so it is NOT likely a CIFS mount. Using "-t cifs" is not what you need - getting rid of "-o username=rncit,password=abc123" is what you need assuming you're doing a Linux to Linux (or UNIX to UNIX or UNIX to Linux or Linux to UNIX file share). You really shouldn't use SMB/CIFS/SAMABA unless you're trying to share between Windows and Linux (or UNIX).

boby.kumar 09-21-2013 04:15 AM

Thanks MensaWater for update.

CIFS mount. Using "-t cifs" is not what you need - getting rid of "-o username=rncit,password=abc123" is what you need assuming you're doing a Linux to Linux (or UNIX to UNIX or UNIX to Linux or Linux to UNIX file share). You really shouldn't use SMB/CIFS/SAMABA unless you're trying to share between Windows and Linux (or UNIX).

yes, i was trying Linux to Linux mounting and got the point what missing for mounting.

Again Thanks a lot for support here.....

cheers...

zhjim 09-23-2013 04:25 AM

Quote:

Originally Posted by MensaWater (Post 5031320)
Really? You couldn't have offered even a LITTLE guidance as to the issue? This site isn't really just to post RTFM messages is it?
You didn't even bother to direct him to look at mount or mount.nfs man pages which would have been more to the point.

In my opinion this is a rtfm message. As the error message indicated. Invalid mount option. So check out the manpage for the correct once. And there on sees that the once used are not valid as the error message indicated. Educate rather then help. This fisher story.

lleb 09-23-2013 09:41 AM

Quote:

Originally Posted by zhjim (Post 5033026)
In my opinion this is a rtfm message. As the error message indicated. Invalid mount option. So check out the manpage for the correct once. And there on sees that the once used are not valid as the error message indicated. Educate rather then help. This fisher story.

while i agree with the fisher story, there are different ways of educating.

for some, myself included, the man pages can be very vague and confusing. many do not offer clear examples and if you can not understand what you read in the man page, they are as worthless as a bucket with a whole in the bottom.

pointing in the right direction without giving exact code is an other means of teaching and when combined with the man page(s) can still educate people and in many cases speed them along the path to being able to understand the man page(s).

while the OP failed to do his job properly by not researching how to mount an NFS share and tell us what he has tried and why he is trying the options he is telling, there is still no reason to just drop a foreign language on the guy and walk away. for a computer novice, or just someone new to linux for that matter, the man page might as well be a foreign language. to make an other quote along with yours... "it might as well be all greek to me" in this case me represents the OP.

so yes, educate, but be gentle about it.


All times are GMT -5. The time now is 01:45 PM.