Top Nav

How to Fix VirtualBox “UUID already exists” Errors

If you’re running VirtualBox on a Windows computer, you’ll probably run into errors from time to time. When I migrated my virtual hard drives from one physical disk to another I ran into a permissions error. Apparently when Virtualbox creates a .vhd (or other format virtual hard drive) it bakes in a universally unique identifier that it uses to recognize VHDs. Normally it doesn’t cause problems, but in this case it prevents duplicates or moved virtual disks from running from an unknown location.

The error looks like this:

virtualbox error - failed to open hard disk uuid

“Failed to open the hard disk E:\VirtualBox VMs\Windows 8 \Windows 8 Enterprise2.vhd.

Cannot register the hard disk ‘E:\VirtualBox VMs\Windows 8 \Windows 8 Enterprise2.vhd’ {ca2bdc6a-a487-4e57-9fcd-509d0c31d86d} because a hard disk ‘E:\VirtualBox VMs\Windows 8 Enterprise\Windows 8 Enterprise2.vhd’ with UUID {ca2bdc6a-a487-4e57-9fcd-509d0c31d86d} already exists.

Result Code:
E_INVALIDARG (0x80070057)


IVirtualBox {3b2f08eb-b810-4715-bee0-bb06b9880ad2}

Callee RC:

Oracle has a chapter in the VirtualBox manual that covers UUID problems, which may reveal how to fix this. Or you can just follow the steps below.

How to Reset the UUID

To fix this you’ll need to run some text commands. Open up the Command Prompt. In both Windows 8 and Windows 7 it can be found by typing “cmd” into the Start Menu search box.

launch cmd prompt windows 7windows 8 command prompt

Now change the cmd prompt’s directory to the folder you installed VirtualBox in. If you put it in the default the command is this:

cd C:\Program Files\Oracle\VirtualBox\

cd to the virtualbox directory

Now type in the following command (or copy/paste using right click):

VBOXMANAGE.EXE internalcommands sethduuid “pathtovhdfile”

uuid changed

If everything worked you should see a message saying “UUID change to: …” and then the VirtualBox should work. All fixed!

, ,

9 Responses to How to Fix VirtualBox “UUID already exists” Errors

  1. E1000i June 13, 2013 at 6:31 am #

    This will work also for linux (ubuntu-debian) atleast:

    just can directly execute wherever your located a slightly different command:

    vboxmanage internalcommands sethduuid “newPathto.vdi”

    thanks for the post, it saved me a lot of reserach and reading!

  2. Victor July 18, 2013 at 7:57 pm #

    Thank you very much. :D

  3. Hamid August 12, 2013 at 10:19 pm #

    It works fine

  4. Adrian Constantin August 20, 2013 at 3:55 am #

    Thank you, Austin!
    You saved me a lot time!

  5. saif March 12, 2014 at 9:43 am #

    thinks man realy thinks you realy helpe me

  6. Alguien July 23, 2014 at 9:35 am #

    Thank you! It works!!

  7. remih August 20, 2014 at 11:52 pm #

    Thanks !!!
    Solution works great on Windows 8 and
    saved me a lot of time !:)

  8. KP September 19, 2014 at 12:56 am #

    Thanks for your blog.
    But i am stuck at another error that my vmdk file already exists …..

    actually i am importing the virtual alliance to VM box … so the moment i change the uuid and start importing again it gives the error cannot create because vmdk already exists.. Then i delete machine and start importing same UUID error occurs then again after fixing vmdk exists … So i am kind of looping in it …

  9. AbdreyS February 4, 2015 at 4:31 am #

    Excellent!!! Thank you very much! Best regards, Andrey from Russia

Leave a Reply


× Top Deals of the Day Shop Now