Ignoring additional waits

SQL Monitor ignores a number of waits by default. It may be necessary or desirable to ignore additional waits.

Step-by-step guide

Ignorable waits can be added to the table settings.KeyValuePairs. It is recommended that you verify the insert is working as desired before modifying the contents of this table. This guide makes the assumption that you will be verifying the data in Step 1 before committing the data in Step 2.

  1. In this step we verify that the wait to be inserted is correct. As an example, the wait PWAIT_DIRECTLOGCONSUMER_GETNEXT is being ignored:

    BEGIN TRANSACTION;

    DECLARE @IgnoreWait NVARCHAR(128);
    -- Replace the value below with the wait you wish to ignore, surrounded by double quotes

    SET @IgnoreWait = '"PWAIT_DIRECTLOGCONSUMER_GETNEXT"';

    SELECT KeyValue
    FROM settings.KeyValuePairs
    WHERE KeyName = 'WaitStatsCollection-WaitsToIgnore';

    UPDATE settings.KeyValuePairs
    SET KeyValue = @IgnoreWait + ',' + KeyValue
    WHERE KeyName = 'WaitStatsCollection-WaitsToIgnore';

    SELECT KeyValue
    FROM settings.KeyValuePairs
    WHERE KeyName = 'WaitStatsCollection-WaitsToIgnore';

    ROLLBACK TRANSACTION;


  2. Verify the output of the SELECT statements in Step 1. You should see output similar to the following:


    Note that the newly-added wait will appear at the beginning of the list of ignorable waits. 

  3. Once you are happy with the output of Step 1, you can update the contents of the table as follows:

    DECLARE @IgnoreWait NVARCHAR(128);
    SET @IgnoreWait = '"PWAIT_DIRECTLOGCONSUMER_GETNEXT"';

    UPDATE settings.KeyValuePairs
    SET KeyValue = @IgnoreWait + ',' + KeyValue
    WHERE KeyName = 'WaitStatsCollection-WaitsToIgnore';

Verify that your changes to settings.KeyValuePairs are maintained after an update to SQL Monitor.




Do you have any feedback on this documentation?

Let us know at sqlmonitorfeedback@red-gate.com


Didn't find what you were looking for?