Techniques are provided for performing changes to a resource governed by a
locking mechanism. An entity (such as a server instance in a database
system cluster) requests permission to modify the resource. In response
to the request, the entity receives a first lock on the resource, which
grants permission to perform the change to the resource without making
the change permanent. After receiving the first lock, the entity performs
the change to a copy of the resource that resides in shared memory
without making another copy of the resource. After performing the change
and until receiving permission to make the change permanent, the entity
prevents the change to the resource from becoming permanent. After
performing the change, the entity receives a second lock on the resource,
which grants the entity permission to make the change permanent. After
receiving the second lock, the entity ceases to prevent the change to the
resource from becoming permanent.