Vcenter License Key Command Line Best

If hosts are managed by vCenter, use Set-VMHost :

While standalone ESXi hosts use the vim-cmd vimsvc/license --set=KEY command via SSH, this command is not used to license a vCenter Server. vcenter license key command line

For advanced automation, such as adding licenses with custom labels, experts often use scripts that interact with the vSphere Managed Object Browser (MOB) via PowerShell. If hosts are managed by vCenter, use Set-VMHost

To see what license keys are already known to vCenter: If hosts are managed by vCenter