Configuring Microsoft SQL Server monitoring profile
This topic describes how to configure BMC PATROL for Microsoft SQL Server.
The following video (4:08) demonstrates how to configure the monitoring of the Microsoft SQL server:
On the Add Monitor Types dialog, with the Monitor Profile set to Microsoft SQL Server, and the Monitor Type set to MS SQL Server, provide the following details:
Field | Description | |||
---|---|---|---|---|
Environment name | Enter a unique logical name for the environment. A container will be created with the environment name. This environment will hold all the SQL Server databases. BMC recommends you to provide only alphanumeric characters in environment name. | |||
Windows user | ||||
Windows user credentials are used for discovery and to collect host related data, such as disk size or MS SQL Server service status. UserName should contain the domain name (DOMAIN_NAME\USER_NAME). | ||||
User Name | Enter a unique, user-defined alias name, host name. User Name should contain a domain name (DOMAIN_NAME\USER_NAME). | |||
Password | Enter the password for the specified user. | |||
Confirm Password | Re-enter the password for confirmation. | |||
MS SQL Server login | ||||
User Name | Enter a unique username. This username is the MS SQL Server login that will be used for monitoring. If this field is left blank then, the Windows User credentials will be used to connect to the MS SQL Server (Integrated Security). | |||
Password | Enter the password for the specified user. | |||
Confirm Password | Re-enter the password for confirmation. | |||
Hosts configuration | ||||
Host name/IP address | Enter the FQDN or IP Address where the SQL Server is installed. $HOSTNAME refers to the host on which Patrol Agent is installed. (Default value is $HOSTNAME) | |||
MS SQL server instance configuration | ||||
MS SQL Server instance name (regex) | Enter the name of the MS SQL server instance. Enter .* to discover all the available instances. | |||
Monitor databases only | Enable this option to monitor only database related metrics. Monitoring of any other SQL Server general metrics will be disabled. | |||
Monitor availability only | Enable this option to monitor only availability related metrics. Monitoring of any other SQL Server general metrics will be disabled. | |||
Databases | ||||
Filtering mode | Specify the filtering type for filtering the database.
| |||
Include/Exclude from monitoring (regex) | Enter a regular expression of the relevant database names to either include or exclude from filtering. | |||
Monitor files and file groups | Enable monitoring of DB files and file groups. | |||
Ignore file 'Autogrowth' | Configuration for Space Used Percentage Metrics | |||
MS SQL Agent | ||||
Jobs considered as failed as long as its last run was failed | Select this check box if you want to consider a job as failed as long as its last run was failed. Such values are stored in the SQL Agent Job Failures parameter. For example, when one job fails in a collection interval, the value of the SQL Agent Job Failures parameter is set to 1 and the value remains so until next run. If the check box is clear, the value of the SQL Agent Job Failures parameter is reset to 0 in the new collection interval if the job did not run during the new collection interval. If you want to retain the number of jobs that failed until the same job runs successfully during any collection interval, select this check box. | |||
Jobs filtering options | ||||
Jobs by logins filtering options | ||||
Filtering mode | Specify the filtering type for the filtering the MS SQL Agent jobs by logins.
| |||
Include/Exclude from monitoring (regex) | Enter a regular expression of the relevant MS SQL Agent jobs by logins to either include or exclude from filtering. | |||
Jobs by categories filtering options | ||||
Filtering mode | Specify the filtering type for the filtering the MS SQL Agent jobs by categories.
| |||
Include/Exclude from monitoring (regex) | Enter a regular expression of the relevant MS SQL Agent jobs by categories to either include or exclude from filtering. | |||
Jobs by names filtering options | ||||
Filtering mode | Specify the filtering type for filtering the MS SQL Agent jobs by names.
| |||
Include/Exclude from monitoring (regex) | Specify a regular expression of the relevant MS SQL Agent jobs by names to either include or exclude from filtering | |||
Perfmon objects filtering | ||||
Perfmon monitoring level |
| |||
Click Custom filtering settings to filter perfmon objects | ||||
Filtering mode | Specify the filtering type for filtering the perfmon objects.
| |||
Perfmon objects | Select the list of perfmon objects to add to the List - Custom perfmon filtering list to Include/Exclude from filtering.
| |||
Custom SQL queries | ||||
Name | Enter the logical name for the SQL query. | |||
SQL query | Enter the SQL query. | |||
Collection interval (min) | Specify the collection interval in minutes | |||
Time based parameters configuration | ||||
Long Running Transactions criteria (min) | Specify the amount of time the transaction has been running before it is considered as a long running transaction. All long running transactions are reported by the Long Running Transactions parameter. | |||
SQL Agent Hung Jobs criteria (min) | Specify the amount of time the job has been running before it is considered as a hung job. All the hung jobs are reported by the SQL Agent Hung Jobs parameter. | |||
Idle Procs criteria (min) | Specify the amount of time the process has not been consuming any resources before it is considered as an idle process. All the idle processes are reported by the Idle Procs parameter. | |||
Number of Blocking Processes criteria (min) | Specify the amount of time the process has been blocked by the blocking process before it is considered as a blocking process. All the blocker processes are reported by the Number of Blocking Processes parameter | |||
Advanced Configuration | ||||
Unique port number (per instance) | Enter a unique port number. | |||
KM administration | ||||
Availability collection interval (min) | Enter the availability collection interval in minutes. | |||
Data collection interval (min) | Enter the data collection interval in minutes. | |||
Device mapping | Select to enable device mapping to consolidate the configured devices at the device level. | |||
Logging | Select to enable debug logging for the environment. | |||
Generate detailed events (requires MRL) | Select the metrics to generate events containing the detailed annotation:
To enable showing these events in BMC Helix Operations Management, create the HelixMonitorEvents configuration variable (/AgentSetup/integration/HelixMonitorEvents) and assign its value as 1. | |||
Query timeout (sec) | Specify the number of seconds allowed for a query to complete before going into timeout. This time affects all queries executed by the KM to collect data. | |||
Global administration settings | ||||
Logging | Select to enable debug logging only at a global level |
Apply the MRL script
In order to support the event generation,SQLGenerateDetailedEvents.mrl script has to be applied on the TrueSight cell. To apply the script, do the following:
- Perform the following steps to download the SQLGenerateDetailedEvents.mrl script on the host where the cell is installed:
- Download the script or locate the script in the %PATROL_HOME%\mssql\configuration directory.
- Copy the SQLGenerateDetailedEvents.mrl script to the <TRUESIGHT_INSTALL_PATH>/pw/server/etc/pncell_<CELL_NAME>/kb/rules directory.
- Open the .load file present in the <TRUESIGHT_INSTALL_PATH>/pw/server/etc/pncell_<CELL_NAME>/kb/rules directory and include the script name without the extension in the file.
For example: Include SQLGenerateDetailedEvents in the .load file. Compile the script by running the following command:
mccomp -n pncell_<CELL_NAME>- Restart the respective cell service for the changes to take effect.