EMC SnapSure is an EMC software feature that enables you to create and manage checkpoints, which are point-in-time, logical images of a Production File System (PFS). Snapsure uses a copy on first modify principle. A PFS consists of blocks. When a block within the PFS is modified, a copy containing the block’s original contents is saved to a separate volume called the SavVol. Subsequent changes made to the same block in the PFS are not copied into the SavVol. The original blocks from the PFS in the SavVol and the unchanged PFS blocks remaining in the PFS are read by SnapSure according to a bitmap and blockmap data-racking structure. These blocks combine to provide a complete point-in-time image called a checkpoint (snapshot).
Checkpoint (snapshots) types
A checkpoint reflects the state of PFS at the point-in-time the checkpoint is created. SnapSure supports two types of checkpoints:
- Read-only checkpoint
- Writeable checkpoint
SnapSure can maintain maximum of 96 read-only checkpoints and 16 writable checkpoints per PFS while allowing PFS applications continued access to realtime data.
Key components of SnapSure
- Production File System (PFS)
- Snapshot (sometimes called checkpoint) – logical point-in-time view of data
- SavVol – Stores original data blocks to preserve the point in time view and holds modified blocks if a writeable snapshot is used
- Bitmap – identifies changesd data blocks in the PFS
- Blockmap – Records the address of data blocks in the SavVol
- Baseline Snapshot – read-only snapshot from which a writeable snapshot can be created.
Example with PFS, Bitmap, Blockmap and SavVol
Writes to PFS with snapshots
Let’s break down what happened on example provided above:
- There is a Snapshot (checkpoint) made on PFS.
- User is changing data in PFS for blocks DB01, DB05, DB08
- VNX is updating the Bitmap from 0 to 1 which indicates that this block was changed after snapshot has been made
- VNX is adding a row in Blockmap saying in which SavVol Block address, un-changed Data Block is held
- VNX is putting original data (unchanged blocks) in SavVol
OK, that’s pretty simple and clear. Isn’t it? The fun starts when we have a second snapshot in the game.
- When you create a second snapshot the Bitmap is zeroed and associated with second snapshot – remember only one bitmap per PFS
- The Blockmap of first snapshot is preserved so we can retrieve the data from that snapshot later on (if needed)
Reads from PFS with snapshots
If we would like to read the oldest store data, it’s straight forwad, we read only from PFS (Production File System).
If we would like to read the data pointed to latest snapshot, VNX first read the bitmap, check what blocks has changed, and read unchanged data from PFS, changed data from SavVol (checking the location in Blockmap)
IF we would like to read the data from older snapshot (not the latest one!) we ignore the bitmap (because it only contains the information of changed data between right-now and latest snapshot. We start with this snapshot blockmap, and we read all blocks from SavVol that are pointed in blockmap. Later on we read from all newer blockmaps. If there is new value for already read block we ignore them! We want to get the ‘oldest possible’ data counting from the snapshot we want to read from. Once we read from all Blockmaps we read remaining data from the PFS, because it will still be the same.
- Automatic SavVol sizes based on size of PFS
- if PFS ≥ 20GB then SavVol = 20GB
- if PFS < 20GB and PFS > 64MB then SavVol = PFS size
- if PFS ≤ 64 MB then Savvol = 64 MB
- All snapshots of a PFS share the same SavVol
- A maximum SavVol size could be determined with manual SavVol creation.
SavVol Automatic Extension
Automatic extension is triggered by High Water Mark (HWM). This feature prevents inactivation of older snapshot. By default, the WHM is set to 90%, but this amount can be lowered if necessary. The maximum value of HWM is 99%, but anything higher than 90% is not recommended. Automatic extension can be manually disabled by setting the HWM to 0%.
If the SavVol was created using AVM, the SavVol space will be extended in 20GB increments until the capacity is below the HWM once more. If the SavVol was manually created, the automatic extension feature will extend the SavVol by 10% of the PFS. If there is no space left, and SavVol is 100% full, Snapsure will inactivate the oldest snapshots (beginning with writeable snapshots), untill enough space is reclaimed.
By default, SnapSure is not able to consume more than 20% of the space available to the VNX. This limit of 20% can be changed in /nas/sys/nas_param
SnapSure Additional Functions
- Schedule snapshot creation – quick tip. To nos schedule snapshot creation at 1 minute pass the hour- because that’s why the VNX is backing up its database and the snapshot creation can fail.
- Refresh snapshots – in other words, delete the selectedsnapshot and put the actual point-in-time situation of PFS on that place.
- Restore a PFS to a point-in-time. Nice feature is that we can restore single files.