Bug 440 - smbmout mounts and then hangs
Summary: smbmout mounts and then hangs
Status: RESOLVED WONTFIX
Alias: None
Product: Samba 2.2
Classification: Unclassified
Component: File Services (show other bugs)
Version: 2.2.7a
Hardware: All Linux
: P3 critical
Target Milestone: ---
Assignee: Gerald (Jerry) Carter (dead mail address)
QA Contact:
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-09-11 18:59 UTC by Thomas Sprinkmeier
Modified: 2005-11-14 09:27 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Thomas Sprinkmeier 2003-09-11 18:59:14 UTC
I have samba (2.2.7a-8.9.0) on a RH9 system (2.4.20-20.9smp) on a
hyper-threading P4 trying to mount a drive on a Windoes 2000 server.

smbmount //w2k/share ./w2k.share -o username=me/domain,password=foobar,uid=root

This command works, though sometimes it hangs (i.e. does not return). The
sharepoint is mounted, and I can "kill -9" the smbmount and it stays mounted.

Usually the first mount works but trying to mount more than one sharepoint at
the same time causes problems.

once one of them hangs I can mount as many additional sharepoints as I want, e.g.
smbmount //w2k/share1 ./w2k.share1 -o username=me/domain,password=foobar,uid=root
smbmount //w2k/share2 ./w2k.share2 -o username=me/domain,password=foobar,uid=root
(this one hangs, go to another window and)
smbmount //w2k/share3 ./w2k.share3 -o username=me/domain,password=foobar,uid=root
smbmount //w2k/share4 ./w2k.share4 -o username=me/domain,password=foobar,uid=root
smbmount //w2k/share5 ./w2k.share5 -o username=me/domain,password=foobar,uid=root
I can even mount the same sharepoint if I ue a different windows account:
smbmount //w2k/share2 ./w2k.share2 -o
username=someone/domain,password=snafu,uid=root


Same thing happens when I boot the non-smp kernel, tried another networking
card, a different PC, different servers (W2K-prof and SAMBA) and 2.2.8a.

2.2.5-10 (default w/ RH8) seems to work OK.
Comment 1 Thomas Sprinkmeier 2003-09-11 20:22:22 UTC
I can reliably force the hang by scecifying mixed-case sharepoints, e.g.:

smbmount //w2k/Share1 ./w2k.share1 -o username=me/domain,password=foobar,uid=root

(note capital S on //w2k/Share1) will always hang.

2.2.7-3.7.3 does not seem to mind how I capitalize the sharepoint name.
Comment 2 Thomas Sprinkmeier 2003-09-15 01:28:56 UTC
Apparnetly this is a bug in fork()

https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=90036

suggested 'fix' is to use kernel 2.4.18 or to use a script to replace smbmount:

------- Additional Comment #15 From Ivan Wilks on 2003-06-14 09:26 -------

I've used the following on my rh9 :-

 mv /usr/bin/smbmount  /usr/bin/_smbmount
 more <<EOT > /usr/bin/smbmount
 #!/bin/sh
 /usr/bin/_smbmount \$1 \$2 \$3 \$4 \$5 \$6 \$7 \$8 \$9  &        
 sleep 1
 kill -QUIT \$! > /dev/null
 EOT
 chmod 0755 /usr/bin/smbmount

------- Additional Comment #16 From kas@informatics.muni.cz on 2003-06-16 15:56
-------

The following commands apparently fixes the problem for me:

mv /usr/bin/smbmount /usr/bin/smbmount.orig
cat <<EOF >/usr/bin/smbmount
#!/bin/bash
export LD_ASSUME_KERNEL=2.2.5
exec /usr/bin/smbmount.orig "$@"
EOF
chmod 755 /usr/bin/smbmount

-Yenya
Comment 3 Gerald (Jerry) Carter (dead mail address) 2004-02-17 08:45:36 UTC
Sorry, but the 2.2 is not under development any longer.
If you can reproduce this bug against the latest 3.0 release, 
please reopen this bug and change the version in the report.
Thanks.
Comment 4 Gerald (Jerry) Carter (dead mail address) 2005-11-14 09:27:13 UTC
database cleanup