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.
I know. Another SAMBA question. I promise I've read about 30 different postings on a variety of sites and tried all their recommendations, but still no luck. So here goes.
I'm running RedHat 9.0 on a Dell Latitude C800 laptop, dual booting with Win XP using Grub loader (installed in root, not MBR). There were no problems during the install and I'm pretty much a happy camper. (Haven't booted XP in weeks. :-)
I have a number of SAMBA shares that I mount manually. I want to mount a couple of them at boot time.
Here's the command I use to mount them manually. It works fine.
mount -t smbfs -o username=admin,password=foo '//My Server/javadocs' /javadocs
I've tried a dozen or so different ways to get this sucker to mount automatically when I boot. The closest I've come is with this entry in my /etc/fstab:
//Meade\040Server/javadocs /javadocs smbfs auto,user=admin,password=foo 0 0
I say “the closest” because at least it doesn't tell me I have a bad line in fstab. When I run “mount -a ” I get this error:
2299: session setup failed: ERRDOS - ERRnoaccess (Access denied.)
SMB connection failed
So I feel I'm getting close, but still no big smiles. Have I incorrectly handled the space in the remote file share? (Wrapping it in ' ' or “ “ resulted in a bad fstab line error.) Should I be using automount instead? (If so, a pointer to explicit instructions would be helpful, because I've tried that too.)
(I should mention that putting the “mount -t” statement directly in rc.local worked, but I want to do this “properly”. And that method locked up during boot time when I tried to do 4 mounts instead of just the 1.)
That solved the ERRnoaccess problem, but it still fails during boot. Interestingly, I can now use "mount -a" after boot and it mounts just fine. Does this suggest that something is loading in the wrong order during boot? Any other ideas? I'm close now. I can feel it.
FWIW, the /var/log/messages file says this:
May 28 11:51:01 localhost mount: SMB connection failed
May 28 11:51:01 localhost kernel: FDC 0 is a post-1991 82077
May 28 11:51:01 localhost netfs: Mounting SMB filesystems: failed
May 28 11:51:01 localhost kernel: NET4: Frame Diverter 0.46
May 28 11:51:01 localhost netfs: Mounting other filesystems: succeeded
As root, use the "lsmod" command to see what kernel modules are loaded. If you see smbfs then you know that's being loaded as a kernel module vs being compiled _into_ the kernel itself.
Feel free to point away. Linux is making me feel stupid enough. You can't do any more damage. :-)
I've looked through /var/log/messages, but I can't find anything that suggests where the smbfs module gets loaded. What should I be looking for?
And assuming that this is the problem, would I be better advised to change the loading order, or rebuild the kernel with smbfs support built in? Pros? Cons?
I've been following this thread for a while and I'm trying to auto-mount my smbfs shares in the fstab file as well.
After running the LSMOD utility I have found that
SMBFS does not appear in the list. Does this mean that it is not running as a kernel module? How do I make it run as a kernel module? Is that what may be keeping my persitent mounts from working correctly (assuming my syntax is correct..etc.)?
Jefficus, I think I have the same problem you have or had been experiencing. Did you ever get a resolution to this? There seems to be no way to automount more than one windows share. I would love to talk to someone who has been able to accomplish this to determine their settings.
dbaker> I have three windows shares automounted using the line in my previous post. Just add a line for every share to your fstab file and it should work.
OK, Slooper, there must be something different about your linux/samba configuration than mine. I have a number of questions to ask you.
1) Which version of redhat are you running? I am running version 9.
2) Do you have smbfs compiled into the kernel or in a module. I have mine in a module.
3) You say that you need to make the win shares read-only. Did it not work with full access? Actually, I tried both and could get neither to work.
4) When I try your options smbfs reports "Unrecognized mount option noexec" at bootup point "Mounting SMB filesystems".
I can't understand what could be wrong. Christ, I can automount each of the two shares alone in /etc/fstab but when I include both smbmnt fails. I wish there was some diagnostic I could run or log I could check to get some specific error message. I checked the /var/log/messages file but it just tells you if the service was successful in starting or not. I can tell that when the kernel boots up.
1) redhat 8
2) mine is a module as well
3) it was working fine at one time with full access, however a linux guru that I know told me that you run the risk of file corruption when writing to NTFS through Samba
3) I get that error too, but it doesn't seem to affect my mount. It still works.
check the mount point folders and see - maybe it worked after all
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.