Aborted clients
Job details
Name: |
Aborted clients |
Platform: |
Mariadb |
Category: |
Availability |
Description: |
Checks the number of clients not closing the connection properly. |
Long description: |
Checks the number of clients not closing the connection properly. |
Version: |
1.1 |
Default schedule: |
12,42 * * * |
Requires engine install: |
Yes |
Compatibility tag: |
.[type=‘instance’ & is_mariadb_branch=‘1′]/.[hasengine=‘YES’ & use_global_variables_information_schema = ‘1′ ] |
Parameters
Name |
Default value |
Description |
warning threshold |
50 |
The maximum value of aborted clients (over a period of time defined by the [time threshold] parameter) before a warning is triggered. |
alarm threshold |
500 |
The maximum value of aborted clients (over a period of time defined by the [time threshold] parameter) before an alarm is triggered. |
threshold (time) |
120 |
A period of time (in minutes) which must be passed (combined with the number of aborted clients) before an alarm or a warning is returned by the procedure. |
enable warnings and alarms |
NO |
If set to “NO” (default), the alert will only collect statistics without returning status warning or alarm. Value “YES“ will activate the alert. |
history threshold |
7 |
The maximum number of day to kept statistics for in the historic tables. |
Job Summary
- Purpose: This monitoring job is designed to track the number of aborted MariaDB clients – clients that have not properly closed their connection to the server.
- Why: Monitoring aborted connections is critical for maintaining database stability and performance. Excessive aborted connections can indicate issues with client applications, network problems, or server overloads, which might adversely affect database health.
- Manual checking: To manually check the number of aborted clients, execute the following SQL command:
SELECT VARIABLE_VALUE AS aborted_clients FROM information_schema.global_status WHERE variable_name = 'Aborted_clients';
Job Details
- Description: The job periodically checks the number of aborted clients and logs differences between current and last recorded values.
- Implementation:
- Database tables for historical data and the last known value are created.
- A stored procedure is used to manage checks and captures the number of aborted clients, storing results in the database for trend analysis.
- There are conditions to trigger warnings or alarms based on predefined thresholds, only if alerts are enabled.
Output & Reporting
- Reporting: The job provides a visual report showing the trend of aborted connections over time.
- Visuals: The generated graphs will display aborted client counts against time, plotted from historical data, allowing DBAs to assess spikes or unusual patterns of dropped connections.
Dependency & Cleanup
- Dependencies: There are a few dependencies like the main procedure and supporting tables which are crucial for the operation of this job.
- Cleanup on fail: In an error state, the job will clean up by dropping the helper tables and procedures to prevent any corrupted or partial data retention.
Key Parameters (without detailed descriptions)
Parameter |
Default Value |
Warning Threshold |
50 |
Alarm Threshold |
500 |
Time Threshold |
120 |
Enable Warnings and Alarms |
NO |
History Threshold |
7 |
Updates and Adjustments
- Error handling: The procedure includes detailed error handling mechanisms that log any SQL exceptions, providing critical diagnostics at every step.
- Parameter Adjustments: Parameters are configurable, allowing tuning based on specific database environment or behavior patterns observed from the reports.
Execution
- Scheduled Execution: This job executes at regular intervals defined by the `default-schedule`.
- Automation: This task is highly automated, minimizing the need for manual intervention and ensuring continuous monitoring of database client connections.
This informational system, through careful monitoring and reporting, aids in maintaining optimal database operations, ensuring reliability and performance in client-server interactions.