Database space check
Job details
Name: | Database space check |
Platform: | Sybase |
Category: | Capacity |
Description: | Checks the amount of free space in all databases. |
Long description: | |
Version: | 2.1 |
Default schedule: | 10 5,17 * * |
Requires engine install: | Yes |
Compatibility tag: | .[type=‘instance’ & databasetype=‘sybase’]/instance[maj_version > ‘14′ & hasengine=‘YES’] |
Parameters
Name | Default value | Description |
---|---|---|
ignore databases | Names of databases which will be ignored (comma separated list). | |
min. free space (MB) | 2000 | No warning or alarm will be triggered if the amount of free space in a device fragment is higher then this value. |
warning threshold pct. | 95 | The check will give a warning when the amount of free space in a device fragment is lower then the parameter value “min. free space (MB)”, and the percentage of used space exceeds the threshold value “warning threshold pct.”. |
alarm threshold pct. | 97 | The check will give an alarm when the amount of free space in a device fragment is lower then the parameter value “min. free space (MB)”, and the percentage of used space exceeds the threshold value “alarm threshold pct.”. |
Job Summary
- Purpose: The purpose of this job is to monitor and manage database space utilization effectively across all databases within a monitored instance that adhere to specific criteria, such as those running on Sybase and meeting version and engine requirements.
- Why: This job is important to ensure that database space usage does not exceed critical thresholds which can lead to performance degradations or system outages, especially in databases with high transaction volumes or large data storage requirements. It helps in proactive administration by alerting on thresholds reaching warning or alarm levels.
- Manual checking: You can check this manually in the database by issuing the following SQL command:
EXEC dbw_database_space_check;
Detailed Description
This dbWatch Control Center monitoring job, specifically designed for Sybase instances with version greater than 14 that have an engine, performs detailed checks on database space usage. The job:
- Checks the amount of free space in all the databases.
- Provides visual and data representations through reports regarding space utilization across segments and device fragments.
- Flags databases as it reaches defined threshold levels for proactive alerts to prevent potential outages or performance hits.
Parameters Definition Overview
- Ignores specified databases from the check.
- Sets minimum free space in MB to prevent raising unnecessary alarms.
- Sets thresholds for warnings and alarms based on percentage usage.
Implementation Logic
The procedure involves creating several temporary tables and procedures to accumulate space usage details across different database segments and device fragments. Specific actions within the procedure include:
- Filtering out ignored databases.
- Calculating space usage while considering different types of database segments.
- Providing detailed logs on space utilization specifics for administrative review.
Dependencies and Cleanup
The job depends on the existence and creation of specific tables and stored procedures which help in generating detailed space utilization statistics:
- dbw_database_space_check
- dbw_db_space_usage
- dbw_db_segm_space_usage
- dbw_db_logspace_usage
- dbw_db_segm_space_usage_dtl
- dbw_db_segm_ids
Upon failure, the cleanup process involves dropping these stored procedures and tables to ensure there are no remnants from failed executions.
Reporting and Alerts
The job is designed to provide extensive reporting capabilities, which are configurable and could include:
- Tables showing current space usage by database and by segment.
- Charts illustrating the percentage of space used.
- Critical alerts that can be configured to trigger notifications for database admins when space usage reaches specified limits.
This job ensures a robust monitoring mechanism is in place to help database administrators manage space effectively and mitigate risks associated with space exhaustion.