Changed Block Tracking for VMware Backups
Changed Block Tracking (CBT) is a VMware feature that optimizes incremental backup procedures.
Enable Changed Block Tracking in VMware Plans
Changed Block Tracking feature can be enabled for any VMware backup plan. To learn how to enable it, refer to the VMware and Hyper-V Backup chapter.
Changed Block Tracking Explained
Virtual machines running on ESX/ESXi hosts track changed disk sectors. Changed Block Tracking identifies the disk sectors modified between two changeset stamps.
On VMFS partitions, CBT can also identify all the disk sectors that are in use.
Virtual disk block changes are tracked on the virtualization layer. When a backup plan is run, it requests transmission of only the blocks that have been changed since the last backup, or the blocks in use.
To identify modified disk sectors since the last change ID, these items are required:
- The host must be ESX/ESXi 4.0 or later
- The virtual machine owning the disks to be tracked must be hardware version 7 or later
- I/O operations must go through the ESX/ESXi storage stack. So NFS is supported, as is RDM in virtual compatibility mode, but not RDM in physical compatibility mode. VMFS is supported, whether backed by SAN, iSCSI, or local disk
- CBT must be enabled for the virtual machine (see below)
- Virtual machine storage must not be (persistent or non-persistent) independent disk, meaning unaffected by snapshots
For CBT to identify disk sectors in use with the special *\ change ID, these items are required:
- The virtual disk must be located on a VMFS volume, backed by SAN, iSCSI, or local disk
- The virtual machine must have zero (0) snapshots when CBT is enabled, for a clean start
In some cases, such as a power failure or hard shutdown while virtual machines are powered on, CBT might reset and lose track of incremental changes. In vSphere 4.1 and prior, Cold Migration (but not Storage vMotion) could reset but not disable CBT. In vSphere 5.x versions earlier to vSphere 5.5 Update 2, storage vMotion resets CBT.
Check if a Virtual Disk has a CBT Enabled
To make sure if a virtual disk has CBT Enabled, proceed as follows:
- Open the vSphere Client and select a powered-off virtual machine.
- Right-click the virtual machine and go to Edit Settings -> Options -> Advanced/General -> Configuration Parameters.
- The configuration file (.vmx) of the virtual machine contains the entry: ctkEnabled = "TRUE".
Note: Set the value to False to disable CBT
- For each virtual disk, the .vmx file contains the entry: scsix:x.ctkEnabled = "TRUE".
- For each virtual disk and snapshot disk there is a .ctk file.
After a successful backup and full snapshot consolidation, there should be no snapshot-related .ctk files remaining in the datastore. For example: vmname-000001-ctk.vmdk