Cluster failover notification

  • I'm new to clustering servers. Is there a good way to setup email notification for when a cluster fails over?

  • If you ping "localhost", you'll get the name of the local server back, not the virtual server's name.  When I had a cluster to administer, I put a job that ran the output of a ping to a temp table, deleted all the lines I didn't want, and parsed the server name out of the row that was left.  If you output that to a physical table or file somewhere so it persists, you can run a comparison and fire an email when the localhost server name doesn't match from the last ping.  Unfortunately, it's reactive, and you need enough resources available on your cluster to run it every five or so, or it's completely useless.  If you want something more immediate, you could look into 3rd party tools (SQL Sentry, maybe), but this is an option if you don't have the budget.

  • that is a great suggestion. Thanks

    I also thought about setting a cluster resource as a generic script and send an email when the resource comes online, but I'm not sure if that is feasible or not. I'll reply with my solution after I get it implemented.

    Thanks again

  • Adam,

    with "SELECT SERVERPROPERTY('ComputerNamePhysicalNetbios') you can query on which clusternode SQL Server is running.

    You could then create a job which is scheduled to run when SQL Agent starts. During failover SQL agent will restart on the failover node and should send a mail telling which is the current active node.

    Markus

    [font="Verdana"]Markus Bohse[/font]

  • that is exactly what I'm looking for. I was wondering if you could get the physical name from SQL. Great solution. Thanks!

Viewing 5 posts - 1 through 4 (of 4 total)

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