[Info-vax] Byte range locking - was Re: Oracle on VMS

BillPedersen pedersen at ccsscorp.com
Mon Nov 21 09:54:40 EST 2016


On Sunday, November 20, 2016 at 11:21:11 PM UTC-5, David Froble wrote:
> BillPedersen wrote:
> 
> > Well we do not yet have Postgres on VMS.  There are a couple stumbling points
> > that have gotten in the way.  Shared Stream IO to files to allow multiple
> > writers and byte-range locking in the same context as the SSIO.  There are
> > two features  which several "data" sharing applications running on Linux/Unix
> > quite often have in common and they are the biggest stumbling points of
> > getting these sorts of software to run on VMS effectively.
> 
> I guess my first question is, how does *ix do byte range locking?  There is 
> nothing special about locking between cooperating tasks.  Just needs a good 
> design, and then implementation.  With the initial help of John Santos I've 
> implemented a locking system.
> 
> The reason I've asked how *ix does the job is that it's my impression that to do 
> other than agreed upon fixed length data locks, it seems that otherwise would 
> have to know a bit more about the data.  That's a bit different from what I've 
> done in the past, and how the VMS DLM works.
> 
> Got any specifications?

The API is via either fcntl() of flock() depending on the flavor of the day.

Issue with these and Samba is that fcntl() limits the range to 2^31 bytes, according to some documents I have read while Windows clients can request up to 
2^32 or 2^64 bytes depending on the client.  So Samba has some other their own internal locking that I have to explore.

But without a coordinated cache then that might not help much.  Since since shared stream IO allows updating of non-overlapping regions in a block...

Anyway.

Have a Happy Thanksgiving Everyone!

Bill.



More information about the Info-vax mailing list