FlashCopy indirection layer

The FlashCopy® feature provides the semantics of a point-in-time copy by using an indirection layer which intercepts I/Os that are targeted at both the source and target virtual disks (VDisks).

Starting a FlashCopy mapping causes this indirection layer to become active in the I/O path. This occurs as an atomic command across all FlashCopy mappings that are in the consistency group.

The indirection layer makes a determination about each I/O. This determination is based upon the following criteria:
  • The VDisk and LBA to which the I/O is addressed,
  • Its direction (read or write)
  • The state of an internal data structure, the FlashCopy bitmap.

The indirection layer either allows the I/O through to the underlying storage, redirects the I/O from the target VDisk to the source VDisk or stalls the I/O while it arranges for data to be copied from the source VDisk to the target VDisk.

Table 1 provides an overview of the FlashCopy I/O path actions.
Table 1. FlashCopy I/O path actions
VDisk Grain already copied? Host I/O operations
Read Write
Source No Read from source Copies the grain to the most recently started target VDisk for this source VDisk and then writes to the source VDisk.
Yes Read from source Write to source
Target No When the grain has not been copied, you can use the following algorithm to determine the VDisk that is being read:
  1. If newer target VDisks exist for the source VDisk of the FlashCopy mapping that is the target VDisk being written to and the data has already been copied, the read operation is from the target VDisk.
  2. If the source VDisk is not a target of another FlashCopy mapping, the read operation is from the source VDisk.
  3. If newer target VDisks exist for the source VDisk of the FlashCopy mapping that is the source VDisk being written to and the data has already been copied, the read operation is from the target VDisk.
When the grain has not been copied or overwritten, you can use the following algorithm:
  1. Use the algorithm for the corresponding read to determine the VDisk to read.
  2. If there is an older target VDisk and the data has not been copied to this VDisk, the data is written to this VDisk.
  3. If there is a target VDisk for this VDisk and the data has not been copied to this VDisk, the data is written to this VDisk.
  4. Writes to target.
Yes Read from target

When the grain has been copied, you can use the following algorithm to determine the VDisk that is being read:

  1. If newer target VDisks exist for this source VDisk and the grain has already been copied, the read comes from the oldest target VDisk.
  2. If there are no newer target VDisks, the read comes from the source VDisk.
Write to target
  1. If newer target VDisks exist for this source VDisk and the grain has already been copied, the read operation comes from the oldest target VDisk. If there are no newer target VDisks, the read operation comes from the source VDisk.
  2. If the grain has not already been copied to the next oldest target VDisk for this source VDisk, the same data is also copied to the next oldest target VDisk.
  3. Writes to target
Note: For cascaded FlashCopy operations, a VDisk can be both the source and the target. When the VDisk is both the source and target, the I/O path actions are handled as described for a target VDisk.

Source read operations

Source read operations are always passed through to the underlying source VDisk.

Target read operations

To process a read operation from the target VDisk, the FlashCopy mapping must consult the FlashCopy bitmap. If the data has already been copied to the target VDisk, the read operation is sent to the target VDisk. If the data has not already been copied, the target read operation is either sent to the source VDisk, or to another target VDisk if multiple target FlashCopy mappings exist for the source VDisk. While the target read operation is outstanding, no write operations that change the data that is being read are allowed to run.

Library | Support | Terms of use | Feedback
© Copyright IBM Corporation 2003, 2009. All Rights Reserved.