PostgreSQL Database

Available Metrics

Possible metric types that can be tracked on a given resource.

Metric Type Data Type Description
AggregatedMetric
Object
Allows for aggregating existing metrics over a period of time. Useful for running sums or averages; also for extracting single data item from collection-based metrics
DatabaseActiveSessionCount
Double
Tracks the number of open sessions for the given database.
DatabasePostgreSqlBlockingQueries
PostgreSqlBlockingQuery[]
LockedItem String
WaitingDuration TimeSpan
BlockedPid Int32
BlockedQuery String
BlockedQueryStart DateTime
BlockedUser String
BlockedMode String
BlockingPid Int32
BlockingQuery String
BlockingUser String
BlockingMode String
Tracks queries that are currently blocking each other.
DatabasePostgreSqlCacheHitRatio
Double
Tracks cache hit rate ratio. Cache hit ratio should be over 99%.
DatabasePostgreSqlDatabaseUtilization
Double
Tracks various database statistics such as read/write blocks, usage metrics, etc.
DatabasePostgreSqlIndexHitRatio
Double
Tracks index hit rate ratio. Index hit rate ratio should be over 99%.
DatabasePostgreSqlIndexUsage
PostgreSqlIndexUsage[]
SchemaName String
TableName String
RowCount Int64
IndexUsagePct Decimal
Tracks index usage for tables. Tracks top 10 tables sorted by row count.
DatabasePostgreSqlIndexUsageByTable
Double
Tracks index usage for the specified table.
DatabasePostgreSqlTableUsage
PostgreSqlTableUsage[]
SchemaName String
TableName String
TableSizeInMB Decimal
Tracks data size usage top 10 biggest tables.
DatabasePostgreSqlTableUsageByTable
Double
Tracks data size for the specified table.
DatabasePostgreSqlTransactionCommittedRatio
Double
Tracks a ratio of the number of committed transactions vs. all transactions.
DatabaseSize
Double
Tracks the size of the database in megabytes.
DatabaseSqlBlockingQueryCount
Int32
Tracks the number of deadlocking queries.
DatabaseSqlNumeric
Double
Tracks numeric value from custom user-defined SQL statement.
DatabaseSqlQuery
Object[]
Tracks a table-based collection of data retrieved via user-defined SQL statement.
DerivedMetric
Double
Allows for deriving new metrics from existing ones. Useful for combining existing metrics together or for multiplying metrics by a factor
LinkedMetric
Object
Allows for tracking of metrics from other resources. Useful when it is important to evaluate metrics from different resources side-by-side
ResourceStatus
String
Tracks overall status of the resource. This is an important metric as it is used to drive Uptime reports. Possible values: Ready, Down, Unknown and in some cases Stopped
ResponseTime
Double
Measures time to connect to resource

Available Commands

Possible commands that can be executed on a given resource. Ultimate subscription is required.

Command Type Description
CustomSqlDatabaseScript Runs custom SQL script on specified database
WebRequest Runs custom WebRequest to specified URL

Default Templates

CloudMonix provided default monitoring templates.

Pre-configured Metrics

Metric Name Metric Type Description
BlockingQueries DatabasePostgreSqlBlockingQueries Tracks queries that are blocking each other
BlockingQueryCount DatabaseSqlBlockingQueryCount Tracks number of currently blocking (possibly dead-locking) queries
CacheHitRatio DatabasePostgreSqlCacheHitRatio Tracks cache hit rate ratio for database.
ConnectionsActive DatabaseActiveSessionCount Tracks number of open connections to the database
IndexHitRatio DatabasePostgreSqlIndexHitRatio Tracks index hit rate ratio for database.
IndexUsage DatabasePostgreSqlIndexUsage Tracks index usage for top 10 tables sorted by row count
ResponseTime ResponseTime Tracks resource's response time. Metric measures how long it took to open an active connection to PostgreSql database in milliseconds
Size DatabaseSize Tracks database size in MBs
Status ResourceStatus Tracks the overall readiness status of the monitored resource. Possible values are: Ready, Down, Stopped and Unknown
TableUsage DatabasePostgreSqlTableUsage Disabled by default. Tracks disk capacity for top 10 tables sorted by table size (metric disabled by default because it can add load to the database).
TransactionCommitedRatio DatabasePostgreSqlTransactionCommittedRatio Tracks a ratio of the number of committed transactions versus all transactions for database

Pre-configured Alerts

Alert Name Expression Severity Description
Database Approaching Max Size Size > 9999 Warning Disabled by default. Fires an alert when the size of the database approaches maximum limit.
Open Sessions Approaching Max Limit ConnectionsActive > 99 Warning Disabled by default. Number of open connections (sesssions) is approaching maximum limit.
Resource Outage Status == "Down" Error Raises an alert when connectivity cannot be established, after specified number of retries on the Advanced tab for sustained period of time
Slow Response ResponseTime > 15000 Warning Raises an alert if establishing a connection to monitored resource takes over 15 seconds for sustained period of time