level2 kernel oplocks?

Steven Danneman steven.danneman at isilon.com
Fri Apr 3 19:15:54 GMT 2009


> Hi!
> 
> Attached find some initial work for supporting level2 kernel oplocks.
> 
> One thing I'm stuck with now is the following:
> 
> * smbd (process A) holds an exclusive lease
> 
> * someone else (process B) tries to open the file
> 
> * smbd (process A) gets a signal
> 
> How does smbd find out if process B opened the file for r/w, so that
> process A has to drop the lease completely, or if process B opened for
> r/o, so that a downgrade would be sufficient??
> 
> Volker

Hey Volker,

A Level II oplock is only contended by a write or byte-range lock
request.  In the case you described, where an open operation contended
an existing client's Exclusive oplock, process A would downgrade its
client to a Level II oplock.  The access mask of the open request is
ignored when deciding how to break oplocks.

-Steven


More information about the samba-technical mailing list