[Info-vax] New filesystem mentioned
Mark Berryman
mark at theberrymans.com
Tue May 14 13:07:25 EDT 2019
On 5/14/19 9:36 AM, Dave Froble wrote:
> .
> .
> .
> So, I don't understand the comment about DLM calls in ZFS? Locking is
> not part of a file system, locking is used in the tools that access a
> file system. Things such as a database, or RMS, or other such.
That would not be correct. At a minimum, access to the metadata of the
file system must be coordinated. Using the allocation bitmap as one
example, you have the following:
For a non-shared filesystem you have a couple of choices:
1. You single-thread all access to the bitmap so there is never more
than one writer.
2. You take out a lock in local memory to coordinate updating the bitmap.
For a share filed system, somewhat more work is involved.
Given: node A and node B in a cluster. Both node A and node B have
cached the current copy of the allocation bitmap.
Node A needs to make a change. It requests an exclusive DLM lock to
change the bitmap. DLM will notify all other nodes that node A now has
an exclusive lock and they must now invalidate their cached copy of the
bitmap. Node A updates the bitmap, and probably schedules a disk write
thereof.
What node A now does with the lock depends on the sharing strategy. If
metadata is shared by flushing to disk, node A can't convert the
exclusive lock back to shared mode until after the disk write completes.
That will allow another node's request for an exclusive lock to
complete and they will then read the updated bitmap back into memory.
Or, perhaps there is an algorithm to inform the other nodes of what
change was made. In that case, node A can't release the exclusive lock
until all other nodes inform node A they have made the necessary
updates. This would alleviate the need to flush through disk but would
require some sort of algorithm to decide by whom and when write-backs
are scheduled.
Now another node needs to modify the bitmap. That node needs to request
an exclusive lock and can't proceed until it gets it. Loop.
This is just one piece of metadata to which access must be coordinated,
and coordinated in a manner that just doesn't exist on a non-shared
filesystem.
So, yes, there would be a number of changes required to take a
filesystem from just about any non-VMS system and make it work on VMS.
Mark Berryman
More information about the Info-vax
mailing list