alanrenouf / vCheck-vSphere

vCheck Daily Report for vSphere
MIT License
735 stars 326 forks source link

vCheck for vCenter Sucks at Plugin 02 and 17 after upgrading the PowerCLI to 11.4 #690

Open ghost opened 5 years ago

ghost commented 5 years ago

After upgrading the PowerCLi modules to 11.4, vCheck stopped to run. Whn check found that it was stuck at Plugin 02. Disabled Plugin 02 and the next it stopped to plugin 17. If I disabled Plugin 02 and 17 The script runs fine.

TheTram commented 5 years ago

PowerCLi 11.2 build 12483598 Plugin 02 Runnnig multiple vcheck -job (seperate xml with Plugin 999 at end). Each job has a different Plugin 00 yet every HTML report has the Plugin 02 information from the first job.

vulcanjedi commented 4 years ago

Concur on this on PowerCLI 11.5

lucdekens commented 4 years ago

Are you sure it happens with PowerCLI 11.5 as well?

This is most probably caused by a known issue with API 6.x where events HostSpecificationRequireEvent and HostSpecificationUpdateEvent were added. Apparently the layout of neither of these events was defined.

This was an issue in PowerCLI (see https://communities.vmware.com/message/2762124#2762124) , the .Net SDK (see https://github.com/vmware/vsphere-automation-sdk-.net/issues/19), the Phyton framework (see https://github.com/vmware/pyvmomi/issues/746) and other frameworks.

Afaik, in PowerCLI 11.5 (and possibly 11.4) the issue is gone.

As a test, do a Get-ViEvent against your vCenter.

Get-VIEvent -Start (Get-Date).AddDays(-1) -MaxSamples ([int]::MaxValue)

If that also comes back with the "Error in deserializing body of reply message for operation 'RetrieveProperties'" message, you might need to open a SR.

vulcanjedi commented 4 years ago

Was running on older test instance and things seem fine. Tried newer instance ran into issues.
Got the deserializing messages.
My colleague updated to 11.5. No longer get those errors but as OP states, hangs on plugin 2/17 on step1. I blocked plugin 2/17 and still waiting finish but seems to be good on 94/116... Your test command does not yield errors and ran fine. I had to kill it it just kept going....

VMware PowerCLI 11.5.0 build 14912921

VMware Common PowerCLI Component 11.5 build 14898112 VMware Cis Core PowerCLI Component PowerCLI Component 11.5 build 14898113 VMware VimAutomation VICore Commands PowerCLI Component PowerCLI Component 11.5 build 14899560

lucdekens commented 4 years ago

And that "I had to kill it it just going...." is a side effect I noticed after the fix. The Get-ViEvent cmdlet and also the underlying API runs a whole lot slower than before.

While I'm prepping vCheck v7, I'm looking at ways to improve the speed. That should make plugins 02 and 17 more responsive.

vulcanjedi commented 4 years ago

Not sure 79 is related but also have response issues there...

lucdekens commented 4 years ago

That one doesn't use events, but the DatastoreBrowser which is unfortunately also known for its slow response time.