问题描述
我尝试安装cif,但是我收到以下错误,我没有找到错误。
I try to mount cifs, but i have got following error and i don't find the error.
~# mount -a
~# mount error(22): Invalid argument
我的/ etc / fstab
I try if in my /etc/fstab
//192.168.0.1/ShareRep /home/user/share cifs credentials=/usr/local/etc/whisper.credentials,uid=501,sec=ntml 0 0
我的凭据文件/ usr /本地/ etc / whisper.credentials
my credentials file /usr/local/etc/whisper.credentials
username=user
password=password
我在Debian 7.6
I am on Debian 7.6
推荐答案
在没有来自 dmesg
的更详细的错误的时候,我会看到一个会导致事情失败的打字错误。您可以选择 sec = ntml
。这是错误的,应该是 sec = ntlm
。注意 ml 应该是 lm
In the absence of a more detailed error from dmesg
I do see one typo that will cause things to fail. You have the option sec=ntml
. This is is wrong and should be sec=ntlm
. Notice how ml should be lm
确定OP正在使用 OS / X 作为 Samba 文件服务器。有一些修改(巫术魔术)的选择,需要做出来使其在大多数口味的Linux上工作。在partiuclar中,您需要指定选项 nomix,sec = ntlmssp,noperm
。我发现这个埋在Ubuntu的(和答案)在苹果论坛上提到了一条消息。总而言之,这出现了:
It was determined that the OP was using OS/X as a Samba file server. There are some modifications (voodoo magic) to the options that need to be made to get this to work on most flavours of Linux. In partiuclar you need to specify the options nounix,sec=ntlmssp,noperm
. I found this buried in a Ubuntu question (and answers) that mentions a thread of messages on the Apple forums. In summary this appeared:
也可能需要一个后续的帖子建议 noperm
。
A followup post suggested noperm
might be needed as well.
如果你修改你的fstab条目是这样的,可能会起作用:
If you modify your fstab entry to be this it may work:
//192.168.0.1/ShareRep /home/user/share cifs credentials=/usr/local/etc/whisper.credentials,uid=501,nounix,sec=ntlmssp,noperm 0 0
这篇关于Debian 7,fstab,mount.cifs参数无效的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!