Get-AlarmDefinition | New-AlarmAction -Email -To ‘jandrews@inflexionllc.com’ -CC @(‘test1@inflexionllc.com’, ‘test2@inflexionllc.com.com’) -Body ‘Test body’ -Subject ‘Test subject’
Drop that line into a PowerCLI windows and poof all alarms will be updated to send an email when they go off (change warning (yellow) to alarm (red)).
Sweet. Not to mention about time!
Don’t forget to add the SMTP server to your vCenter Server Settings and your vCenter server to your “allowed relay” list on your SMTP server.
2 Responses to vSphere5: My favorite feature