Table and index scan statistics


Job details

Name: Table and index scan statistics
Platform: Postgres
Category: Performance
Description: This task gathers scan statistics on tables and indexes from pg_stat_all_tables view.
Long description: Statistics from pg_stat_all_tables view are gathered for the following columns:
Version: 1.8
Default schedule: 15,45 * * *
Requires engine install: Yes
Compatibility tag: .[type=‘instance’ & databasetype=‘postgres’]/.[hasengine=‘YES’ & newer_than_ninetwo = ‘1′]

Parameters

Name Default value Description
keep data for 7 The number of days to keep the data for.
ignore databases List of databases (separated by comma) which will be ignored.

Job Summary

SELECT * FROM pg_stat_all_tables;

Job Details

Scans monitored include:

Implementation Details

A series of operations involving the creation and maintenance of historical statistics tables and the function `dbw_scan_stat_func` which calculates differences between current and previous statistics records:

Dependencies

Reporting and Statistics

Key Presentations Include:

Each report includes detailed statistics concerning scan counts and fetched rows, ordered by the highest activity.

Execution Notes

This monitoring job highlighted above is crucial for proactive database performance monitoring and tuning to ensure efficient data handling within a PostgreSQL environment.