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.
This problem has been posted before, but so far no one who did was able to get an answer. Anyway, here goes... maybe I'm lucky and someone has an idea what the problem is by now.
I have two servers, both with Windows 2003 and a lonely Linux box which tries to mount shares from these servers via Samba.
Now, winbind authentication and everything is working perfectly fine, BUT as soon as I use a Samba version higher than 3.0.2a or 3.0.3 I have problems with mounted shares. Interestingly mounting them works fine without any errors in logs, but as soon as I try to list the directory content of one of these I get "ls - permission denied".
Of course I made sure that the permissions are right for the mount point, I have been playing around off and on for several months with parameters in fstab - to no avail. Everytime a new Samba version is released I try and end up having to go back to 3.0.2a to be able to mount these shares.
Oh and, mounting them via CIFS works fine, I do not get any such error messages when accessing shares that way. But alas CIFS currently has problems with shares of a distributed file system which renders it useless for my purposes.
Does anyone out there know how to fix either of these problems? If more information is required please let me know.
I assume you want to mount the remote address by name, to do this you have to have proper Wins resolution, either by Query or Wins server on local broadcast.
mount -t smbfs //SERVERNAME/SERVERSHARE /mnt/SHARE -o username=user1,password=123456
another way is to have text file, with root read-only persmission (chmod 600) containing with this context
call it whatever you like, put it in the directory you want to mout, ie /mnt/SHARE/pass
username = user1
password = 123456
You then can add in your /etc/fstab , an arguement "credentials=/mnt/SHARE/pass"
This will then call the file to supply the password authentication to your windows share. See "man smbmount"
in your /etc/fstab, more options can be applied
/mnt/SHARE //SERVERNAME/SHARE smbfs credentials=/mnt/SHARE/pass 0 0
See "man fstab"
Also verify in your /etc/samba/smb.conf , that your
Verify these are correct for your network configuration, this will help resolve WINS name resolution. Add Static names to local /etc/samba/lmhosts file.
I am actually using a credentials file (located in /etc/samba). Aside from the different location of the credentials file the lines in /etc/fstab looks just like your example (with a ro parameter).
As I said, it works fine like this with Samba 3.0.2a and 3.0.3 but not with a version higher than this.
But I run into the same problem even if I do a command line smbmount with a credentials file or not. This is a really confusing problem.
WINS resolution is working fine, it does mount the share just fine. I just cannot access anything in it afterwards. A normal "ls" shows the mount point but when I do "ls -la" the mount point is invisible. Curiously I can "cd" into the mount point, but a "ls" results in the "permission denied" problem I mentioned.
I can access samba shares from the windows machines and I can access windows shares with smbclient. Only smbmount is giving me a headache.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.