Link to home
Avatar of beehlers
beehlersFlag for United States of America

asked on

How do I copy a vmdk from one datastore to another datastore?

I have a VMware installation, v6.7.   I have 3 datastores, one on a server and two on a Drobo.  I have one VM where the C drive is in a datastore that is on the Drobo, and the rest of the drives attached to the VM are on the server.  I need to bring them together on the server.  I have tried copying the vmdk using the web vSphere client but it keeps ending in failure with the message "Failed - A general system error occurred: Invalid change tracker error code".  The drive is thick provisioned and there is enough space on the target drive to copy it there.  How can I do this?
Avatar of Andrew Hancock (VMware vExpert PRO / EE Fellow/British Beekeeper)
Andrew Hancock (VMware vExpert PRO / EE Fellow/British Beekeeper)
Flag of United Kingdom of Great Britain and Northern Ireland image

Copy and Paste between datastores should work the VM is powered off?

I assume no vCenter Server no Migrate feature or storage vMotion?

Otherwise you could try at the ESXi shell
Avatar of beehlers

ASKER

Yes, the VM is powered off, I have not used the ESXi shell in the past, it is turned on and I can ssh to it, but am not well versed in the commands.
Is this VM currently backed up using any third party software, because that error is a CBT tracking error code.

Okay try the following this will CLONE the disk.

change to the folder/directory where the VMDK exists

e.g.

cd /vmfs/volumes/vmname

Open in new window


then
vmkfstools -i /vmfs/volumes/vmname/vmname.vmdk /vmfs/volumes/destination-datastore/vmname.vmdk

Open in new window

Thanks for those directions, I have started the process. Here is possibly a dumb question....  In the folder where this vmdk lives, there are several other files.  Do I need to copy all those files also or do I just need the vmdk and it will recreate all the stuff it needs?
Your question is how do I copy a VMDK from one datastore to another, you don't state why!

if it's to move the VMDK to another datastore, what you will need to do is

1. Remove the disks from the VM (do not delete from datastore).
2. Add new Hardware, and select Add Existing Disk, and browse to this disk you've CLONED.
3. Power up the VM.
4. Check the VM is all working.
5. Delete the original disk. (or leave and archive, delete after a few weeks)
Ran the clone and got the same error, "Clone: 100% done. Failed to clone disk: Invalid change tracker error code (5948)"

ASKER CERTIFIED SOLUTION
Avatar of Andrew Hancock (VMware vExpert PRO / EE Fellow/British Beekeeper)
Andrew Hancock (VMware vExpert PRO / EE Fellow/British Beekeeper)
Flag of United Kingdom of Great Britain and Northern Ireland image

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
Yes we do backup with a 3rd party backup.
Ok, thanks.  Running again.  
That worked!  Thank you sooooo much!  I was at a complete stand still!  You saved my bacon!