Tablespace growth and information


Job details

Name: Tablespace growth and information
Platform: Postgres
Category: Capacity
Description: Shows an overview of tablespace growth and statistics.
Long description: Shows an overview of tablespace growth and statistics.
Version: 1.4
Default schedule: 10 18 * *
Requires engine install: Yes
Compatibility tag: .[type=‘instance’ & databasetype=‘postgres’]/.[hasengine=‘YES’]

Parameters

Name Default value Description
ignore tablespace Tablespaces you do not want to list in report.
keep data for 7 The number of days to keep the data for.

Job Summary

select spcname as "Tablespace name", round(pg_tablespace_size(spcname)/1024.0/1024.0, 1) as "Tablespace size in MB" from pg_tablespace

Job Details and Functions

Dependencies

Object Object Type Description Cleanup on Fail
dbw_tablespace_growth_rate(taskId int) 2 Function that calculates growth rate true
dbw_tablespace_growth_histr 0 Historical growth data table true
dbw_tablespace_growth_ignore_list 0 List of tablespaces to ignore in reports true

Report Template and Structure

Presentations:

  1. “Tablespace growth and information”: This visualization shows the tablespaces names and their total size measured at different dates.
  2. “Daily tablespace growth last month”: This plot charts the change in size of tablespaces, broken down by day over the past month.
  3. “Current tablespace size”: Simple tabular presentation showing the current size of each tablespace.

Database Queries and Operations

Additional Information

By offering vital insights through systematic tracking and structured reporting, this job serves as an integral part of maintaining the health and performance of the PostgreSQL database environment.