WilliamLam.com

  • About
    • About
    • Privacy
  • VMware Cloud Foundation
  • VKS
  • Homelab
    • Resources
    • Nested Virtualization
  • VMware Nostalgia
  • Apple
You are here: Home / Performing A Storage vMotion in vCloud Director Using vCO

Performing A Storage vMotion in vCloud Director Using vCO

02.20.2012 by William Lam // 10 Comments

I wrote an article yesterday called Performing A Storage vMotion in vCloud Director Using vCloud REST API and at the beginning I mentioned a few alternative solution to using the vCloud REST API such as the vCloud SDKs: Java, .NET, PHP or the new vCloud Director cmdlets. Afterwards, I realized I left out one very important solution, which is using vCenter Orchestrator (vCO) with the vCloud Director plugin.

I was able to quickly put together a vCO workflow using the Query Service in the vCD plugin and with the help of this VMTN thread from Christophe Decanni. I have exported my workflow so you can easily import it into your vCO Server without any hassle.

Disclaimer: Please thoroughly test this in a non-critical environment before using it on production systems.

Download: StoragevMotionForvCloud.workflow

To start using the workflow, you will need to ensure you have the vCloud Director 1.5 vCO plugin installed and import the workflow after you have downloaded it to your local system:

Here is a quick view of what the Storage vMotion for vCloud Director workflow looks like:

Here is an example execution of the workflow where we will Storage vMotion (using vCloud "relocate" API operation) to move "vESXi-01" VM from "iSCSI-3" to "iSCSI-4" datastore.

Step 1 - Select vCloud vDC and vCloud VM that you wish to performed the Storage vMotion. As part of the initial query, user will be provided with the current datastore the vCloud VM is residing on:

Step 2 - Once the query has completed to identify the current datastore the vCloud VM is residing on, a user interaction request will be needed to select the destination datastore to perform the migration to. You will notice the workflow icon will change to a yellow color and requiring an "answer" from the user. Right click on the workflow and click on "Answer" to continue the workflow:

Step 3 - You will see a "result" field which is the query of the vCloud VM that was selected and the datastore it's currently residing on. You will now have the option to select the vCloud datastore you wish to Storage vMotion the vCloud VM to:

Step 4 - Now you are ready to kick off the Storage vMotion operation. This may take sometime to finish depending on the size of the VM and the speed of your underlying storage. You should see a message under "Log" specifying the operation has been started. If everything is successful, you should see the vCloud VM now running on the new datastore.

Now you can enjoy performing Storage vMotions in vCoud Director with just a click of a button with the help of vCenter Orchestrator! Happy workflowing 🙂

More from my site

  • Org vDC to vCenter Resource Pool Workflow Using vCenter Orchestrator
  • Leveraging vCD + vCO + Wavemaker Part 2
  • Leveraging vCD + vCO + Wavemaker Part 1
  • Congratulations to Chris Greer for Winning Automating vSphere with vCenter Orchestrator
  • Win a Free Automating vSphere with vCenter Orchestrator Book

Categories // Uncategorized Tags // orchestrator, svmotion, vcd, vCO

Comments

  1. *protectedPeter says

    04/02/2012 at 7:28 pm

    Nice work. Have you been able to get the VclVAppTemplate.relocate() version to work yet? VM's work but templates throw an Access is Forbidden error for me so far...

    Reply
    • *protectedOliver says

      01/10/2013 at 3:31 pm

      To move a template to a different datastore I just rightklicked the template and said "move to a different catalog", there I selected the same as before. It seems to work so far, but I did not have any linked clones of that maschine, don't know if this could have any side effect.

      Reply
  2. *protectedAnonymous says

    12/10/2012 at 2:27 pm

    Sounds good, but download doesn't work: Cannot resolve hostname!?!?

    Reply
    • *protectedWilliam says

      12/10/2012 at 3:54 pm

      Sorry about that, link fixed.

      Reply
    • *protectedAnonymous says

      12/10/2012 at 5:00 pm

      Thanks a lot. Download works fine, but to import the workflow a different format is needed. I assume it should be one file instead of 3 files. Regards Christian

      Reply
    • *protectedWilliam says

      12/10/2012 at 5:07 pm

      No, you just import the workflow into vCO.

      Reply
  3. *protectedAnonymous says

    12/10/2012 at 5:19 pm

    Your ZIP consist of 3 files. When I try to import either of the files to vCo does not work: "Unable to import file * Not a valid workflow file".

    Reply
    • *protectedWilliam says

      12/10/2012 at 5:25 pm

      The extension as noted in the link should be .workflow, please don't try to save it as anything else. Within the .workflow, there will be several files but that's more of the internals of it which you don't need to touch. When you export a workflow, it'll have a .workflow extension & you can just import it right in.

      Reply
  4. *protectedJohan says

    07/17/2013 at 8:59 am

    Nice work dude! Is there a new version for the vCloud Director 5.1 Plug-In? I can't get this working in my environment...

    Reply
    • *protectedAnonymous says

      08/28/2013 at 6:48 pm

      Bump!

      Reply

Leave a Reply to JohanCancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Search

Thank Author

Author

William is Distinguished Platform Engineering Architect in the VMware Cloud Foundation (VCF) Division at Broadcom. His primary focus is helping customers and partners build, run and operate a modern Private Cloud using the VMware Cloud Foundation (VCF) platform.

Connect

  • Bluesky
  • Email
  • GitHub
  • LinkedIn
  • Mastodon
  • Reddit
  • RSS
  • Twitter
  • Vimeo

Recent

  • Programmatically accessing the Broadcom Compatibility Guide (BCG) 05/06/2025
  • Quick Tip - Validating Broadcom Download Token  05/01/2025
  • Supported chipsets for the USB Network Native Driver for ESXi Fling 04/23/2025
  • vCenter Identity Federation with Authelia 04/16/2025
  • vCenter Server Identity Federation with Kanidm 04/10/2025

Advertisment

Privacy & Cookies: This site uses cookies. By continuing to use this website, you agree to their use.
To find out more, including how to control cookies, see here: Cookie Policy

Copyright WilliamLam.com © 2025