more on locks
Henry J. Cobb
hcobb at fly2.berkeley.edu
Fri Sep 24 14:18:39 EST 1993
Thanks, OK I won't mess with the policy of global database locking.
But unless there is something else I've overlooked, I'll add a
section to filopen() (protected by a #ifndef NO_ATOMIC_CREATION (I hope
that nothing is really that broken)).
I'll check for spec == "atomic" and do an open() with O_WRONLY |
O_CREAT | O_EXCL followed by an fdopen() for lockfile itself.
Then I'll change the ...WriteLock functions to atomically create
the lockfile, or remove it, etc.
Also I'd like to set a special protocol in the client/server setup
to request a break of the lock.
All of the OS'es I am aware of have some procedure for atomic file
creation, and I know of no other IPC which is common to all of them. If
this is a problem under say VMS or MVS or Novell or Appleshare, etc.,
please let me know.
Henry J. Cobb hcobb at fly2.berkeley.edu SFB Tyrant
More information about the Acedb