Hany Michael wrote a nice article on importing and exporting your VMs from and to vCloud Director. Although the importing made a lot of sense the exporting from vCD and importing into vSphere in my opinion is a bit shady. It is not something I would recommend to anyone as I am unsure it is supported and I believe that vCD should be used as your management platform and not vCenter. Besides that in many environments tenants will not have direct access to vCenter to begin with. There is a simple method to export your VMs from vCloud Director in OVF Format:
- Power off your vApp and add it to the Catalog
- Select the correct catalog
- Open the Catalog you copied the vApp to
- Click “Download”
Now you can import it again in vSphere. You could keep the original vApp running in vCD if you want (when it is fenced of course as otherwise you will end up with an IP conflict) or you can completely delete it, that is up to you!
Hany Michael says
Hi Duncan,
Got a ping back (and a lot for traffic might I add 😉 ). I’m not sure either if the second option of migrating the VMs from vCD to vSphere would be supported (referring to the one editing the customer fields), however, I don’t see anything wrong with the first option. It’s just a matter of two clicks. Unregister and then add to inventory. The procedures you described above look solid, but if you think of it from a management perspective, it would take much longer time and effort for such a simple task.
My 2 cents.
Duncan Epping says
Like I stated Hany, in a normal environment someone who manages the Org doesn’t necessarily has access to vSphere… preferably not I guess even.
Besides that vCD keeps track of VMs etc, removing objects from outside of vCD cannot be the approach you should take in my opinion as it might leave vCD in an inconsistent state.
Janakan says
The “Import from vSphere” doesn’t show up for Org Admin. I believe it’s part of the design. May have wait till the cloud plug-in for VI I guess!
-Janakan
Hany Michael says
Duncan,
1 – In your case, you will still need vSphere access anyways in order to import the VM 🙂 – the vSphere admin and the Cloud admin are not living in two separate islands. One has to coordinate with the other at the end of the day.
2 – vCD keeps track of its VM via this custom field, it will always know if it has the owner ship of VM or not. It’s not like vCD and vCenter will be competing with each other over it. After you take this ownership of the VM and clone it to your vS4 environment (after fixing the networks, using a nicer name ..etc) you can simply remove the vApp from your cloud and you are done – it will be gone as if it was never there. I might need to clarify this point in my post to avoid the confusion.
I will add a link back to your article as another method for this migration. Great discussion by the way!
Duncan Epping says
@Janakan: That is correct, As an Org Admin you can’t do that. You will always need to be Cloud Admin.
@Hany: You are making a whole bunch of assumptions here. Who says you are importing it to the same vSphere environment the vCloud is part of? That is most definitely NOT a best practice. vCenter servers should be dedicated to vCD.
Hany Michael says
This could be a different discussion, but in my case I’m always referring to private clouds. In most of the organization (especially new ones starting their cloud journey) I would expect that they will have a none-vCD RPs at least at the beginning, while in public clouds I would agree that a vCenter must be dedicated to vCD for the different tenants/customers operating on it.
Duncan Epping says
Even then, in any organization which is large enough to buy / use vCD I would expect a separation of roles and responsibilities. What you have shown would work in SMB but in many of the Enterprise organizations I have worked for would be pure blasphemy.
Wade Holmes says
Interesting discussion guys. I think the moral of the story is design and operational decisions should be based not on assumptions, but on customer requirements…
Abhinav Joshi says
Disclosure – NetApp Employee
Great article Duncan.
One important use case of “importing VMs from vSphere” that I can think of is when the cloud admin gets the requirements from a new/existing tenants to pre-provision their environment with e.g. 100 VMs. This could be to meet the bursts in business demands or even as a base environment as new tenants sign up. I believe currently you can manually import pre-created VMs (using VMware Full Clones) in vCD (one VM at a time).
The entire process can be fully orchestrated and made very efficient by using VMware vCenter Orchestrator (free VMware product I guess) to leverage storage hardware assisted, space efficient, VM cloning to mass provision VMs in vCenter, and then bulk import them into new/existing tenant Org vDCs in vCD.
We have an online demo, if anyone is interested.
Jean Paul Lopez says
Hi,
It’s NOT working. Using Firefox 3.X. Tried Win7, Mac OSX, nothing. I click download, and NOTHING happens. Have Java installed, etc. What do I need to do to be able to download my Image (And migrate to a platform that really works, VM IS CRAP!)
Jeff Q says
what about the use case for restoring a VM from backup? We use NetBackup to do this and unfortunately we have to remove the VM from vCD, restore it to vCenter, clone it(or remove/re-add to inventory to clear out custom field), modify the network and then we can re-import it to vCloud.
it’s all a bit painful compared to our straight vSphere environment.
Joris Both says
Duncan, I am currently trying to import my existing virtual machines into different organizations, but I am struggling to keep the configuration of the VM the same..
As soon as I import a machine, I need to re-assign the IP address in the VM configuration. No problem there, I just select static and fill in the original IP address. The only problem is, is that Vcloud Director wants me to enable guest customization to make it work.
Guest customization does a lot more then just set the IP adress… It also changed my hostname, so my Windows 2008 machine didn’t belong to the domain any more..
What is the best way to import the virtual machines into Vcloud director without breaking them? If I would try this with a domain controller, I would destroy the whole AD…