RE: Caching and callbacks

New Message Reply About this list Date view Thread view Subject view Author view Attachment view

From: Boris Z. (boris@conley.com)
Date: 02/24/99-12:17:50 PM Z


Message-ID: <01BE5FF8.148018E0.boris@conley.com>
From: "Boris Z." <boris@conley.com>
Subject: RE: Caching and callbacks
Date: Wed, 24 Feb 1999 13:17:50 -0500



On Wednesday, February 24, 1999 11:43 AM, Spencer Shepler [SMTP:shepler@Eng.Sun.COM] wrote:
> "Boris Z." wrote:
> > 
> > > I don't see how op-locks, which are as I understand it, really a cache
> > > consistency mechanisms and not a lockign mechanism, can solve this
> > > problem. If a process on each client makes modifications to the same
> > > part of the database, without file/record locks, or share reservations at
> > > open time, won't the database get corrupted.
> > 
> > Server will delay any write operation on the oplock protected range until
> > oplock expires or until oplock call-back will be answered. Let's talk about
> > this on Connectathon.
> 
> Unfortunately, I am not willing to wait 2 weeks to complete this discussion.
> 
> I have been told that applications in a Windows environment that care about
> file content updates will use file locking.  It is also my understanding that
> the oplock mechanism is used by the client OS to enable caching.  One side 
> effect that the client OS takes advantage of is that if it holds an oplock 
> for a file and the application requests a file lock, that file lock is not 
> propagated to the file server.  I don't believe this is necessary but is an 
> optimization that the client employs.


Locks and oplocks are semantically different.
Locking protects data from simultaneous access by the applications. 
Oplocks protect file system caches. Lock cannot be broken.
Oplocks can be broken, if someone needs to access the data.Clients cannot
just hold oplocks. We can associate oplocks with the lease tmo and expire them
even if clients do not answer for oplock notification callback.
If a client wants to renew the oplock, it can be refused even if lease TMO did not
expire. With locks it incorrect.

Boris


New Message Reply About this list Date view Thread view Subject view Author view Attachment view

This archive was generated by hypermail 2.1.2 : 03/04/05-01:46:43 AM Z CST