VMware HCX

  • 1.  How to schedule a Mobility group to start replication using PowerCLI

    Posted May 13, 2025 07:54 AM
    Edited by gertvangorp May 15, 2025 10:00 AM

    Hi, 

    I am trying to write a Powershell script that makes mobility groups for x VMs to be bulk migrated using HCX.

    I was using this blog as example.

    https://vmusketeers.com/2021/11/15/automating-hcx-cutover-using-powercli-hcx-powercli-vexpert/

    Now I am able to create the MobilityGroups with the VM's in there.

    I can stqrt to mobility group to start replication and I can put a schedule for the switchover.

    I want to be able just to put in a schedule to start the replication, which is possible using the UI.

    Manual starting using the command Start-HCXMigration works but I want to set a schedule....

    thanks

    Gert



  • 2.  RE: How to schedule a Mobility group to start replication using PowerCLI

    Broadcom Employee
    Posted 25 days ago

    This is currently not supported using PowerCLI. You may want to explore API as an alternate method. You can use a HAR dump to work out which API calls the UI is making, then create a PowerShell function.




  • 3.  RE: How to schedule a Mobility group to start replication using PowerCLI

    Posted 25 days ago

    How Do you make such a HAR dump?

    this will maybe filx my network mapping issue as well

    I I look at the VM config in HCX I see this

    while going deepir in the job config I see this.

    The migration works if I start this using powerCLI not using the UI.  Buyt at the end no networks are connected

    already thansk for your help

    gert