LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Why fstab doesn't mount smbfs (https://www.linuxquestions.org/questions/linux-newbie-8/why-fstab-doesn%27t-mount-smbfs-177678/)

rjkfsm 05-04-2004 06:30 AM

Why fstab doesn't mount smbfs
 
I was doing research on why my Windows box can't access the shares on my Linux box and ran across an article on fstab and smbfs. I've seen a lot of people post here about problems with mounting smbfs shares on boot and what I read made sense. DISCLAIMER: If this person was wrong, then I am wrong and I'm sure someone will correct me. What the article taught ended up working, so I'm assuming it's correct.

When your system boots, it goes through several runlevels. As you go through the boot sequence, the fstab is loaded before your ethernet card. As a result, the mounting fails. What you need to do is have the smbfs mount occur after the ethernet card is initialized.

There are two ways of doing this:

put a 'mount -t smbfs' command with options in the /etc/rc.d/rc.local file or put a uid=xxx option in your fstab like this:

//shelby/shareddocs /mnt/shared smbfs username=shunter,password=xxx,uid=000,users,exec,rw 0 0

Russ

ironoxide 12-16-2011 11:11 AM

I spent a long time to find the problem: STP - Spanning Tree Protocol.
When a host is attached such as a computer, printer or server the switch port will always go into the forwarding state, albeit after a delay of about 30 seconds while it goes through the listening and learning states. Full story: fstab mount error at boot.

grim76 12-16-2011 12:15 PM

You can also try adding the _netdev option to your mount options. That is supposed to wait until the network is online before mounting the location.

ironoxide 12-16-2011 12:23 PM

_netdev doesn't work (if the problem is STP) because network it's online (but switch doesn't forward packets because of STP listening/learning state)


All times are GMT -5. The time now is 10:35 PM.