Screenshot failure: Could not define domain: AlreadyExists

Issue

When running screenshot verification, you receive the following error message:

VM screenshot failed with error: Failed to create VM template createVM() returned: internal error: Could not define domain: AlreadyExists - The specified key, name, or identifier already exists.

This article is only applicable to devices using ESXi Virtualization to perform screenshot verification.

Environment

  • Datto SIRIS

Cause

A domain created by a previous screenshot was left in an unusable state, preventing the Datto appliance from automatically removing the leftover domain.

Solution

To fix the issue, you will need to remove the leftover domain from your hypervisor manually.

  1. Log in to vSphere.
  2. Look for a VM called "Unknown" on the hypervisor that the device uses for screenshots.

figure1.jpg
Figure 1: Unusable screenshot domain on a hypervisor

  1. Right-click the domain and select Remove from Inventory to de-register the VM so that it will no longer conflict with future screenshots.

figure2.png
Figure 3: Remove from Inventory

NOTE  Datto recommends using the Delete from Disk option because it removes all the data from the leftover VM. If the storage location of some or all of the VM's data is inaccessible (such as an NFS share that no longer exists), this option may be unavailable, or selecting it might result in an error message. If this happens, use Remove from Inventory instead.

  1. Re-run the screenshot to verify that you resolved the issue.