W2K-Terminal Server vs Samba 2.0.7

Jeremy Allison jeremy at valinux.com
Wed Dec 20 18:21:59 GMT 2000


On Tue, Dec 19, 2000 at 10:55:17PM -0500, acherry at pobox.com wrote:
> 
> Yes, even if Win2K doesn't exhibit the same limits that 4.0 did, if
> you hit a limit on the server side you'll still have problems.
> 
> We never actually ran into an open file limit with our WTS 4.0 system
> and Samba.  The problem we ran into was with file locking.  Having
> multiple users on one smbd process was particularly disastrous for
> multiuser Access databases.  At least on Solaris, Samba uses fcntl()
> record locking for byte-range locks.  The big problem is that fcntl()
> locks are meant to prevent one process from modifying data that
> another process has locked -- they aren't meant to be used within the
> context of the *same* process.  MS Access uses byte-range locks on the
> .LDB file to keep track of which users have what database records
> locked.  This works fine with individual PCs, but not with multiple
> Terminal Server users.  The second WTS user to open up the database
> would blow away the first WTS user's locked entry in the LDB file (you
> can actually sit and watch this by running "strings" and/or "lslk" on
> the LDB file).  If you have only WTS users accessing the database,
> you'll never get more than one entry in the LDB file (that of the most
> recent user to open the database). This tends to result in database
> corruption and other unpredictable behavior.
> 
> Switching the WTS clients to disallow multiple users per connection
> gets around this problem, since you end up with separate smbd
> processes for each user.
> 
> If Win2K doesn't allow turning this "feature" off, the only
> alternatives I could see are to either rewrite Samba's locking
> mechanisms to be entirely internal (using UID/PID or UID/client
> pairs)

Funny you should mention this but this is *exactly* what
we have done for Samba 2.2 and HEAD :-) :-).

We now pass remote SMB locking torture testing that we can
get NT to fail on :-).

I would be very interested in you testing out the new Samba
2.2 code on your multi-user access databases, it should work
*perfectly* - if it doesn't it's a bug and we need to know
about it :-).

Thanks,

		Jeremy.
-- 
--------------------------------------------------------
Buying an operating system without source is like buying
a self-assembly Space Shuttle with no instructions.
--------------------------------------------------------




More information about the samba-ntdom mailing list