Is there a way to find this alert via PowerCLI? I am getting this alert often and need to set up an e-mail alert when this happens but I don't see it in Get-VIEvent but it is in the console under Alarms.
To get the host name you can do it like this:
Get-VIEvent -Start (Get-Date).AddDays(-7) -MaxSamples 99999 | ` Where-Object {$_.GetType().Name -eq "EventEx" -and $_.EventTypeID -eq "vprob.net.redundancy.lost"} | ` Select-Object -Property EventTypeId,Severity,CreatedTime,@{N="VMHost";E={$_.Host.Name}}
Regards, Robert
To add an action have a look at my post called Alarms – Adding an action
This alarm is triggered by an EventEx event.
These are triggered by an extension.
To find these you can do
Get-VIEvent -Start (Get-Date).AddDays(-7) -MaxSamples 99999 | `
where {$_.GetType().Name -eq "EventEx" -and $_.EventTypeID -eq "vprob.net.redundancy.lost"}
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Is there a way to show which ESX host this happened on?
EventTypeId : vprob.net.redundancy.lost
Severity : warning
Message :
Arguments : {1, 2, 3}
ObjectId : ha-eventmgr
ObjectType : HostSystem
ObjectName :
Fault :
Key : 2072101
ChainId : 2072101
CreatedTime : 2/16/2011 7:54:27 AM
UserName :
Datacenter : VMware.Vim.DatacenterEventArgument
ComputeResource : VMware.Vim.ComputeResourceEventArgument
Host : VMware.Vim.HostEventArgument
Vm :
Ds :
Net :
Dvs :
FullFormattedMessage : Lost uplink redundancy on virtual switch "vSwitch0". Physical NIC xsigo_xnic1 is down. Affected
portgroups:"VMotion", "Service Console", "Service Console 2".
ChangeTag :
DynamicType :
DynamicProperty :
To get the host name you can do it like this:
Get-VIEvent -Start (Get-Date).AddDays(-7) -MaxSamples 99999 | ` Where-Object {$_.GetType().Name -eq "EventEx" -and $_.EventTypeID -eq "vprob.net.redundancy.lost"} | ` Select-Object -Property EventTypeId,Severity,CreatedTime,@{N="VMHost";E={$_.Host.Name}}
Regards, Robert
Thanks Robert, that was exactly what I need.
It seems "vprob.net.redundancy.lost" changed to "esx.problem.net.redundancy.lost" on newer esxi / vcenter