From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jamie Lokier Subject: Re: file leases Date: Wed, 22 Sep 2004 14:36:06 +0100 Sender: linux-fsdevel-owner@vger.kernel.org Message-ID: <20040922133606.GA27338@mail.shareable.org> References: <20040921084008.GG28786@mail.shareable.org> <20040921121629.319331BBAB@citi.umich.edu> <20040921124459.GC1001@mail.shareable.org> <20040921203033.GB21190@legion.cup.hp.com> <20040922113232.GA25022@mail.shareable.org> <20040922224119.6f73909b.sfr@canb.auug.org.au> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: jra@samba.org, andros@citi.umich.edu, linux-fsdevel@vger.kernel.org Return-path: Received: from mail.shareable.org ([81.29.64.88]:29909 "EHLO mail.shareable.org") by vger.kernel.org with ESMTP id S265211AbUIVNgP (ORCPT ); Wed, 22 Sep 2004 09:36:15 -0400 To: Stephen Rothwell Content-Disposition: inline In-Reply-To: <20040922224119.6f73909b.sfr@canb.auug.org.au> List-Id: linux-fsdevel.vger.kernel.org Stephen Rothwell wrote: > > This was triggered by creating 3rd.jpg (copied locally from > > elsewhere). Then viewing it in Internet Explorer on the Windows ME > > client. Then closing IE, and trying to copy the file locally. > > Closing IE, won't cause the Windows client to release the lease, it tries > to hold it as long as possible so that it knows its local cached copy of > the file is still correct. Yes, that's what I assumed. > > At about 11:50:49 I expect to see linux_oplock_receive_message and > > then linux_release_kernel_oplock -- because I see these at times when > > there's no stall -- but I *don't* see either in the Samba log after > > this point: > > So this is not consistent i.e. it works as expected most of the time? It's not consistent. Most of the time it stalls with oplocks enabled in Samba. Specifically: If I have been viewing or editing a file in Windows, then most of the time oplocks viewing or editing the same file on the server stalls. I thought it was stalling every time. However when I did these tests today with the "cp" command, I was surprised to see it not stalling sometimes. So it is inconsistent. > > Perhaps more worryingly, there is no communication with Windows ME, so > > Windows ME may still think it has the oplock. 20 minutes later, after > > viewing the file a couple more times in ME, and after editing it > > locally, there are no further messages with "oplock" or "linux" in the > > Samba log. > > This makes sense as Windows still thinks it has the oplock. > > > It looks like either: > > > > (1) Linux leases aren't working: they're not signalling Samba. > > > > (2) or, Samba is not interfacing with Linux leases properly, so > > is missing the signal. > > Either is possible. Is this a standard kernel.org 2.6.8 kernel and > a standard samba 3.0.6 - or are these distribution versions? Gentoo versions. Kernel is gentoo-dev-sources-2.6.8, which is Linux 2.6.8 plus a few small patches that don't touch locks.c or anything that looks relevant. Samba is samba-3.0.6-r3, again none of the small patches looks relevant. -- Jamie