Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Most of people got this Permission Denied access when mounting a
Windows Shared folder
following mounting ->
usually : mount -t cifs //<MachineName>/<Shared Folder> /mnt/Shared -o username=<username>,password=<password>
give you error 13.
correct : mount -t cifs //<MachineName>/<SharedFolder> /mnt/Shared -o username=<DomainName>/<username>,password=<password>
Yes! the only deference is "domain name:<DomainName>" is missing. In case of No Domain try to put your <MachineName> there.
cifs does not locate domain itself (I guess).
I'm absolutely positive that it was not a permissions problem such as just not qualifying the username with the domain, but rather the fact that this was 3 years ago and some samba servers I had didn't support cifs then (they were 2.x series). If you look up, I did mention in the original post that the credentials used were exactly the same in both cases of the smbfs and cifs lines.
no no, you misunderstand, the original problem was that when passing the exact same credential string the connection would work with smbfs and not cifs. This was due to the older samba servers.
The problem you are describing is in fact a different and trivial problem of you just not qualifying the username with the domain.
Yes boss superb it is really appropriated, without using Domain name it is creating huge difference here.
Thanks,
-- Amit Gandhi
Quote:
Originally Posted by mastfaraz
Solution
Most of people got this Permission Denied access when mounting a
Windows Shared folder
following mounting ->
usually : mount -t cifs //<MachineName>/<Shared Folder> /mnt/Shared -o username=<username>,password=<password>
give you error 13.
correct : mount -t cifs //<MachineName>/<SharedFolder> /mnt/Shared -o username=<DomainName>/<username>,password=<password>
Yes! the only deference is "domain name:<DomainName>" is missing. In case of No Domain try to put your <MachineName> there.
cifs does not locate domain itself (I guess).
actually, you know what, I take it all back, cifs is way way way better than smbfs.
smbfs doesn't complain because it silently fails in many cases. This is worse, because you then find out that what you were doing hasn't worked.
Anyway, I don't have any probs at the moment on this.
I just made the same realization that you did, but this thread didn't help me. I needed to do: mount.cifs //SERVER/SHARE /mnt/point -o domain=THEDOMAIN,user=user,pass=pass
in order to make it work.. not really sure why DOMAIN\user didn't work. I agree now that it is better than SMBFS, but there should be more specific error-messages. I wasted a couple of hours before I realized that the cifs-mount-command differed from the smbfs and then I used a couple of hours trying different combos to get it working. Really stupid to waste peoples time like this. But I agree that CIFS is looking better than SMB in terms of stability. Still.. Annoying differences are still annoying.
yeah, but for some reason it did not work. I am starting to wonder if there is something weird with my character-set that prevents the / from being interpreted such by the mount.cifs, but I cannot find anything like that in the code. Can anyone confirm that DOMAIN/user is working or is it DOMAIN//user or DOMAIN\\user or DOMAIN\user?
which says pretty much exactly what's been said here. I finally found out why I got the mount error 13 problem using cifs and an external credentials file. This is my entry in /etc/fstab:
The file /etc/samba/auth.smb contains only 2 lines:
username=foo
password=bar
But the key thing is that this file must not contain any extra white space before or after those 2 lines, i.e., the file should end right after the last password character without a newline! I had a newline and it caused the error. I had tried adding the domain name prefix to the username and that didn't help. Perhaps smbfs is more forgiving about how it reads credentials, but cifs should not be so picky, but it is.
Today I had exacttly the same problem: I was unable to mount cifs share (of course domain/user/pass were correct). It turned out that administrator disallowed NTLMv1 auth so I had to use -o sec=ntlmv2. If that doesn't help then try to synchronize clock on client & server.
I have been trying to get CIFS to work for almost two years. And this is also for how long I have been googling for this problem -- without any solution.
Now, finally, this did the trick! Using "-o sec=ntlmv2" I can finally mount my share! What's weird is that it had always worked with smbclient, and also with the smb:// KIO slave in KDE. This means that they must have implemented the v2 authentication.
Most of people got this Permission Denied access when mounting a
Windows Shared folder
following mounting ->
usually : mount -t cifs //<MachineName>/<Shared Folder> /mnt/Shared -o username=<username>,password=<password>
give you error 13.
correct : mount -t cifs //<MachineName>/<SharedFolder> /mnt/Shared -o username=<DomainName>/<username>,password=<password>
Yes! the only deference is "domain name:<DomainName>" is missing. In case of No Domain try to put your <MachineName> there.
cifs does not locate domain itself (I guess).
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.