Hello,
I need to query all ESXi hosts against "lost access to volume" for datastore issues over a certain period of time please. How?
You can do something liek this
Get-VIEvent -Start $start -MaxSamples ([int]::MaxValue) |
where {$_.FullFormattedMessage -match "lost access"} |
Select CreatedTime,@{N='VMHost';E={$_.Host.Name}},FullFormattedMessage,@{N="Type";E={$_.GetType().Name}}
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Hi,
This post by LucD vSphere events with PowerCLI solves a case similar to yours, check if you solve with this, otherwise we wait for him to see the post and respond. He certainly knows how to help you.
ARomeo
This is great, thank you. However, I need the report to include the ESXi hostname if you know how to .
You can do something liek this
Get-VIEvent -Start $start -MaxSamples ([int]::MaxValue) |
where {$_.FullFormattedMessage -match "lost access"} |
Select CreatedTime,@{N='VMHost';E={$_.Host.Name}},FullFormattedMessage,@{N="Type";E={$_.GetType().Name}}
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Thanks,