HCX job stuck java.lang.NullPointerException: null
search cancel

HCX job stuck java.lang.NullPointerException: null

book

Article ID: 408088

calendar_today

Updated On:

Products

VMware HCX

Issue/Introduction

After migrating from one site to another, and never completing the task, you will see the following error on the UI 

 

but if you tried to force cleanup or archive i will failed with the following error:

java.lang.NullPointerException: null

Environment

Vmware HCX 

Cause

vCenter vpxd service crashed due to a duplicate key value being inserted to table "vpx_nw_assignment". This happens when HCX migrates VM's to network port group which has any special characters.

Resolution

Information require:

  • Migration ID 
  • Migration Group

Task: Generating x-hm authentication token for use with HCX APIs

Note: Choose Migration APIS, The option for Migration has been deprecated

  • After you get the token we are going to use the api call :  POST
    ​/migrations​/forceCancel

Example: 

Sample data:

Migration ID: 1234567

Migration groups:7654321

api call 

{
  "items": [
    {
      "migrationId": "string",
      "migrationGroupId": "string"
    }
  ],
  "removeLongRecoveryData": false
}

complete api call 

{
  "items": [
    {
      "migrationId": "1234567",
      "migrationGroupId": "7654321"
    }
  ],
  "removeLongRecoveryData": false
}
  • Go into the UI, and this should show as cancel 

  • If yes, tried to archive
  • If not, open a case with VMware and collect the log's