Users of Selectel Managed Databases can get information about the load on the cluster servers and working with databases. All data are presented in the form of graphs. The graphs can be viewed on the Monitoring tab on the cluster page.
Cluster Servers Watchers
The graph shows the percentage of the cluster server cores loaded.
The graph shows the average system load over a period of time. Load average shows the number of processes which are being executed by the cluster cores. The graph shows the indicator displayed as three values: for 1 minute, for 5 minutes, and for 15 minutes.
The graph shows the taken memory without regard of the cache and OS buffers.
The graph shows the used disk space.
Cluster Databases Watchers
Each line of the graph shows the number of connections to a particular cluster database. The graph also shows the total number of connections to all cluster databases.
Longest Query Execution Time
The graph shows the execution time of the longest query for the period.
The graph shows the number of transactions per one second for each cluster database.
The graph shows the number of operations on all databases per one second. It shows the following types of operations:
- tup_returned – number of rows returned by queries in this database per one second;
- tup_fetched – number of rows fetched by queries in this database per one second;
- tup_inserted – number of rows inserted by queries in this database per one second;
- tup_updated – number of rows updated by queries in this database per one second;
- tup_deleted – number of rows deleted by queries in this database per one second.
The graph shows the percentage of the data read from the cache in the request (the ratio of
blks_hit to the sum of
The graph shows the number of locks for each cluster database.
The graph shows the number of deadlocks recorded in each database.
Disk Fullness Notifications
If the cluster’s status has changed to DISK_FULL, then you can clean up the disk by opening a transaction with
transaction_read_only = no and deleting unnecessary data.
Please note that a statement like
DELETE FROM table WHERE ... in large tables can create large selections and place them on the disk. In this case, the disk may run out of space, which will lead to problems with PostgreSQL, and you’ll have to restore it manually. We do not recommend using
DELETE FROM to clean up the disk.
The first way to clean up the disk is to use
BEGIN; SET transaction_read_only = no; DROP TABLE some_unused_table; COMMIT;
The second way is to use
BEGIN; SET transaction_read_only = no; TRUNCATE TABLE some_unused_table; COMMIT;
TRUNCATE TABLE is faster than the first command but deletes records from a table without removing table structure.
DROP TABLE removes the table structure (data, privileges, indexes, constraints, and triggers).
TRUNCATE TABLE is best for removing all rows from a table and leaves the table structure — it’s faster than
DROP TABLE is best for removing an entire table, including its structure and data — it’s faster than
DELETE is used to remove specific rows.