Custom Configuration Checks
Custom configuration checks enable you to verify values that are specific to your SQL Server setup. For example, you can check the last update time in a table, ensure that row counts from replicated tables are in sync, or leverage new DMVs by creating custom queries without waiting for the next release of Aireforge Studio.
Creating a Custom Configuration Check
- Open Aireforge Studio.
- Navigate to the Compare tab.
- From the toolbar, select Configure, then click Add Comparison.
This dialog allows you to create custom configuration checks tailored to your environment.
Example: Custom Configuration Check
In this example, we'll create a custom configuration check to verify whether "Lock Pages in Memory" is enabled.
Note: This check is only compatible with SQL Server 2016 SP1 and later. If applied to versions older than 2016, the comparison will fail. You can add a version check in the query for now, and we plan to introduce more granular version control in future updates.
Name:
Lock Pages in Memory
Author:
You
Category: Create a new category or use an existing one like
Instance > Hardware
.Description: The query returns
sql_memory_model_desc
, which can be one of the following:CONVENTIONAL
LOCK_PAGES
LARGE_PAGES
(Enterprise Edition Only).
Query:
Since this applies only to SQL Server 2016 SP1 or newer, we'll use a single query. It's possible to create different queries for different SQL Server versions, especially if you want to convert units (e.g., KB to MB) between versions.
SELECT sql_memory_model_desc FROM sys.dm_os_sys_info;
Applies to: Select
SQL Server 2016 SP1
. If you apply this check to older versions, it may fail unless you include a version check in the script.Columns: Define how Aireforge Studio should compare the columns in the result set. For this check, we'll select Normal Compare. The available options are:
- Primary Key: Used to match rows between result sets.
- Ignore: The column is ignored and not included in the comparison.
- Normal Compare: The values should be equal across all servers.
- No Compare: The values are displayed in the result set but not compared between servers.
- Unique: The value should be unique across servers.
Saving and Running the Custom Configuration Check
Once you've set up the custom check, save it, and run a comparison through Aireforge Studio. The tool will compare the results across your selected servers, identifying any discrepancies.
If you create a useful script and think it could benefit others, feel free to share it with us for potential inclusion in future Aireforge Studio updates.