Use the following HCX API command to forceCancel the migration:curl -k --location -X POST 'https://<SOURCE_HCX_MGR_IP>/hybridity/api/mobility/migrations/forceCancel' \--header 'accept: application/json' \--header 'accept-language: en-GB,en-US;q=0.9,en;q=0.8' \--header 'content-type: application/json' \--header 'x-hm-authorization: <X-HM_TOKEN>' \--data '{ "items": [ { "migrationId": "<migration-ID>" } ], "removeLongRecoveryData": false}'This curl should be run on both the connector and cloud managers.
The following information is required:
<SOURCE_HCX_MGR_IP>: Specify the IP address or FQDN of the HCX Connector. The API client must be able to reach this VM on the network.<X-HM_TOKEN>: Refer to this KB article Generating x-hm authentication token for use with HCX APIs for instructions on obtaining the X-HM token. F12" key to open the Developer Tools.Network" tab and select the "Fetch/XHR" filter.Site Pairs" or "Interconnect" to generate an API response.Headers" tab and find the x-hm-authorization field.<migration-ID>: This is the migration ID you want to cancel. Migration", selecting the virtual machine, and copying the migration ID.curl -k -X POST "https://<SOURCE_HCX_MGR_IP>/hybridity/api/migrations?action=query" \--header "accept: application/json" \--header "x-hm-authorization: <X-HM_TOKEN>" \--header "Content-Type: application/json" \--data "{filter={skipDrafts=true,createTimeEpoch=1583692200000},options={resultLevel=\"MOBILITYGROUP_ITEMS\",compat=2.1}}"jq commands to format the data to find the virtual machine's "entityName" and its corresponding migrationId.