locking issues

Michael B. Allen mballen at erols.com
Thu Feb 1 07:10:01 GMT 2001


On Tue, Jan 30, 2001 at 12:34:50AM -0000, Romeril, Alan wrote:
> Looking at a Win2K to Win2K logon these packets are sent very quickly after
> the SMBntcreateX request, and there are many more SMBntcreateX packets that
> result in a SMBlockingX response than for an NT4 logon.  Where is this
> going?


This is a message I posted to the CIFS mailing list at
discuss.microsoft.com in December:

> I mapped a drive from one NT 4 Workstation to another and
> copyied a file from the local drive to the mapped share in a
> cmd window. I also saved a notepad file with "save as" to the
> same share. In both cases NetMon showed around 5-10[actually I
> think it was consistently 6] SmbComNTCreateAndX _round trips_
> for the filename in question. Most of them were error responses
> that the object did not exist, which it did not. Similarly there
> where multiple positive responses. Could someone enlighten me
> as to why such a packet storm is required to save or copy a
> file over the network?

No one ever replied. I did not examine thuroughly what was happening
but it looked like NT client was trying various locking options among
other things. I suspect two things at least are happening:

1) NT client is attempting to achive optimal sharing, locking, and
other conditions in one "atomic" request by trying the more favorable
but less servable options first only to fail and try options more likely
to succeed.

2) Requests passed though the various layers of API's for NT client
amplify the actuall traffic on the wire.

So this is not just a Samba issue although I believe Samba's
locking support is rather poor. There are dozens of flags for
SMB_COM_NT_CREATE_ANDX and in general it's a poorly documented
command. Samba would be hard pressed to serve it in a way that satisfies
NT clients when NT can't.

A little OT but pertainent I think.

Mike

-- 
signature pending




More information about the samba-technical mailing list