I used host profiles to configure networking and other configuration on ESXi 6.5 hosts for a while. Worked fine.
When a trainee used the host profile, an error showed up after the host profile ‘remediate’ feature was selected.
The error shown in vCenter was ‘Cannot apply the host configuration’
At the same time, when the host was selected, the summary tab provided some insight on the error. An NFS export could not be mounted as the NFS server could not be reached.
It turned out that the host customization fields were filled in incorrectly. The host customization has mandatory fields for the VMkernel IP-address and subnet for management, vMotion and NFS.
The host profile was configured to mounts NFS exports automatically. As the NFS storage could not be reached, the host profile remediate failed.
Once the correct IP-address was set for the VMkernel used for NFS traffic, the host profile was applied succesfully.