Creating a new virtual disk or RDM fails with the error: Operation failed because file already exists
search cancel

Creating a new virtual disk or RDM fails with the error: Operation failed because file already exists


Article ID: 304444


Updated On:


VMware vSphere ESXi


  • Creating a new virtual disk fails
  • Creating a new raw device mapping (RDM) fails
  • You see the error:

    Operation failed because file already exists


VMware ESXi 3.5.x Embedded
VMware ESX 4.1.x
VMware ESXi 4.1.x Embedded
VMware ESXi 4.1.x Installable
VMware ESXi 4.0.x Installable
VMware ESX Server 3.5.x
VMware ESX Server 3.0.x
VMware ESX 4.0.x
VMware ESXi 3.5.x Installable
VMware ESXi 4.0.x Embedded


A virtual disk or raw device mapping has an associated descriptor file and a binary file. The descriptor file is commonly referenced by the virtual machine and by VMware products. This file points towards the appropriate binary file for access to the actual data. For example:
# ls -l
-rw------- 1 root root 98388608 Jun 21 10:16 VMname-flat.vmdk
-rw------- 1 root root 469 Jun 22 12:35 VMname.vmdk

If the virtual machine has, for example, a second *-flat.vmdk file, the creation of the second disk fails.
This issue can occur for *-flat.vmdk, *-rdm.vmdk, and *-rdmp.vmdk files.
To resolve this issue:
  1. View the datastore via your datastore browser.
  2. Remove, rename, or relocate the offending *-flat.vmdk, *-rdm.vmdk, or *-rdmp.vmdk file .

    • Only delete the *-flat.vmdk file if you are sure that this file is no longer needed. Check the file's modification date to determine how long ago this disk was modified. If it is old, there is a better chance that you do not need it. If you are unsure if a file is needed, contact VMware Support.
    • *-rdm.vmdk and *-rdmp.vmdk files are safe to remove as they are just a link to the physical LUN. Deleting these files does not affect the LUN.
    • If a previous creation process was interrupted, ensure that residual or temporary files are not present and blocking subsequent attempts from succeeding.

If you have snapshots or you are know that this file is in-use by a live virtual machine, do not shut it down, perform a snapshot operation, or interrupt the virtual machine in any way. To determine if a file is in use, see Investigating virtual machine locks in ESX/ESXi (10051). If you are unsure or require further assistance, contact VMware Support.

Note: You can recreate a new disk descriptor file for the left-over *-flat.vmdk file. For more information, see Cannot power on a virtual machine because the virtual disk cannot be opened (1004232).