Database size
Home > Select Project > Stat/Report > DB size
It aggregates the sizes of tables for each database and provides trend data in a chart. You can identify and manage the trend in database capacity growth. You can prepare for rapid capacity increases by identifying them in advance.
Database size can affect the performance. You can prepare to troubleshoot performance issues because the increase in size can delay the query execution. It is also required to identify and prevent problems in advance that may increase the size due to incorrect queries or database structure issues.
The trend in database size helps you understand usage patterns and data growth. You can predict future capacity requirements and take possible actions. Monitoring these changes helps you optimize the resources and costs.
The total database size is queried with the pg_database_size
function, and the monitoring account must have the connect or pg_read_all_stats
role. template database
is excluded from collection.
Individual table sizes can be queried with the pg_relation_size
, pg_indexes_size
, and pg_total_relation_size
functions, and the query role for the corresponding schema is required.
grant pg_read_all_stats to whatap;
grant usage on schema {schema_name} to whatap;
-
The sizes for the
pg_catalog
,sys
,information_schema
, andpg_toast
schemata are not collected. -
The collection cycle is collected once every hour.
Basic screen guide
-
Set the time to search in Time. You can also select a lookup time by clicking the green button.
-
Select a target to view in Instance.
-
Select .
-
The lookup time can be set up to 62 days. In case of a view for 3 days or more, the graph displays the daily average.
-
Select the clock display area to query a random date and time. If you click the text range for date and time, the option appears to select the date and time.
Checking the changes over time
If you select the graph bar at a specific time in Size trend, you can see the database size trend and change amounts from the start time to the selected time in a list.
Checking the sizes for each table
If you select a database in Size details, you can see the list of sizes for each table in the top 50.
It displays DATA SIZE and INDEX SIZE for each table. In the table list of the Table size (TOP 50) section, select the TABLENAME column. Then the Object detail window appears for columns and index items.
This function is supported in DBX agent 1.6.15 or later. For more information about the database roles and related settings, see the following.
Downloading the viewed data
You can download the searched data as a CSV format file. Select and then select Size details or Table size (TOP 50).