Error : "Licenses could not be assigned to the vCenter System. Please try again or check the error logs. If the issue persists contact support" seen during license assignment on VCF 9.1
search cancel

Error : "Licenses could not be assigned to the vCenter System. Please try again or check the error logs. If the issue persists contact support" seen during license assignment on VCF 9.1

book

Article ID: 443446

calendar_today

Updated On:

Products

VCF Operations

Issue/Introduction

 

  • License assignment to a selected vCenter in VCF Operations 9.1 fails with an error message "failed assignments" and "Licenses could not be assigned to the selected vCenter".
  • Selecting the View Details tab for the error message shows the message below: "Licenses could not be assigned to the vCenter System. Please try again or check the error logs. If the issue persists contact support" 
  • The symptoms from KB 424533 have been validated and ruled out.
  • Reviewing the /storage/log/vcops/log/adapters/ManagementAdapter/ManagementAdapter_*.log file reveals exceptions similar to the following:
    ERROR ManagementAdapter #### [ops@#### threadId="######" threadName="vcf-licensing-assign-##" instanceId="####"] [(####) com.vmware.adapter.management.components.licensing.vcf.EntitlementMutationManager.lambda$assignEntitlements$1] - Assignment failed for VC <License_Assignment_VC_UUID> at <License_Assignment_VC_FQDN_from_Ops>
    java.util.concurrent.CompletionException: java.lang.NullPointerException
    ERROR ManagementAdapter #### [ops@##### threadId="######" threadName="vcf-licensing-collection-#####" instanceId="####"] [(####) com.vmware.adapter.management.components.licensing.vcf.collector.VCenterLicenseUsageCollector.collect] - Connection failed for VC null at <Non_License_Assignment_VC_FQDN>
    com.vmware.adapter.management.components.licensing.vcf.exceptions.VcConnectionException: Connection failed for VC null at <Non_License_Assignment_VC_FQDN>
    Caused by: com.vmware.vim.vmomi.client.exception.ConnectionException: https://<Non_License_Assignment_VC_FQDN>/sdk invocation failed with "java.net.UnknownHostException: <Non_License_Assignment_VC_FQDN>: Name or service not known"

Environment

VMware Cloud Foundation Operations 9.1
VMware vCenter Server 9.1

Cause

All VCs added in the Integrations tab are processed by the Management Adapter regardless of whether they are in the Collection or Stopped state. This is because management capabilities are separate from monitoring, which is reflected in the Status column on the Integration page. Each VC is processed to determine its license state, which is necessary to identify the appropriate license for VCF Ops itself, as it is licensed based on VC licenses

Resolution

To resolve this issue, correct the underlying connection or collection issue for the disconnected vCenter:

  1. Review the /storage/log/vcops/log/adapters/ManagementAdapter/ManagementAdapter_*.log  to identify the specific secondary vCenter throwing the UnknownHostException or collection failure.

    Example: Caused by: com.vmware.vim.vmomi.client.exception.ConnectionException: https://<Non_License_Assignment_VC_FQDN>/sdk invocation failed with "java.net.UnknownHostException: <Non_License_Assignment_VC_FQDN>: Name or service not known"

  2. Resolve the network connectivity, DNS, or collection issue for that specific vCenter.

  3. Allow 5 to 10 minutes for a complete data collection cycle to run and succeed.

  4. Retry the license assignment by following documentation for assigning a primary license to a vCenter instance.