Adding ESXi host to vCenter failed with error "Cannot complete the license assignment operation"
search cancel

Adding ESXi host to vCenter failed with error "Cannot complete the license assignment operation"

book

Article ID: 419134

calendar_today

Updated On:

Products

VMware vCenter Server

Issue/Introduction

Attempting to add\connect a host to the vCenter Server fails with the error after reaching to 90%:

Cannot complete the license assignment operation. Can not assign a license to "Host" <host_name>. Make sure the License Service is available.

Environment

VMware vCenter Server
VMware vSphere ESXi

Cause

This issue occurs when the vCenter has VMDir in read-only mode.

Resolution

Please perform the below steps to change the vmdir to NORMAL state:

Note: Ensure to take a backup of vCenter Server before proceeding.

  1. Log in to the vCenter Server with SSH access.
  2. Type shell and press Enter
  3. Execute command:
    /usr/lib/vmware-vmdir/bin/vdcadmintool
  4. Press 6 to check the status of vmdir if READ_ONLY. If yes, go to the next step. Otherwise, stop here and issue does not match this Knowledge Base article.
  5. Press 5 and enter NORMAL to set vmdir to NORMAL state
  6. Press 0 to exit the tool.
  7. Restart vmdird service.
    service-control --restart vmdird
  8. Add ESXi host to vCenter

Additional Information

Unable to add an upgraded host to vCenter/cluster with error "cannot complete the license assignment operation. license service on server is unavailable"