From owner-freebsd-ports Sat Sep 15 8:30:16 2001 Delivered-To: freebsd-ports@freebsd.org Received: from pc1-cove4-0-cust214.bir.cable.ntl.com (pc1-cove4-0-cust214.bir.cable.ntl.com [213.105.93.214]) by hub.freebsd.org (Postfix) with ESMTP id B2FD337B403; Sat, 15 Sep 2001 08:30:04 -0700 (PDT) Received: from ntlworld.com (alpha.private [192.168.0.2]) (authenticated) by pc1-cove4-0-cust214.bir.cable.ntl.com (8.11.3/8.11.3) with ESMTP id f8FFU0m32758 (using TLSv1/SSLv3 with cipher RC4-MD5 (128 bits) verified NO); Sat, 15 Sep 2001 16:30:03 +0100 (BST) (envelope-from ianjhart@ntlworld.com) Message-ID: <3BA373F8.5FE5D35F@ntlworld.com> Date: Sat, 15 Sep 2001 16:30:00 +0100 From: ian j hart X-Mailer: Mozilla 4.78 [en] (X11; U; Linux 2.2.12 i386) X-Accept-Language: en MIME-Version: 1.0 To: "ports@FreeBSD.ORG" Cc: "Stephen D. Spencer" , "dwcjr@FreeBSD.org" Subject: Re: kernel oplocks References: <3BA3616C.31F9E9D0@ntlworld.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-ports@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org (from stable) > "Stephen D. Spencer" wrote: [snip kernel oplocks - separate post] > > From my research, it appears that oplocks are a performance > > feature that alots file/record(?) locking capabilities to the > > client for as long as that client is the only system > > accessing the file in question. (does away with the latency > > of going over the network to do file/record(?) locking. I'm > > not an expert on this subject, so I would send you elsewhere > > for a definitive description on what oplocks are. > > The Using Samba O'Reilley book is included with the samba docs > > and includes a description and some diagrams involving > > how oplocks work and what they are for) That was my conclusion also. > > > > If someone else comes along and accesses the file, the server > > is supposed to force the client to give up its oplock and go > > back to the server for locking operations. At any rate, > > there have been a number of commits to oplock.c since the > > release of 2.2.1a in July. I'm waiting for these updates > > to either settle or for 2.2.2 to come out before re-enabling > > oplocks. In the mean time, our file server being the big, > > beefy box that it is, is having no difficulty keeping up with > > the load sans oplocks. > > > > Stephen Spencer | > > | "Mutton yesterday, mutton today, and blimey, > > | if it don't look like mutton again tomarrer" > > | -Bert > NB: The following is my opinion from a very brief look at the code. Use a sizable pinch of salt. 'A' has oplock 'B' wants oplock The code is rather complex, as I expected, but it looks like the 'B' client sends the 'A' client a break oplock message, and then waits. This is the source of the "no response received to oplock break request..." messages. This is going to cause problems with more that a few simultainious clients. That's why there is a contension limit. This is set to 2 by default. In other words if there are more than two competing clients, turn off oplocks for that file. I was seeing lots of these no responce messages, and the loading went off the scale. Maybe this code is broken or has some kind of race. I'm also not sure that there are not problems with the underlying non-oplock locks. This is a read only share I wouldn't expect any blocking at that level. I've downloaded the 2.2 code and I'll have a look during the weekend. -- ian j hart To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message