A quick post on how to import a host profile into vCenter Server using vSphere PowerCLI. Here is the link to the cmdlet reference page.
- Open PowerCLI and connect to you vCenter Server: PowerCLI C:> Connect-VIServer <IP_or_FQDN>
- Next, use the following to import the profile: PowerCLI C:> Import-VMHostProfile –FilePath <Path> -Name <Profile_Name> -ReferenceHost <ESXi_host_Name>
For example: PowerCLI C:> Import-VMHostProfile -FilePath D:HostProfilesDefault.vpf -Name Default -ReferenceHost host-01.dr-lab-e.local Done. As you can see the host profile is now displayed under Host Profiles in the vCenter Server. All you have to do now, is to link it to the cluster and apply it to the hosts. Note: make sure that the reference host is online and is accessible or you will receive an error message in the PowerCLI window stating that the host is invalid or incompatible. This of course can also be done in the vCenter Server through the Host Profile import wizard. 🙂