Unable to mount CIFS share from /etc/fstab

according to (https://wiki.ubuntu.com/MountWindowsSharesPermanently) should be:

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

Try to look what you are doing wrong. Make it simple, remove the file_mode, user and gid, maybe the iocharset and sec variables as well. If this will work, add always one...


The

sec=ntlm

doesn't solve the problem on my desktop (Ubuntu 13.10). It seems the parameter format changed a bit about the domain. Used to work this before but does not now:

-o username=msdomain/msusername,password=mspassword

I've changed to this format:

-o dom=msdomain,username=msusername,password=mspassword

and it works well now.


sec=ntlm worked for me too...

I had load of problems with this from the CLI and fstab but it worked fine from the GUI (on Fedora 20) to a home NAS and to rule out things like complex passwords I created a user with a simple username and password and then used the CLI command mount.cifs to test with. I kept getting permission denied (13) all the time so did a Wireshark of the GUI and CLI attempts.

If you do this then you want the Protocol Response message back from the server and expand all of the fields to check for the version/dialect (in my case the server wanted version 1.0) and more importantly the security requirements, a 1 means that the server requires something and my server required password encryption so setting sec=ntlm fixed it for me :-D.

Many thanks to Dee above!

Tags:

Mount

Samba

Cifs