Im looking for a way to send a alert email via a script that detects something like a dirty or abrupt shutdown of a windows server based on the event log. lets say you have a exchange 2007 ccr cluster and for what ever reason the Active node crashes and since the fail overs happen so quickly most of the monitoring software such as like WUG or nimsoft dont pick it up because it is outside of the polling cycle. I am looking for a simple script that will route a simple smtp message that says "server mail01a of vitualmail01 has crashed/rebooted due to *_*" the blank would be filled in by a event from the system or app log. so what i am looking for a is a script that will:
send a message via a predetermined smtp server
Have a subjet that says what its for
then have a body that is pulled from a event n the server that crashed logs such as system or app.
Im not looking for someone to do this for me, just looking to be pointed in the right direction, any help would be greatly appriciated.