[smbfs] Timing problems with kernel 2.2.x?

Marc Haber Marc.Haber-lists at gmx.de
Thu Nov 11 19:29:24 GMT 1999


On Fri, 12 Nov 1999 01:45:05 +1100, you wrote:
>On Fri, Nov 12, 1999 at 12:57:55AM +1100, Marc Haber wrote:
>> [Note: This has been posted to linux-kernel and was ignored. Since
>> smbfs is maintained by the samba team, I am retrying here]
>
>	I saw it over on the kernel mailing list but I think it got
>ignored because no one else is doing quite what you are.  Quite
>frankly, I didn't pay it much attention because I don't use Debian
>and I have no clue what apt is doing, so your description of the
>problem wasn't very helpful.

apt is a package installation tool that can fetch and install packages
from almost any source accessible.

>> To maintain and install packages from CD-ROM to my Debian/GNU Linux
>> system, I use Debian's apt package. Since my Linux box is stowed away
>> in a closet, I use an smbfs mount to mount the CD-ROM drive from my
>> Windows desktop machine to the Linux box.
>
>	What release of Debian?

slink, apt from potato.

>> I now suspect that the 2.2 series smbfs needs some time after the
>> mount call returned to actually attach the mounted share to the mount
>> point in the local file system. Thus, access attempts issued
>> immediately after the mount fail.
>
>	When I just now read this I got a real strong sense of deja-vu.
>The earlier versions of smbmount in the Samba package (prior to 2.0.2
>I believe) did have a timing problem because the smbmount parent process
>exited after starting the remount child but before the mount was actually
>accomplished.  This created exactly the timing problem you described
>here.  It caused all sorts of havock with autofs.  :-)

Looks like this might be it.

>This is actually
>what originally got me involved with the Samba team in the first place.
>
>	That being said, however, that should have been fixed with
>recent versions of smbmount.

I can reproduce the problem with smbmount 2.0.6pre3. Didn't try the
released version yet.

>	If it's what I think it is then, no, I don't believe it's a
>kernel problem.  It's an smbmount problem.
>
>	But it shouldn't be present with 2.0.6pre3.  What is your EXACT
>command line to smbmount (minus account names and passwords, of course).

Looks like smbmount itself works fine. But, however:

To be able to mount the CDROM with a single command, I am using
/etc/fstab semantics. smbmount is linked to /sbin/mount.smb and I have
a line saying
|//janeway/cdom /mnt/cdrom smb noauto,user,noexec,nosuid,username=<username>,password=<password>
in /etc/fstab.

Now see:
|q:~# mount /mnt/cdrom ; ls -ali /mnt/cdrom ; sleep 5 ; ls -ali /mnt/cdrom
|total 2
|   7990 drwxr-xr-x   2 root     root         1024 Nov  6 16:48 .
|  10137 drwxr-xr-x   8 root     root         1024 Nov  7 16:55 ..
|total 525
|      2 dr-xr-xr-x   1 root     root          512 Mar  6  1999 .
|  10137 drwxr-xr-x   8 root     root         1024 Nov  7 16:55 ..
|    171 dr-xr-xr-x   1 root     root          512 Mar  6  1999 .disk
|    172 dr-xr-xr-x   1 root     root         1463 Mar  6  1999 README.1ST
|<snip>
|q:~#

Replacing "mount /mnt/cdrom" with "smbmount //janeway/cdrom /mnt/cdrom
-o username=<username>,password=<password>" works, though.

>	Did you have to change your command parameters to smbmount from
>previous versions used with the 2.2.x kernels to the 2.0.6 version of
>smbmount?

Absolutely. smbmount --version returns an error message stating
explicitly that it's Version 2.0.6pre3.

Greetings
Marc

-- 
-------------------------------------- !! No courtesy copies, please !! -----
Marc Haber          |   " Questions are the         | Mailadresse im Header
Karlsruhe, Germany  |     Beginning of Wisdom "     | Fon: *49 721 966 32 15
Nordisch by Nature  | Lt. Worf, TNG "Rightful Heir" | Fax: *49 721 966 31 29


More information about the samba mailing list