ltcenter — ltcenter is a command-line admin tool for observing and troubleshooting LightDB
LightDB provides various activity statistics about its runtime, such as connections, statements, database operations, replication, resources usage and more. The general purpose of the statistics is to help DBAs to monitor and troubleshoot LightDB. However, these statistics provided in textual form retrieved from SQL functions and views, and LightDB doesn't provide native tools for working with statistics views.
ltcenter's main goal is to help LightDB DBA working with statistics and provide a convenient way to observe LightDB in runtime.
Top-like interface that allows you to monitor stats changes as you go.
Configuration management function allows viewing and editing of current configuration files and reloading the service, if needed.
Logfiles functions allow you to quickly check LightDB logs without stopping statistics monitoring.
"Poor man’s monitoring" allows you to collect LightDB statistics into files and build reports later on.
Wait events profiler allows seeing what wait events occur during queries execution.
summary activity - a compilation/selection of metrics from different sources - LightDB uptime, version, recovery status, number of clients grouped by their states, number of (auto)vacuums, statements per second, age of the longest transaction and the longest vacuum;
pg_stat_activity - activity of connected clients and background processes.
pg_stat_database - database-wide and sessions statistics, such as number of commits/rollbacks, processed tuples, deadlocks, temporary files, etc.
pg_stat_replication - replication statistics, like connected standbys, their activity and replication lag.
pg_stat_user_tables, pg_statio_user_tables - statistics on accesses (including IO) to tables.
pg_stat_user_indexes, pg_statio_user_indexes - statistics on accesses (including IO) to indexes.
pg_stat_user_functions - statistics on execution of functions.
pg_stat_wal - WAL usage statistics.
lt_stat_statements - statistics on SQL statements executed including time and resources usage.
statistics on tables sizes based on pg_relation_size()
and pg_total_relation_size()
functions;
pg_stat_progress_vacuum - progress of (auto)vacuums operations.
pg_stat_progress_cluster - progress of CLUSTER and VACUUM FULL operations.
pg_stat_progress_create_index - progress of CREATE INDEX and REINDEX operations.
pg_stat_progress_analyze - progress of ANALYZE operations.
pg_stat_progress_basebackup - progress of basebackup operations.
pg_stat_progress_copy - progress of COPY operations.
ltcenter top
also provides system usage information based
on statistics from procfs
filesystem:
load average and CPU usage time (user, system, nice, idle, iowait, software, and hardware interrupts, steal);
memory and swap usage, amount of cached and dirty memory, writeback activity;
storage devices statistics: IOPS, throughput, latencies, average queue and requests size, devices utilization;
network interfaces statistics: throughput in bytes and packets, different kind of errors, saturation and utilization.
mounted filesystems' usage statistics: total size, amount of free/used/reserved space and inodes.
In the case of connecting to remote LightDB, there is possibility to use additional SQL functions used for
retrieving /proc
statistics from a remote host.