Script to get an email/Alert when a databse is down or is in suspect mode or the sql service and agent is stopped.

  • Hello,

    We are using sql server 2005 and recently our server got shut down unexpectedly and restarted.But I did not notice till the next day while viewing event viewer.

    So is there any script to get an email/Alert when the databases are down or sql service/sql agent has stoped?

    How you guys know when the databases are down?

  • Nowadays we use Operations Manager to monitor the servers and it will send out all kinds of email & IM's when a server goes offline. We also have Idera's Diagnostic Manager that can do the same thing.

    Prior to spending all that money however, I used to set up a server with email and then had all the other servers do event forwarding to that server. When errors occurred, they were forwarded to the central machine, which had Operators and Alerts set up to respond to the events as they came in. It's a part of the SQL Server Agent.

    It's not as sophisticated or as powerful as the third party tools available, but it can do most of what you need.

    "The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
    - Theodore Roosevelt

    Author of:
    SQL Server Execution Plans
    SQL Server Query Performance Tuning

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply