无法从/ etc / fstab挂载CIFS共享

Modified on: Thu, 14 Jun 2018 10:45:53 +0800

我的/etc/fstab中有一行自13.04以来停止工作的年代:

//192.168.100.2/share   /mnt/popcorn      cifs username=MyUserName,password=MyPassword,user,gid=sambashare,file_mode=0664 0   0

它给了我:

mount /mnt/popcorn
mount error(13): Permission denied
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)

dmesg和沙漠中的阳光一样有用:

[  622.471321] CIFS VFS: Send error in SessSetup = -13
[  622.471458] CIFS VFS: cifs_mount failed w/return code = -13

我知道user / pass组合是正确的,因为这样可以正常工作:

bart@dosar:~$ smbclient //192.168.100.2/share --user=MyUserName
Enter nmt's password: 
Domain=[WORKGROUP] OS=[Unix] Server=[Samba 3.0.32]
smb: \> ls
...

如何在Ubuntu 13.04上永久挂载CIFS / Samba共享?

最佳答案

https://wiki.ubuntu.com/MountWindowsSharesPermanently)应该是:

//servername/sharename  /media/windowsshare  cifs  username=msusername,password=mspassword,iocharset=utf8,sec=ntlm  0  0

试着看看你做错了什么。简单一点,删除file_mode,user和gid,也可以是iocharset和sec变量。如果这样可行,请始终添加一个......

作者:Dee

相关问答

添加新评论