Database Reference
In-Depth Information
The preceding discussion is making an optimistic assumption, namely, that everything is available as expected.
Now what if this is not the case and instance SSKY3 did not have the block? In such a situation, instance SSKY3 would
continue with the instruction received from the GCS. However, in the transfer operation, instance SSKY3 would send
a message indicating that it no longer has a copy of the block and instance SSKY2 is free to get the block from disk. On
receipt of this message, instance SSKY2 will, after confirming/informing the GCS, retrieve the block directly from disk.
What happens if there is a third instance or for that matter a fourth, fifth, or sixth instance that is requesting
access to read this block? In all of these situations, the behavior and order of operation is similar. In Figure 2-9 ,
instance SSKY3 will copy the block to the respective requesting instances; and Oracle controls these copies by
maintaining the information in the GRD.
Read/Write Behavior
A block that was read by instance SSKY3 and now copied to instance SSKY2 is requested by instance SSKY1 for a write
operation. A write operation on a block would require instance SSKY1 to have an exclusive lock on this block. We now
go through the steps involved in this behavior:
9. Instance SSKY1 sends a request for an exclusive resource on the block to the GCS on the
mastering instance SSKY4 .
10. The GCS, after referring to the GRD on instance SSKY4 , ascertains that the block is being
held by two instances, SSKY3 and SSKY2 . The GCS sends a message to all (instance SSKY2 in
our example) but one instance (instance SSKY3 ) is requesting moving the block to a NULL
location. (Moving the block to a NULL location or status changes the resource from shared
mode to local mode). This effectively tells the instances to release the buffers holding the
block. Once this is done, the only remaining instance holding the block in a shared mode
would be instance SSKY3 .
11. GCS requests instance SSKY3 to transfer the block for exclusive access to instance SSKY1 .
Figure 2-9 illustrates the steps involved when instance SSKY1 requires a copy of the block that is currently held by
instances SSKY2 and SSKY3 for a write operation.
 
Search WWH ::




Custom Search