Tuesday, 4 April 2017

vSphere: Snapshot Error - Change Tracking Target File Already Exists

I ran into an issue when attempting to consolidate and create snapshots of VMs being backed up using NetBackup. The snapshot creation would start but fail at 10% with the following error;
An error occurred while saving the snapshot: Change tracking target file already exists.
 This is quite a easy fix and simply involves moving the ctk files out of the root folder.

1. SSH to ESXi host that the VM is running on.
2. Navigate to the virtual machine directory using the following command;
cd /vmfs/volumes/datastore/virtual_machine/
3. List the contents of the directory with "ls" and look for file including "-ctk.vmdk".
4. Create a temporary directory using the following command;
mkdir temp
5. Move the ctk files into this directory using the following command;
 mv *-ctk.vmdk temp/
6. Attempt to take another snapshot to confirm this is now working.