Hi,
I'm checking some security settings in my Cluster of 3 ESXis hosts running 6.5.
I run this first script :
Foreach ($VMHost in Get-VMHost ) {
$ESXCli = Get-EsxCli -VMHost $VMHost;
$ESXCli.software.vib.list() | Where {
($_.AcceptanceLevel -ne "PartnerSupported") -and
($_.AcceptanceLevel -ne "VMwareAccepted") -and
($_.AcceptanceLevel -ne "VMwareCertified") }
$ESXCli.software.acceptance.get()
}
The result returns is :
PartnerSupported
PartnerSupported
PartnerSupported
As there are 3 hosts, I assume that each line is related to one host. The problem is that all VIBs have an acceptance level of PartnerSupported or VMwareAccepted.
I should get no result but I get one line per host with PartnerSupported. Why ?
If I add the VMhost in the script like this :
Foreach ($VMHost in Get-VMHost ) {
$ESXCli = Get-EsxCli -VMHost $VMHost;
$ESXCli.software.vib.list() | Where {
($_.AcceptanceLevel -ne "PartnerSupported") -and
($_.AcceptanceLevel -ne "VMwareAccepted") -and
($_.AcceptanceLevel -ne "VMwareCertified") }
$ESXCli.VMhost, $ESXCli.software.acceptance.get()
}
The result returned shows one line with the VMhost Name that is truncated, and other information, and one line with PartnerSupported:
Name ConnectionState PowerState NumCpu CpuUsageMhz CpuTotalMhz MemoryUsageGB MemoryTotalGB Version
---- --------------- ---------- ------ ----------- ----------- ------------- ------------- -------
PartnerSupported
in52inmvt1esx01.v... Connected PoweredOn 32 696 67168 33.722 63.908 6.5.0
PartnerSupported
in52inmvt1esx02.v... Connected PoweredOn 32 459 67168 18.628 63.908 6.5.0
PartnerSupported
in52inmvt2esx01.v... Connected PoweredOn 32 761 67168 23.662 63.908 6.5.0
How to get the VMhost Name not truncated ?
Using $ESXCli.VMhost.Name instead, returns the full hostname:
in52inmvt1esx01.vdrmvt.local
PartnerSupported
in52inmvt1esx02.vdrmvt.local
PartnerSupported
in52inmvt2esx01.vdrmvt.local
PartnerSupported
Thanks in advance for helping me to understand the result and improve the output result.
Regards
Patrick