Set the License Key for a Host on vCenter Server

You can set the license key for a host on a vCenter Server system by using the LicenseKey parameter of the Set-VMHost cmdlet.

Prerequisites

Verify that you are connected to a vCenter Server system.

Procedure

  1. Save the Host host object as a variable.
    $vmhost = Get-VMHost -Name Host
  2. Set the host to evaluation mode or provide a valid license key.
    • Set the host to evaluation mode by providing the evaluation key.
      Set-VMHost -VMHost $vmhost -LicenseKey 00000-00000-00000-00000-00000
    • Provide a valid license key.
      Set-VMHost -VMHost $vmhost -LicenseKey Your_license_key