Thursday, June 7, 2012

Database Mirror Monitoring and Automation with SQL Sentry

The Challenge

Since its introduction in SQL 2005 SP1, mirroring has become a common method to provide high availability for critical databases. With any HA strategy, proper monitoring is a must to ensure everything is working as planned with minimal data loss and disruption incurred in the event of a failover.

SQL Server provides several pertinent performance counters, as well as the Database Mirroring Monitor, to provide a base level of visibility into mirroring. Unfortunately there are known issues with alerting on mirroring thresholds as listed in Microsoft Connect here.

The issue is marked as ”Closed as Won’t Fix”, which leaves us with the need for a workaround.

The discovery of this led me to write this post. Not only will I provide scripts to configure a workaround, but I’ll show you how you can gain additional visibility and automation by combining this solution with SQL Sentry’s comprehensive monitoring and alerting capabilities.

While still available, mirroring will likely be used less in SQL Server 2012. The new Always On technology provides many enhancements over other HA options, and I’ll likely write a post about that in the future. See Aaron Bertrand’s (b|t) blog post on TechNet for an overview.

That said, I don’t suspect everyone will immediately upgrade to this new technology, so mirroring will be around for a while.

I first began my search through connect after reading the TechNet article on Alerting on Database Mirroring Events.

After some testing I quickly realized the solution wasn’t working as the alerts were database specific. Changing the "Database name:" field in the alert definition to <All Databases> in the alert properties fixed the issue. This may be sufficient if you only have one database mirrored on this server, but not if you have more than one since the alerts, and really the underlying error messages themselves, don’t provide for a database name.

I considered several options for a workaround. Ultimately, I wanted to make use of what native resources were reliable and practical as I didn’t want to reinvent the wheel. I know many people use a lot of the native functionality as covered in the MSDN article, Monitoring Mirroring Status, which discusses the dbmmonitor system stored procedures.

The Solution

So, my solution was to generate new error messages to replace the four native mirror performance errors. They are listed in the Technet article with Error numbers, 32040, 32042, 32043, and 32044. The below script creates new ones where I’ve replaced the leading 3 with a 5. The error messages are essentially the same as the original, except I’ve added a parameter for a database name. If you’ve already created your own custom error messages with those numbers, you’ll want to modify the script accordingly.

-- Create custom mirroring error messages to replace native ones so they can be database specific.
-- Error numbers are same as native, except leading 3 is replaced with a 5.
-- Severity level is 10, but error numbers and severity levels can be modified to suit your environment. 
-- Created by: Steven Wright, SQL Sentry
 
USE master
-- Check to see if there is already an error with this ID in sysmessages
IF EXISTS (SELECT 1 FROM sys.sysmessages WHERE error IN (52040, 52042, 52043, 52044))
    -- If there is, abort the script 
BEGIN 
    RAISERROR (N'At least one message with this error ID is in use.', 16, 1) 
END
ELSE
BEGIN
    EXEC sp_addmessage    @msgnum= 52040,
                        @severity= 10,
                        @msgtext= N'The oldest unsent transaction for %s is now %d.  The alert threshold is %d.',
                        @with_log= 'TRUE'
    EXEC sp_addmessage    @msgnum= 52042,
                        @severity= 10,
                        @msgtext= N'The Log Send Queue for %s is now %d KB.  The alert threshold is %d KB.',
                        @with_log= 'TRUE';
    EXEC sp_addmessage    @msgnum= 52043,
                        @severity= 10,
                        @msgtext= N'The Redo Queue for %s is now %d KB.  The alert threshold is %d KB.',
                        @with_log= 'TRUE';
    EXEC sp_addmessage    @msgnum= 52044,
                        @severity= 10,
                        @msgtext= N'The mirror commit overhead for %s is now %d ms.  The alert threshold is %d ms.',
                        @with_log= 'TRUE';
END

Download the script directly here: Create_Mirror_Error_Msgs.sql

Now that we’ve created these enhanced error messages, we need to ensure that they are the ones raised when your mirroring performance thresholds are exceeded. I’m referring to the standard warning thresholds you can set natively in SQL Server as described in MSDN.

Normally these errors are raised after a check by sp_dbmmonitorupdate. If you’ve used sp_dbmmonitoraddmonitoring to set things up, you should have a job on your server called ‘Database Mirroring Monitor Job’ that runs the update proc at scheduled intervals.

Below is a script to create a replacement proc called sp_Sentry_dbmmonitorupdate that is otherwise identical, but raises our newly created errors and passes a database name to give us more complete details. Simply replace the call to the native proc in the job’s step with a call to this new one in msdb. If you call it with a null parameter for database_name, it will cycle through each mirrored database, passing the appropriate name when raising the error.

USE [msdb]
GO
 
/****** This is a modified version of sys.dbmmonitorupdate which raises customized errors for mirroring to include the dbname. 
Written by Steven Wright, SQL Sentry ******/
 
SET ANSI_NULLS ON
GO
 
SET QUOTED_IDENTIFIER ON
GO
 
 
CREATE procedure [dbo].[sp_Sentry_dbmmonitorupdate] 
(
    @database_name        sysname = null    -- if null update all mirrored databases
)
as
begin
    set nocount on
    if (is_srvrolemember(N'sysadmin') <> 1 )
    begin
        raiserror(21089, 16, 1)
        return 1
    end
    if ( db_name() != N'msdb' )
    begin
        raiserror(32045, 16, 1, N'msdb..sp_Sentry_dbmmonitorupdate')
        return 1
    end
 
    declare        @retcode    int
 
    if object_id ( N'msdb.dbo.dbm_monitor_data', N'U' ) is null
    begin 
        create table msdb.dbo.dbm_monitor_data (        -- go through the code to see if there SHOULD be nulls.
            database_id                smallint,
            role                    bit null,
            status                    tinyint null,
            witness_status            tinyint null,
            log_flush_rate            bigint null,
            send_queue_size            bigint null,
            send_rate                bigint null,
            redo_queue_size            bigint null,
            redo_rate                bigint null,
            transaction_delay        bigint null,
            transactions_per_sec    bigint null,
            time                    datetime,
            end_of_log_lsn            numeric(25,0),
            failover_lsn            numeric(25,0),
            local_time                datetime
        )
 
        exec @retcode = msdb.dbo.sp_MS_marksystemobject dbm_monitor_data
        if ( @@error != 0 OR @retcode != 0 )
        begin
            raiserror( 32038, 16, 1 )
            return 1
        end
 
        create clustered index dbmmonitor1 
            on msdb.dbo.dbm_monitor_data (database_id asc, time asc )
    end
 
    -- TO DO: create some keys depending on enterences.
    -- TO DO: make sure that the rows are unique
    if object_id ( N'msdb.dbo.dbm_monitor_alerts', N'U' ) is null
    begin
        create table msdb.dbo.dbm_monitor_alerts (
            database_id                smallint,
            retention_period        int null,    --this defaults to 7 days.  checked during the table update
            time_behind                int null,
            enable_time_behind        bit null,
            send_queue                int null,
            enable_send_queue        bit null,
            redo_queue                int null,
            enable_redo_queue        bit null,
            average_delay            int null,
            enable_average_delay    bit null
        )
 
        exec @retcode = msdb.dbo.sp_MS_marksystemobject dbm_monitor_alerts
        if ( @@error != 0 OR @retcode != 0 )
        begin
            raiserror( 32038, 16, 2 )
            return 1
        end
    end
 
    if ( select name from sys.database_principals where name = N'dbm_monitor') is null 
    begin
        create role dbm_monitor
        grant select on object::msdb.dbo.dbm_monitor_data to dbm_monitor
    end
 
    if @database_name is not null
    begin
        --
        -- Check if the database specified exists 
        --
        if not exists (select * from master.sys.databases where name = @database_name)
        begin
            raiserror(15010, 16, 1, @database_name)
            return 1
        end
        -- 
        -- Check to see if it is mirrored
        --
        if (select mirroring_guid from master.sys.database_mirroring where database_id = db_id(@database_name)) is null 
        begin
            raiserror(32039, 16, 1, @database_name)
            return 1
        end
 
    declare
        @database_id            smallint,
        @role                    bit,
        @status                    tinyint,
        @witness_status            tinyint,
        @log_flush_rate            bigint ,
        @send_queue_size        bigint ,
        @send_rate                bigint ,
        @redo_queue_size        bigint ,
        @redo_rate                bigint ,
        @transaction_delay        bigint ,
        @transactions_per_sec    bigint ,
        @time                    datetime ,
        @end_of_log_lsn            numeric(25,0),
        @failover_lsn            numeric(25,0),
        @local_time                datetime
 
    declare
        @retention_period        int,
        @oldest_date            datetime
 
        set @database_id = DB_ID( @database_name )
 
-- To select the correct perf counter, we need the instance name.
        declare 
            @perf_instance1        nvarchar(256),
            @perf_instance2        nvarchar(256),
            @instance            nvarchar(128)
 
        select @instance = convert( nvarchar,  serverproperty(N'instancename'))
        if @instance is null
        begin
            set @instance = N'SQLServer'
        end
        else
        begin
            set @instance = N'MSSQL$' + @instance
        end
 
        set @perf_instance1 = left(@instance, len(@instance)) + N':Database Mirroring'
        set @perf_instance2 = left(@instance, len(@instance)) + N':Databases'
 
--
-- Insert a single row in the table for each database
--
-- 1. Pull out the perf counters
-- 2. Pull out the information from sys.database_mirroring
-- 3. Get the end of log lsn
 
        declare @perfcounters table(
            counter_name        nchar(128),
            cntr_value            bigint
        )
 
        insert into @perfcounters select counter_name, cntr_value from sys.dm_os_performance_counters where
            (object_name = @perf_instance1 or object_name = @perf_instance2 ) and 
            instance_name = @database_name and
            counter_name IN (N'Log Send Queue KB', N'Log Bytes Sent/sec', N'Redo Queue KB', N'Redo Bytes/sec', N'Transaction Delay', N'Log Bytes Flushed/sec', N'Transactions/sec')
        -- TO DO select all perfcounters for all databases so that you only need to access them once.
        select @role = (mirroring_role - 1),
            @status = mirroring_state, 
            @witness_status = mirroring_witness_state,
            @failover_lsn = mirroring_failover_lsn,
            @end_of_log_lsn = mirroring_end_of_log_lsn
                from sys.database_mirroring where database_id = @database_id
        -- TO DO: when doing the join, store the database id.
        select @log_flush_rate = cntr_value from @perfcounters where counter_name = N'Log Bytes Flushed/sec'
        select @send_queue_size = cntr_value from @perfcounters where counter_name = N'Log Send Queue KB'
        select @send_rate = cntr_value from @perfcounters where counter_name = N'Log Bytes Sent/sec'
        select @redo_queue_size = cntr_value from @perfcounters where counter_name = N'Redo Queue KB'
        select @redo_rate = cntr_value from @perfcounters where counter_name = N'Redo Bytes/sec'
        select @transaction_delay = cntr_value from @perfcounters where counter_name = N'Transaction Delay'
        select @transactions_per_sec = cntr_value from @perfcounters where counter_name = N'Transactions/sec'
        set @time = getutcdate()
        set @local_time = getdate()
 
-- 4. and insert it here
        insert into msdb.dbo.dbm_monitor_data (database_id, role, status, witness_status, failover_lsn, end_of_log_lsn, log_flush_rate,
                send_queue_size, send_rate, redo_queue_size, redo_rate, transaction_delay, transactions_per_sec, time, local_time)
        values( @database_id, @role, @status, @witness_status, @failover_lsn, @end_of_log_lsn, @log_flush_rate, @send_queue_size, @send_rate,
            @redo_queue_size, @redo_rate, @transaction_delay, @transactions_per_sec, @time, @local_time )
 
        -- 
        -- Raise the alerts (as errors)
        --
        --
        -- we need to call sys.sp_dbmmonitorresults to get the last row inserted and then we will compare those results with what is in the alerts table
        --
        declare    @alert        bit,
                @threshold    int,
                @command    char(256),
                @time_behind_alert_value    datetime,
                @send_queue_alert_value        int,
                @redo_queue_alert_value        int,
                @average_delay_alert_value    int,
                @temp_time                    int
 
        declare @results table(
            database_name            sysname,    -- Name of database
            role                    int,        -- 1 = Principal, 2 = Mirror
            mirroring_state            int,        -- 0 = Suspended, 1 = Disconnected, 2 = Synchronizing, 3 = Pending Failover, 4 = Synchronized
            witness_status            int,        -- 1 = Connected, 2 = Disconnected
            log_generation_rate        int NULL,    -- in kb / sec
            unsent_log                int,        -- in kb
            send_rate                int NULL,    -- in kb / sec
            unrestored_log            int,        -- in kb
            recovery_rate            int NULL,    -- in kb / sec
            transaction_delay        int NULL,    -- in ms
            transactions_per_sec    int NULL,    -- in trans / sec
            average_delay            int,        -- in ms
            time_recorded            datetime,
            time_behind                datetime,
            local_time                datetime        
        )
 
        set @command = N'sys.sp_dbmmonitorresults ''' + replace(@database_name, N'''',N'''''') + N''',0,0'
        -- get just the values we want to test
        insert into @results exec (@command)
        select @time_behind_alert_value = time_behind, @send_queue_alert_value = unsent_log,
                @redo_queue_alert_value = unrestored_log, @average_delay_alert_value = average_delay
        from @results where database_name = @database_name
 
        -- These next four code blocks are the same:
        --    If the alert is enabled AND the value is above the threshold, fire the event
        -- The four code blocks are time behind, send queue, redo queue and average delay.
 
        -- time behind
        set @alert = 0    -- from SteveLi.  This will make sure that if there are problems with the select, the alert
                        -- will not accidentally fire.
        select @threshold = time_behind, @alert = enable_time_behind
            from msdb.dbo.dbm_monitor_alerts where database_id = @database_id
        begin
            set @temp_time = datediff(minute, @time_behind_alert_value, getutcdate())
            if ( @alert = 1 and @threshold < @temp_time ) -- time_behind_alert_value is datetime
            begin
                raiserror( 52040, 10, 1, @database_name, @temp_time, @threshold ) with log
            end
        end
        -- send queue
        set @alert = 0
        select @threshold = send_queue, @alert = enable_send_queue
            from msdb.dbo.dbm_monitor_alerts where database_id = @database_id
        begin
            if ( @alert = 1 and @threshold < @send_queue_alert_value )
            begin
                raiserror( 52042, 10, 2, @database_name, @send_queue_alert_value, @threshold ) with log
            end
        end
        -- redo queue
        set @alert = 0
        select @threshold = redo_queue, @alert = enable_redo_queue
            from msdb.dbo.dbm_monitor_alerts where database_id = @database_id
        begin
            if ( @alert = 1 and @threshold < @redo_queue_alert_value )
            begin
                raiserror( 52043, 10, 3, @database_name,@redo_queue_alert_value, @threshold ) with log
            end
        end
        -- average delay
        set @alert = 0
        select @threshold = average_delay, @alert = enable_average_delay
            from msdb.dbo.dbm_monitor_alerts where database_id = @database_id
        begin
            if ( @alert = 1 and @threshold < @average_delay_alert_value )
            begin
                raiserror( 52044, 10, 4, @database_name,@average_delay_alert_value, @threshold ) with log
            end
        end
 
        -- Prune the Data Table.
        select @retention_period = retention_period from msdb.dbo.dbm_monitor_alerts where database_id = @database_id
        if @retention_period is null
            set @retention_period = 168 -- 168 hours is equivalent to 7 days
        set @oldest_date = getutcdate() - (@retention_period / 24.)
        delete from msdb.dbo.dbm_monitor_data where time < @oldest_date and database_id = @database_id
    end
    -- OK, this SP was called with no database specified.
    -- We are going to go through all the databases that are mirrored and update them.
    else
    begin
        declare dbmCursor cursor local scroll 
            for select 
                database_id 
            from sys.database_mirroring 
            where mirroring_guid is not null
 
        open dbmCursor
        fetch next from dbmCursor
            into @database_id
 
        while @@fetch_status=0
        begin
-- Better make sure msdb..sp_Sentry_dbmmonitorupdate with a null parameter.  Could cause real bad problems.
            set @database_name = db_name( @database_id )
            if @database_name is not null
            begin
                
                exec msdb..sp_Sentry_dbmmonitorupdate @database_name
                fetch next from dbmCursor
                    into @database_id
            end
        end
 
        close dbmCursor
        deallocate dbmCursor
    end
 
return 0
end
 
GO

Download the script directly here: Create_Sentry_dbmmupdate.sql

Finally we need to create our SQL Agent Alerts that are fired when these errors are raised. SQL Sentry Event Manager can monitor these alerts. This allows us to automate responses, such as sending an email, or take other more advanced actions that SQL Sentry provides. We can then create a custom view that allows us to see a chronological, Outlook-style calendar picture of this activity alongside any other events like high impact queries that may trigger our alerts.

In addition to the four performance thresholds covered by the errors we’ve created, I’ve added some additional alerts for monitoring status changes such as mirror failovers as well as monitoring for automatic page repair. Automatic page repair is a great feature that was introduced with SQL 2008 and provides for automatic repair of corrupt pages using the partner database since it is an exact copy.

Paul Randal (b|t) has more details about automatic page repair in his blog.

So here is the script to create the alerts. Note I tried to keep the format as similar to that used in the original TechNet article for consistency.

USE [msdb];
GO
 
DECLARE @ReturnCode INT;
SELECT @ReturnCode = 0;
 
-- ***************
-- Create a set of alerts based on performance warnings
-- ***************
IF NOT EXISTS (SELECT name FROM msdb.dbo.syscategories WHERE 
   name=N'Database Mirroring' AND category_class=2)
BEGIN
EXEC @ReturnCode = msdb.dbo.sp_add_category @class=N'ALERT', 
   @type=N'NONE', @name=N'Database Mirroring';
IF (@@ERROR <> 0 OR @ReturnCode <> 0) GOTO Quit_Alert;
 
END;
 
DECLARE @alertName NVARCHAR(200);
-- Create [DBM Perf: Unsent Log Threshold Exceeded]
SELECT @alertName = N'DBM Perf: Unsent Log Threshold Exceeded';
EXEC msdb.dbo.sp_add_alert 
   @name=@alertName, 
   @category_name=N'Database Mirroring',
   @message_id=52042, 
   @severity=0, 
   @delay_between_responses=60, 
   @include_event_description_in=0,
   @enabled=1;
 
-- Create [DBM Perf: Oldest Unsent Transaction Threshold Exceeded]
SELECT @alertName = N'DBM Perf: Oldest Unsent Transaction Threshold Exceeded';
EXEC msdb.dbo.sp_add_alert 
   @name=@alertName, 
   @category_name=N'Database Mirroring',
   @message_id=52040, 
   @severity=0, 
   @delay_between_responses=60, 
   @include_event_description_in=0,
   @enabled=1;
 
-- Create [DBM Perf: Unrestored Log Threshold Exceeded]
SELECT @alertName = N'DBM Perf: Unrestored Log Threshold Exceeded';
EXEC msdb.dbo.sp_add_alert 
   @name=@alertName, 
   @category_name=N'Database Mirroring',
   @message_id=52043, 
   @severity=0, 
   @delay_between_responses=60, 
   @include_event_description_in=0,
   @enabled=1;
 
-- Create [DBM Perf: Mirror Commit Overhead Threshold Exceeded]
SELECT @alertName = N'DBM Perf: Mirror Commit Overhead Threshold Exceeded';
EXEC msdb.dbo.sp_add_alert 
   @name=@alertName, 
   @category_name=N'Database Mirroring',
   @message_id=52044, 
   @severity=0, 
   @delay_between_responses=60, 
   @include_event_description_in=0,
   @enabled=1;
 
 
-- Create [DBM Status: Mirroring Role Change]
SELECT @alertName = N'DBM Status: Mirroring Role Change';
EXEC msdb.dbo.sp_add_alert 
   @name=@alertName, 
   @category_name=N'Database Mirroring',
   @message_id=1480, 
   @severity=0, 
   @delay_between_responses=60, 
   @include_event_description_in=0,
   @enabled=1;
 
-- Create [DBM Status: Mirroring Active as Principal]
SELECT @alertName = N'DBM Status: Mirroring Active as Principal';
EXEC msdb.dbo.sp_add_alert 
   @name=@alertName, 
   @category_name=N'Database Mirroring',
   @message_id=1440, 
   @severity=0, 
   @delay_between_responses=60, 
   @include_event_description_in=0,
   @enabled=1;
 
-- Create [DBM Status: Mirroring Active as Mirror]   
SELECT @alertName = N'DBM Status: Mirroring Active as Mirror';
EXEC msdb.dbo.sp_add_alert 
   @name=@alertName, 
   @category_name=N'Database Mirroring',
   @message_id=1441, 
   @severity=0, 
   @delay_between_responses=60, 
   @include_event_description_in=0,
   @enabled=1;   
   
-- Create [DBM Status: Mirror Inactive]
SELECT @alertName = N'DBM Status: Mirror Inactive';
EXEC msdb.dbo.sp_add_alert 
   @name=@alertName, 
   @category_name=N'Database Mirroring',
   @message_id=1442, 
   @severity=0, 
   @delay_between_responses=60, 
   @include_event_description_in=0,
   @enabled=1;   
   
-- Create [DBM Status: Mirror Terminated]
SELECT @alertName = N'DBM Status: Mirror Terminated';
EXEC msdb.dbo.sp_add_alert 
   @name=@alertName, 
   @category_name=N'Database Mirroring',
   @message_id=1443, 
   @severity=0, 
   @delay_between_responses=60, 
   @include_event_description_in=0,
   @enabled=1;
  
-- Create [DBM Automatic Page Repair: In Progress]
SELECT @alertName = N'DBM Automatic Page Repair: In Progress';
EXEC msdb.dbo.sp_add_alert 
   @name=@alertName, 
   @category_name=N'Database Mirroring',
   @message_id=1432, 
   @severity=0, 
   @delay_between_responses=60, 
   @include_event_description_in=0,
   @enabled=1;
   
-- Create [DBM Automatic Page Repair: Successful]
SELECT @alertName = N'DBM Automatic Page Repair: Successful';
EXEC msdb.dbo.sp_add_alert 
   @name=@alertName, 
   @category_name=N'Database Mirroring',
   @message_id=1461, 
   @severity=0, 
   @delay_between_responses=60, 
   @include_event_description_in=0,
   @enabled=1;
   
-- Create [DBM Automatic Page Repair: Failed]
SELECT @alertName = N'DBM Automatic Page Repair: Failed';
EXEC msdb.dbo.sp_add_alert 
   @name=@alertName, 
   @category_name=N'Database Mirroring',
   @message_id=1481, 
   @severity=0, 
   @delay_between_responses=60, 
   @include_event_description_in=0,
   @enabled=1;
Quit_Alert:

Download the script directly here: Mirror_Alerts.sql

We’ve now successfully created our workaround and should be getting properly detailed alerts based on those conditions. Remember to run these scripts on both your principal and mirror server for complete coverage.

Increased Visibility and Notification with SQL Sentry

Now that we’ve set up reliable detection of our mirroring thresholds, let’s take a look at the increased visibility and automation that can be provided with SQL Sentry Event Manager.

SQL Sentry Event Manager can monitor many SQL related events and show this activity in an Outlook-style calendar view. Among the events that can be monitored and shown are SQL Agent Alerts like the ones we just created.

In our Log Shipping and Replication whitepaper, we show you how to create Custom Event Views for providing visibility into log shipping and replication activity. The same functionality can be applied to mirroring and the mirroring alerts we created. In fact, if you are monitoring your mirrored servers with Event Manager and Performance Advisor, known as the SQL Sentry Power Suite, you can add any Top SQL statements to the view. This allows you to see historically, the exact times high impact queries were executing alongside any mirroring alerts that were likely generated due to the extra load as shown in the example screenshot.

mirperfalert

Notice we get our status alerts too. In the above test I ran queries to generate enough activity against the mirrored database to trigger some of our performance alerts. I can see and be notified of mirror failovers the same way as seen below.

mirfail

With both scenarios I get confirmation from both sides of the mirror because I’ve set up my alerts on both the principal instance and the mirror instance. The same visibility and notification applies to my automatic page repair alerts.

Automation

Monitoring your mirrors with Event Manager can allow you to add automation to your environment as well. The most common action would be to get emails or pages when these alerts are raised. That is basic functionality in Event Manager without the need for database mail. You can get a quick review on setting up notifications in the SQL Sentry User Guide.

Another example might involve an application that requires access to multiple mirrored databases on the same server. Should one failover, you want them all to failover together. SQL Sentry’s Execute SQL actions allow you to do just that. Simply enter the appropriate commands in the Execute SQL action for this alert, and SQL Sentry can automate the failover of the other mirror.

Director of Client Services, Jason Hall (b|t), has a blog post detailing the use of Execute Actions in SQL Sentry.

New in SQL Sentry Version 7

SQL Sentry version 7 has added even more visibility into mirroring. First you may have noticed a new node under your SQL Server instances in the Navigator pane labeled Databases. Double clicking on a database provides details including mirroring information.

mirinfo

Additionally, you may have noticed new metrics in the Performance Advisor dashboard. In the upper right, we have provided a chart for backup throughput. In version 7, should we detect at least one mirrored database on the instance, we’ll show Send and Redo Queue size as well. This provides both real time and historical views into the size of either queue.

queuehist

When you combine this with the calendar visibility for these events and alerting on all these mirroring thresholds and status events, you get comprehensive coverage and can rest assured you’ll know whenever your mirrored databases experience any issues.  If you haven’t already, download a free evaluation copy of the complete SQL Sentry Suite at http://www.sqlsentry.net/download-trial/trial.asp.  And if you have any questions, don’t hesitate to contact me or the rest of the team by emailing support at sqlsentry.net.

58 comments:

  1. Great post! I just started using mirroring on our production database and your alerts will be very important. Thanks again.

    ReplyDelete
  2. Nice Article Steve, i have one Question,if the databases are mirrored do we have to monitor both the instances in PA/EM, if so, does it require a license to monitor a mirrored instance ?

    ReplyDelete
  3. Thanks! Yes, if you want the complete picture you'll want to monitor both instances involved in the mirror. This would be especially important in the event of a failover to ensure you are always monitoring the primary. Regardless you want to ensure you monitor both the Send Queue on the primary as well as the Redo Queue on the mirror. SQL Sentry does require a license for each monitored instance.

    ReplyDelete
  4. Awesome Artical Really i have searching this type of valuable information From a lot of days i found satisfaction when Read your blog Thanks for giving this type blog and also please Read link bvba Woodstone which provide information server monitoring software & Network monitoring tools: http://www.woodstone.nu/salive

    ReplyDelete
  5. There could be others who have the permission to update the data on the database too. It is the duty of the system administrator to frequently check that this privilege is not misused and vital information is tampered. Database Diagram Tool

    ReplyDelete
  6. Thanks for sharing the post.. parents are worlds best person in each lives of individual..they need or must succeed to sustain needs of the family. kit per cancello automatico

    ReplyDelete
  7. We as QuickBooks Support Phone Number +1-844-233-5335 team provide our matchless support for the issues in QuickBooks to its users worldwide. It goes without saying that QuickBooks is one of the most helpful accounting software presents in the current time. Read more- https://tinyurl.com/yy9ov86q & visit us- https://www.qbooksupportphonenumber.com/

    ReplyDelete
  8. QuickBooks has completely transformed the way people used to run their business earlier. In order to get used to it, one should welcome this positive change. Supervisors at QuickBooks Support Phone Number 800-417-3165 have trained all their executives to combat the issues in this software. Read more- https://tinyurl.com/y52oohj6 & visit us- https://www.qbcustomersupportphonenumber.com/

    ReplyDelete
  9. QuickBooks is one of the most widely used accounting software, it also offers you a range of versions. We provide help at QuickBooks Payroll Support Phone Number +1-844-233-5335 to deal with the issues in this QuickBooks version. Read more- https://tinyurl.com/y4rwdn9t & visit us- https://www.qbooksupportphonenumber.com/quickbooks-payroll/

    ReplyDelete
  10. Our support team at QuickBooks Payroll Support Phone Number +1-800-417-3165 helps you deal with the issues that pop up in this software. When it comes to errors, there are so much that you may face. Read more- https://tinyurl.com/y6crto3c & visit us- https://www.qbcustomersupportphonenumber.com/quickbooks-payroll/

    ReplyDelete
  11. Our team at Phone Number For Quickbooks Payroll Support 1(800)674-9538 are responsible for addressing customer needs and ensures that they get the fastest solutions for their queries. for more visit: https://www.payrollsupportphonenumber.com/

    ReplyDelete
  12. QuickBooks Customer Service +1 800-674-9538 team provides solutions that are easy to implement. What further makes them the top-notch source for QuickBooks support is their round the clock availability. for more visit: https://www.payrollsupportphonenumber.com/quickbooks-customer-service/

    ReplyDelete
  13. QuickBooks has amazed a lot of business owners with its outstanding performance. Yet, some errors might obstruct you from enjoying the benefits of QuickBooks. Team at QuickBooks Technical Support Phone Number +1 844-233-5335 helps you come out clear of the errors of this software in no time. Read more- https://tinyurl.com/y2xxv6hy & Visit us- https://www.qbooksupportphonenumber.com/quickbooks-technical/

    ReplyDelete
  14. Our support team at QuickBooks Payroll Support Phone Number +1-800-417-3165 helps you deal with the issues that pop up in this software. When it comes to errors, there are so much that you may face. Read more- https://tinyurl.com/y6crto3c & visit us- https://www.qbcustomersupportphonenumber.com/quickbooks-payroll/

    ReplyDelete
    Replies
    1. https://www.leansimulations.org/2011/02/lean-lego-game-4-rounds-to-successful.html?showComment=1564726272863#c2355939943514120111

      Delete
  15. QuickBooks Support Phone Number +1-800-417-3165 is assisted by our customer support representatives who answer your call instantly and resolve all your issues on the spot. It is a backing portal that authenticates the users of QuickBooks to run its features in a user-friendly manner. Read more- https://tinyurl.com/y52oohj6 & visit us- https://www.qbcustomersupportphonenumber.com/

    ReplyDelete
    Replies
    1. Hey! What an outstanding post. I really like your work. I have been using QuickBooks from past 2 years. Overall QuickBooks is a wonderful accounting software for small and medium sized businesses. By installing QuickBooks, you can save your time and money. You can even get live help and support at QuickBooks Tech Support Phone Number 1-855-236-7529.
      Rea more: https://www.techiesupportnumber.com/quickbooks-contact-number/
      Website: https://tinyurl.com/y3kahnzm

      Delete
    2. Hey! What an outstanding post. I really like your work. I have been using QuickBooks from past 2 years. Overall QuickBooks is a wonderful accounting software for small and medium sized businesses. By installing QuickBooks, you can save your time and money. You can even get live help and support at QuickBooks Tech Support Phone Number 1-855-236-7529.
      Rea more: https://www.techiesupportnumber.com/quickbooks-contact-number/
      Website: https://tinyurl.com/y3kahnzm

      Delete
    3. Hey! What an outstanding post. I really like your work. I have been using QuickBooks from past 2 years. Overall QuickBooks is a wonderful accounting software for small and medium sized businesses. By installing QuickBooks, you can save your time and money. You can even get live help and support at QuickBooks Tech Support Phone Number 1-855-236-7529.
      Rea more: https://www.techiesupportnumber.com/quickbooks-contact-number/
      Website: https://tinyurl.com/y3kahnzm

      Delete
  16. I don’t know how I landed here. I have rarely seen such a creative and well drafted post. You have summarized the entire subject in an outstanding manner. I could get the entire context in a single tour of the post. Keep writing such posts more often.
    In case there is any technical issues concerning anyone, the team is available at
    QuickBooks Support Phone Number +1 833-222-6943 24/7. It ensures the resolution within the minimum time span. The users can get advice from the technically skilled and qualified professionals. Moreover, they provide specialized guidelines and instructions to their users.
    Visit: https://tinyurl.com/y6g3ng8h

    ReplyDelete
  17. These kinds of blogs are so rare to find these days. I appreciate you for this excellent post. The creativity, presentation and the ideas are added up together in a beautiful manner. I wish to see more such kinds of posts.
    One thing I would like to tell you. If there is any discrepancy in the system, immediately contact the QuickBooks Payroll Support Phone Number +1 833-222-6943. The experience of their customer care services in very unique and excellent.
    Visit: https://tinyurl.com/y6g3ng8h

    ReplyDelete
  18. Nice blog! I must appreciate your writing skills and efforts. Thanks for sharing this useful piece of information with us. I am really surprised that this type of good content still exists on internet. I am here with a very useful piece of information. Are you a businessman? Looking to automate your accounting tasks? No need to worry more. Yes, you can use QuickBooks accounting software to manage your business accounting related task. In case you ever stuck with technical issues in the software then feel free to access our support services by dialling QuickBooks Technical support Phone Number +1 800-311-5657
    for more visit: https://www.getsupportphonenumber.com/quickbooks-support-number/

    ReplyDelete
  19. Nice blog! I must appreciate your writing style and the way you tell your point of view. Thanks for sharing this blog. You know you can ease your business management process to a great extent? Yes, this is possible by adapting QuickBooks accounting software. This software consists of power packed tools and features to help you automate your entire
    accounting tasks. In case you ever stuck with technical problem in the software then you can get in touch with professional by dialling QuickBooks Helpline Number +1 800-311-5657. Here, they provide end-to-end technical support for QuickBooks at affordable market price.for more visit: https://www.getsupportphonenumber.com/quickbooks-support-number/

    ReplyDelete
  20. Hi, thanks for sharing this useful blog with us. I must appreciate your valuably and writing style. You have nicely described each point in your blog. I am here to help you in your QuickBooks accounting process. If you are facing any kind of issue while using the software then Phone Number for Quickbooks Payroll Support +1 800-311-5657 is your one-stop
    destination. Here, you can learn a number of tools and techniques for a productive usage of QuickBooks. Additionally, the provide technical support at comfort of your home on wallet-friendly price.for more visit: https://www.getsupportphonenumber.com/quickbooks-support-number/

    ReplyDelete
  21. Wow, what an amazing collection of ideas and an excellent manner of presenting them. I appreciate your efforts and the way of drafting this entire segment of information. It is equally understandable by the beginners as well as those in the learning stage. Now, I want more such kind of posts. I would like to add an important information regarding the technical assistance. The support team is available at Phone Number for QuickBooks Support +1 800-311-5657. They get instant solutions for their users within the nearest time instant. Their aid is quite amazing, concise and available 24/7 round the clock. for more visit: https://www.getsupportphonenumber.com/quickbooks-support-number/

    ReplyDelete
  22. I must say that this synchronization of creativity, presentation and representation is quite impressive. Excellent collection of highly relevant ideas. This post is enough for one to get deep into the topic. I congratulate you for this post. I hope I get such more posts in future. I have got an important update for you regarding the use of QuickBooks. When coming across technical hurdles, the concerned person can call the support team at QuickBooks Support Number +1 833-228-2822. For any assistance required regarding the issues, the team provides an instant relief to the users stuck in troublesome situations.

    ReplyDelete
  23. I must say that this synchronization of creativity, presentation and representation is quite impressive. Excellent collection of highly relevant ideas. This post is enough for one to get deep into the topic. I congratulate you for this post. I hope I get such more posts in future. I have got an important update for you regarding the use of QuickBooks. When coming across technical hurdles, the concerned person can call the support team at QuickBooks Support Phone Number +1 833-228-2822. For any assistance required regarding the issues, the team provides an instant relief to the users stuck in troublesome situations.

    ReplyDelete
  24. I must say that this synchronization of creativity, presentation and representation is quite impressive. Excellent collection of highly relevant ideas. This post is enough for one to get deep into the topic. I congratulate you for this post. I hope I get such more posts in future. I have got an important update for you regarding the use of QuickBooks. When coming across technical hurdles, the concerned person can call the support team at QuickBooks Technical Support +1 833-228-2822. For any assistance required regarding the issues, the team provides an instant relief to the users stuck in troublesome situations.

    ReplyDelete
  25. QuickBooks is an accounting software package developed and marketed by Intuit. QuickBooks products are geared mainly toward small and medium-sized businesses and offer on-premises accounting applications as well as cloud-based versions that accept business payments, manage and pay bills, and payroll functions.Time to time, Intuit releases new updates for its all its QuickBooks editions be it QuickBooks Pro, QuickBooks Premier, QuickBooks Enterprise, QuickBooks Online or QuickBooks Accountant. These updates help with better management of the day to day transactions and remove any errors or bugs. You can more information about the latest updates by dialing the toll-free QuickBooks Support Phone Number. Also, it is very important for QB Users to have knowledge of all the tools and features that are available on QB and how to use them efficiently. If you do not have the right knowledge and are looking to get it then call on the QuickBooks Tech Support Number and learn from the QuickBooks Experts

    ReplyDelete
  26. It gives me an immense pleasure to go through your posts from time to time.
    Because of their unique content and presentation. I wish you a success and hope you
    keep writing more and more such posts.
    I would like to tell you that while working, if you come across technical issues and not
    able to tackle them. Establish a connection with the experts and see your all the
    faults disappearing. There is an assurance that the problem will be sorted out within
    a fixed deadline. You just need to dial theQuickBooks Support Phone Number1-844-235-3996 to get assistance.
    Vsit :- https://tinyurl.com/yynvmjf2

    ReplyDelete
  27. It gives me an immense pleasure to go through your posts from time to time.
    Because of their unique content and presentation. I wish you a success and hope you
    keep writing more and more such posts.
    I would like to tell you that while working, if you come across technical issues and not
    able to tackle them. Establish a connection with the experts and see your all the
    faults disappearing. There is an assurance that the problem will be sorted out within
    a fixed deadline. You just need to dial theQuickBooks Support Phone Number1-844-235-3996 to get assistance.
    Vsit :- https://tinyurl.com/yynvmjf2

    ReplyDelete
  28. It gives me an immense pleasure to go through your posts from time to time.
    Because of their unique content and presentation. I wish you a success and hope you
    keep writing more and more such posts.
    I would like to tell you that while working, if you come across technical issues and not
    able to tackle them. Establish a connection with the experts and see your all the
    faults disappearing. There is an assurance that the problem will be sorted out within
    a fixed deadline. You just need to dial theQuickBooks Support Phone Number1-844-235-3996 to get assistance.
    Vsit :- https://tinyurl.com/yynvmjf2

    ReplyDelete
  29. It gives me an immense pleasure to go through your posts from time to time.
    Because of their unique content and presentation. I wish you a success and hope you
    keep writing more and more such posts.
    I would like to tell you that while working, if you come across technical issues and not
    able to tackle them. Establish a connection with the experts and see your all the
    faults disappearing. There is an assurance that the problem will be sorted out within
    a fixed deadline. You just need to dial theQuickBooks Support Phone Number1-844-235-3996 to get assistance.
    Vsit :- https://tinyurl.com/yynvmjf2

    ReplyDelete
  30. Dial Sage 50 customer support phone number Canada 1-844-995-7243 to get the efficient customer support services for Sage 50 accounting software issues at the most pocket friendly market price. Read more- https://tinyurl.com/y2nsgqga & visit us-https://www.getsupportcontactnumber.com/sage-50-customer-support-phone-number-canada-1-844-995-7243/

    ReplyDelete
  31. Ours is a team at sage 50 technical support phone number 1-844-995-7243 that leaves no stone unturned to bring you out of any difficulty that you are facing while using Sage 50. Whether it is Sage 50c or classic Sage 50 we help you in all the ways possible to resolve all your issues and let you carry on with your work without much interruption. Read more- https://tinyurl.com/yyueyche & visit us-https://www.getsupportcontactnumber.com/

    ReplyDelete
  32. Nice Blog Thanks for sharing this useful link. It’s a really informative for all. QuickBooks is one of the best accounting software which helps in managing your company finances and accounting. Any technical issue obstructing your way ahead? Call us now on Quickbooks Support Phone Number 1-800-986-4607.

    ReplyDelete
  33. Our team at QuickBooks Support Phone Number +1 800-417-3165 has been providing its matchless assistance for the errors in QuickBooks for quite a long time. Though this software is regarded as one of the top most accounting applications in the world, it is often accompanied by some errors. Before we jump onto its errors, let’s have a brief introduction of QuickBooks. Visit us- https://www.theqbsupportphonenumber.com/

    ReplyDelete
  34. Get prominent solutions for QuickBooks near you right away! Without any doubts, QuickBooks has revolutionized the process of doing accounting that is the core strength for small as well as large-sized businesses. QuickBooks Support Phone Number +1-800-417-3165 is a backing portal that authenticates the users of QuickBooks to run its features in a user-friendly manner. Visit us- https://www.qbcustomersupportphonenumber.com/

    ReplyDelete
  35. Our support team at QuickBooks Payroll Support Phone Number +1-800-417-3165 helps you deal with the issues that pop up in this software. When it comes to errors, there are so much that you may face. From installation error to upgrading error to update issues to even multi-user troubles etc., all the issues of QuickBooks Payroll are solved in the easiest manner by our talented team. Visit us- https://www.qbcustomersupportphonenumber.com/quickbooks-payroll/

    ReplyDelete
  36. QuickBooks error 6073
    It would be a delight for you to know that this team is available at your service for 24 hours. Therefore, in future, if you ever encounter QuickBooks error 6073 just call at QuickBooks Support Phone Number +1 800-417-3165 and all your issues will vanish. Read more- https://tinyurl.com/y4dd4brh & visit us- https://www.qbcustomersupportphonenumber.com/quickbooks-error-6073/
    QuickBooks error 6129
    So, next time if you face any issue in this software like QuickBooks error 6129 call at QuickBooks Support Phone Number +1 800-417-3165. Read more- https://tinyurl.com/y4jmbpdr & visit us-https://www.qbcustomersupportphonenumber.com/quickbooks-error-6129/

    ReplyDelete
  37. QuickBooks error 6147
    Apart from this, these guys are available 24*7 to fix issues like QuickBooks error 6147 for you. So, dial QuickBooks Support Phone Number +1 800-417-3165 and get away with the problems in this software. Read more- https://tinyurl.com/y2w6wh5r & visit us-https://www.qbcustomersupportphonenumber.com/quickbooks-error-6147/
    QuickBooks error 6150
    Apart from this, these guys are available round the clock at your service. So, in case you encounter QuickBooks error 6150 in future, do not hesitate to call the team at QuickBooks Support Phone Number +1 800-417-3165. Read more- https://tinyurl.com/y3fd9f6s & visit us-https://www.qbcustomersupportphonenumber.com/quickbooks-error-6150/

    ReplyDelete
  38. QuickBooks error 6210
    Also, these guys are quite friendly in nature and are always ready to help you even at the wee hours. So, call them at QuickBooks Support Phone Number +1 800-417-3165 without any doubt the next time you encounter QuickBooks error 6210. Read more- https://tinyurl.com/y5qqjzah & visit us- https://www.qbcustomersupportphonenumber.com/quickbooks-error-6210/
    QuickBooks error 61
    So, stop wasting your time in the search of a dependable support team, rather call at QuickBooks Support Phone Number +1 800-417-3165 and get QuickBooks error 61 fixed in no time. Read more- https://tinyurl.com/y25pyzw6 & visit us- https://www.qbcustomersupportphonenumber.com/quickbooks-error-61/

    ReplyDelete
  39. QuickBooks error 30159
    So, next time if you come in terms with QuickBooks error 30159 just call at QuickBooks Support Phone Number +1 800-417-3165. Read more- https://tinyurl.com/yymsk8vb & visit us- https://www.qbcustomersupportphonenumber.com/quickbooks-error-30159/
    QuickBooks error 12007
    So, in future if you come across any issue like QuickBooks error 12007 just dial QuickBooks Support Phone Number +1 800-417-3165. Read more- https://tinyurl.com/y26he33c 7 visit us- https://www.qbcustomersupportphonenumber.com/quickbooks-error-12007/
    QuickBooks error 12029
    These experts work towards achieving maximum customer satisfaction. Therefore, call them at QuickBooks Support Phone Number +1 800-417-3165 and get issues like QuickBooks error 12029 fixed instantly. Read more- https://tinyurl.com/yyulub9j & visit us- https://www.qbcustomersupportphonenumber.com/quickbooks-error-12029/

    ReplyDelete
  40. QuickBooks error OLSU 1013
    Also, this exceptional team is available 24/7 at your service. So, call the team at QuickBooks Support Phone Number+1 800-417-3165 to get done with the errors in QuickBooks error OLSU 1013. Read more- https://tinyurl.com/y3vrhfuu & visit us- https://www.qbcustomersupportphonenumber.com/quickbooks-error-olsu-1013/
    QuickBooks error 102
    And most of all, they are available at your service for 24 hours. So just dial their toll-free number +1 800-417-3165 and get away with the issues like QuickBooks error 102. Read more- https://tinyurl.com/y59pl7e8 7 visit us-https://www.qbcustomersupportphonenumber.com/quickbooks-error-102/

    ReplyDelete
  41. Being customer friendly with all their customers is another quality of this team. Hence, call them at their toll-free number +1 800-417-3165 and get fixed issues like QuickBooks installation error. Read more- https://tinyurl.com/y6znyj9d & visit us- https://www.qbcustomersupportphonenumber.com/quickbooks-installation-error/

    ReplyDelete
  42. QuickBooks error 324
    So, next time if you come across QuickBooks error 324 wave it a big good bye by calling at QuickBooks Support Phone Number +1 800-417-3165. Read more- https://tinyurl.com/yxzc4jkg & visit us- https://www.qbcustomersupportphonenumber.com/quickbooks-error-324/
    QuickBooks Install Error 1904
    So, in future if you ever come across QuickBooks Install Error 1904 just dial QuickBooks Support Phone Number +1 800-417-3165. Read more- https://tinyurl.com/y6sfzl3u & visit us- https://www.qbcustomersupportphonenumber.com/quickbooks-install-error-1904/

    ReplyDelete
  43. Our team at QuickBooks Support Phone Number +1 800-417-3165 has been providing its matchless assistance for the errors in QuickBooks for quite a long time. Though this software is regarded as one of the top most accounting applications in the world, it is often accompanied by some errors. Before we jump onto its errors, let’s have a brief introduction of QuickBooks. Visit us- https://www.theqbsupportphonenumber.com/

    ReplyDelete
  44. Enjoy Top-Notch Assistance at QUICKBOOKS PAYROLL SUPPORT PHONE NUMBER +1 800-417-3165. It is said that ‘hard work and success go hand in hand’. Our team at QuickBooks Payroll Support Phone Number +1 800-417-3165 follows this mantra dedicatedly and the results that we have achieved so far are applaudable. QuickBooks is the most opted application when it comes to handle accounting affairs. It automates the complete business running process in such a way that everything falls into place. Visit us- https://www.theqbsupportphonenumber.com/quickbooks-payroll/

    ReplyDelete
  45. Hi, I was looking for content that can help me with my project. Thank you! All the points that are mentioned in your blog are relevant and simple to understand. You can even manage your work by downloading QuickBooks. For more help related to issues, contact us at QuickBooks Tech Support Phone Number +1 833-222-6943. The teams of professional technicians are available 24 hours 365 days.
    Visit more: https://www.qbtechservices.com/

    ReplyDelete
  46. Hey loved all that you shared. Undoubtedly, you have some of the best posts that I have come across. Keep going and all the best. Now, you can easily manage your time by downloading QuickBooks software. For any issues related to this software, you can contact us at QuickBooks Enterprise Support Phone Number +1 833-222-6943.
    You can even visit the website https://www.qbtechservices.com/ to know about the policies and services.

    ReplyDelete
  47. Nice Blog It’s a really informative for all. QuickBooks is a reliable accounting software. You can easily use and install QuickBooks. We are providing technical support in Quickbooks Support Phone Number 1800. Please call us our Toll-free Number + 1-800-986-4607.

    ReplyDelete
  48. Nice Blog Thanks for sharing this use full link. QuickBooks is a reliable accounting software. You can easily use and install QuickBooks. We are providing technical support in Quickbooks Payroll Support Phone Number . Our technical support team is 24*7 available so if you need any help. Please call us our Toll-free Number + 1-800-986-4607.

    ReplyDelete
  49. Nice Blog It’s a really informative QuickBooks is designed to meet your ever-increasing business accounting needs. Are QuickBooks errors troubling you ? Quickbooks for MAC support phone number it is Specifically designed for MAC operating system.We are providing 24*7 technical support so if you need any query.Please call us our Toll-free Number + 1-800-986-4607

    ReplyDelete
  50. Nice Blog Our support team at QuickBooks Tech Support Phone Number 1-800-986-4591 resolve your all issue in Quickbooks like installation & upgrading. We are providing 24*7 technical support so if you need any query.

    ReplyDelete
  51. Hey,
    I have been a regular reader of your blog. The current topic is indeed different from the rest of the topics. Now, you can easily manage your work by downloading QuickBooks. This software has some of the most amazing features. Hence, if you face any problem while working on this software, you can call us at QuickBooks Enterprise Support Phone Number +1 833-222-6943 Your call will be answered by the professional expert.
    Visit: https://www.qbtechservices.com

    ReplyDelete
  52. I think I must mention your outstanding writing skills. Well, your skills are unique and reader-engaging. You must write more often to share knowledge and publicize your skills. I have used QuickBooks for many years and find myself happy with the support team. You can check out their star services in technically difficult situations at QuickBooks Pro Support Phone Number+1 833-222-6943
    Visit: https://www.qbtechservices.com

    ReplyDelete