diff --git a/pgmon_templates.yaml b/pgmon_templates.yaml index 78eaf4c..c56d9a0 100644 --- a/pgmon_templates.yaml +++ b/pgmon_templates.yaml @@ -13,14 +13,14 @@ zabbix_export: items: - uuid: 818721b38324495a949cfe8c10a00eec name: 'Max Frozen XID Age' - key: 'pgmon[{#AGENT},{#CLUSTER},max_frozen_age]' + key: 'pgmon[{$AGENT_NAME},{$CLUSTER},max_frozen_age]' description: 'Maximum age of any frozen XID in any database' tags: - tag: Application value: PostgreSQL - uuid: e73d02840f4043288f5fe5cc8b7c997b name: 'PostgreSQL version' - key: 'pgmon[{#AGENT},{#CLUSTER},version]' + key: 'pgmon[{$AGENT_NAME},{$CLUSTER},version]' delay: 1h description: 'PostgreSQL Server version number' tags: @@ -29,7 +29,7 @@ zabbix_export: discovery_rules: - uuid: 35222acc25d34e008edd88f6b6ff7ad7 name: 'Discover Databases' - key: 'pgmon[{$AGENT_NAME},{$CLUSTER},discover_dbs,pos={$AGDNT_NAME}:{$CLUSTER}]' + key: 'pgmon[{$AGENT_NAME},{$CLUSTER},discover_dbs,pos={$AGENT_NAME}:{$CLUSTER}]' delay: 10m item_prototypes: - uuid: 4bd8ecf7677a4eed97409ed86d8d0e64 @@ -39,12 +39,18 @@ zabbix_export: trends: '0' value_type: TEXT tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 98efbb23589b4de6ae95ab61d08c78b0 name: 'Time spent executing statements on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[active_time,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},active_time,{#DBNAME}]' delay: '0' value_type: FLOAT units: s @@ -59,12 +65,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: c8e998f898b64af3b6452313d4bb8573 name: 'Number of backends on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[backends,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},backends,{#DBNAME}]' delay: '0' description: 'Number of backends currently connected to this database, or NULL for shared objects. This is the only column in this view that returns a value reflecting current state; all other columns return the accumulated values since the last reset.' preprocessing: @@ -74,12 +86,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 569ed1c8849747a9b5b90ff2d859ea89 name: 'Blocks hit on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[blks_hit,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},blks_hit,{#DBNAME}]' delay: '0' description: 'Number of times disk blocks were found already in the buffer cache, so that a read was not necessary (this only includes hits in the PostgreSQL buffer cache, not the operating system''s file system cache)' preprocessing: @@ -89,12 +107,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 88a3eebdf53b43c0b8b8ef60aba56116 name: 'Blocks read on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[blks_read,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},blks_read,{#DBNAME}]' delay: '0' description: 'Number of disk blocks read in this database' preprocessing: @@ -104,12 +128,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 05a62cf75aa34435bb8275d4b84875bb name: 'Time spent reading blocks on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[blk_read_time,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},blk_read_time,{#DBNAME}]' delay: '0' value_type: FLOAT units: s @@ -124,12 +154,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 51ae24232a3d484a9fe6bdc0edc5ec96 name: 'Time spent writing blocks on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[blk_write_time,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},blk_write_time,{#DBNAME}]' delay: '0' value_type: FLOAT units: s @@ -144,12 +180,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: bfae7ca4d10f497694b799d5abf15de8 name: 'Total number of checksum failures on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[checksum_failures,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},checksum_failures,{#DBNAME}]' delay: '0' description: 'Number of data page checksum failures detected in this database (or on a shared object), or NULL if data checksums are not enabled.' preprocessing: @@ -164,12 +206,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: eb72f62ae8b24c2688a9832ed5f51792 name: 'Total number of conflicts on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[conflicts,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},conflicts,{#DBNAME}]' delay: '0' description: 'Number of queries canceled due to conflicts with recovery in this database. (Conflicts occur only on standby servers; see pg_stat_database_conflicts for details.)' preprocessing: @@ -179,12 +227,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 5a039ddd9f27497a818e145bb912fe25 name: 'Total number of deadlocks on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[deadlocks,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},deadlocks,{#DBNAME}]' delay: '0' description: 'Number of deadlocks detected in this database' preprocessing: @@ -194,12 +248,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: f2d1c3c0540a4f2da0e48260b1ce556b name: 'Time spent in idle transactions on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[idle_in_transaction_time,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},idle_in_transaction_time,{#DBNAME}]' delay: '0' value_type: FLOAT units: s @@ -214,14 +274,19 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: f52b9b40acac43b8aa130c7c7ba7c55e name: 'Total number of sessions on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[sessions,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},sessions,{#DBNAME}]' delay: '0' - units: b description: 'Total number of sessions established to this database' preprocessing: - type: JSONPATH @@ -230,14 +295,19 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 7dfe2f7842e14967bf48fb73f90f5568 name: 'Total number of abandoned sessions on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[sessions_abandoned,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},sessions_abandoned,{#DBNAME}]' delay: '0' - units: b description: 'Number of database sessions to this database that were terminated because connection to the client was lost' preprocessing: - type: JSONPATH @@ -246,14 +316,19 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: e8bb24eba9c04d7b9bff05798d751f6f name: 'Total number of fatal sessions on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[sessions_fatal,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},sessions_fatal,{#DBNAME}]' delay: '0' - units: b description: 'Number of database sessions to this database that were terminated by fatal errors' preprocessing: - type: JSONPATH @@ -262,14 +337,19 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: aaf735d7125c494e9dfc504f3ebbc7e4 name: 'Total number of terminated sessions on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[sessions_killed,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},sessions_killed,{#DBNAME}]' delay: '0' - units: b description: 'Number of database sessions to this database that were terminated by operator intervention' preprocessing: - type: JSONPATH @@ -278,12 +358,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 58ede113f9ab46188239b5fa094107a2 name: 'Total temp file size on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[temp_bytes,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},temp_bytes,{#DBNAME}]' delay: '0' units: b description: 'Total amount of data written to temporary files by queries in this database. All temporary files are counted, regardless of why the temporary file was created, and regardless of the log_temp_files setting.' @@ -294,12 +380,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 3e837ab01d904d1fb10c50b843ffb25e name: 'Total number of temp files on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[temp_files,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},temp_files,{#DBNAME}]' delay: '0' description: 'Number of temporary files created by queries in this database. All temporary files are counted, regardless of why the temporary file was created (e.g., sorting or hashing), and regardless of the log_temp_files setting.' preprocessing: @@ -309,12 +401,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 5eade95d8a374122b2e5ab861c179918 name: 'Tuples deleted on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[tup_deleted,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},tup_deleted,{#DBNAME}]' delay: '0' description: 'Number of rows deleted by queries in this database' preprocessing: @@ -324,12 +422,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 40992ae903c64104ad719365575f7ac9 name: 'Tuples fetched by index scans on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[tup_fetched,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},tup_fetched,{#DBNAME}]' delay: '0' description: 'Number of live rows fetched by index scans in this database' preprocessing: @@ -339,12 +443,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 8f317cab436b429b8898643c9b36ab71 name: 'Tuples inserted on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[tup_inserted,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},tup_inserted,{#DBNAME}]' delay: '0' description: 'Number of rows inserted by queries in this database' preprocessing: @@ -354,12 +464,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: cb791a01a44840e8ad355411e3ce41be name: 'Tuples returned by sequential scans on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[tup_retruned,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},tup_returned,{#DBNAME}]' delay: '0' description: 'Number of live rows fetched by sequential scans and index entries returned by index scans in this database' preprocessing: @@ -369,12 +485,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: cc8da1b703c9424d8b08e55e61c3dd23 name: 'Tuples updated on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[tup_updated,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},tup_updated,{#DBNAME}]' delay: '0' description: 'Number of rows updated by queries in this database' preprocessing: @@ -384,12 +506,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: e0b4c77f621b49c590f1b73d3f6bbd8a name: 'Total number of commits on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[xact_commit,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},xact_commit,{#DBNAME}]' delay: '0' description: 'Number of transactions in this database that have been committed' preprocessing: @@ -399,12 +527,18 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 016eb3789cc84340bfeee252073317ac name: 'Total number of rollbacks on {#DBNAME}' type: DEPENDENT - key: 'pgmon_db[xact_rollback,{#DBNAME}]' + key: 'pgmon_db[{#AGENT},{#CLUSTER},xact_rollback,{#DBNAME}]' delay: '0' description: 'Number of transactions in this database that have been rolled back' preprocessing: @@ -414,61 +548,107 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},db_stats,datname={#DBNAME}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 3f2b24137fab474fbe3e7c66b82e68f0 name: 'Tuples fetched by index scans on {#DBNAME} - 1h delta' type: CALCULATED - key: 'pgmon_db_delta[tup_fetched,1h,{#DBNAME}]' + key: 'pgmon_db_delta[{#AGENT},{#CLUSTER},tup_fetched,1h,{#DBNAME}]' delay: 10m - params: 'last(//pgmon_db[tup_fetched,{#DBNAME}]) - last(//pgmon_db[tup_fetched,{#DBNAME}], #1:now-1h)' + params: 'last(//pgmon_db[{#AGENT},{#CLUSTER},tup_fetched,{#DBNAME}]) - last(//pgmon_db[{#AGENT},{#CLUSTER},tup_fetched,{#DBNAME}], #1:now-1h)' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 73bcb7f2272f4277ae64624f88a42d16 name: 'Tuples fetched by index scans on {#DBNAME} - 1m delta' type: CALCULATED - key: 'pgmon_db_delta[tup_fetched,1m,{#DBNAME}]' - params: 'last(//pgmon_db[tup_fetched,{#DBNAME}]) - last(//pgmon_db[tup_fetched,{#DBNAME}], #1:now-1m)' + key: 'pgmon_db_delta[{#AGENT},{#CLUSTER},tup_fetched,1m,{#DBNAME}]' + params: 'last(//pgmon_db[{#AGENT},{#CLUSTER},tup_fetched,{#DBNAME}]) - last(//pgmon_db[{#AGENT},{#CLUSTER},tup_fetched,{#DBNAME}], #1:now-1m)' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: be104f19788a40b98ddffa390448fb96 name: 'Tuples fetched by index scans on {#DBNAME} - 5m delta' type: CALCULATED - key: 'pgmon_db_delta[tup_fetched,5m,{#DBNAME}]' - params: 'last(//pgmon_db[tup_fetched,{#DBNAME}]) - last(//pgmon_db[tup_fetched,{#DBNAME}], #1:now-5m)' + key: 'pgmon_db_delta[{#AGENT},{#CLUSTER},tup_fetched,5m,{#DBNAME}]' + params: 'last(//pgmon_db[{#AGENT},{#CLUSTER},tup_fetched,{#DBNAME}]) - last(//pgmon_db[{#AGENT},{#CLUSTER},tup_fetched,{#DBNAME}], #1:now-5m)' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 9516e42e590e430e96d8df9d71e55fad name: 'Tuples returned by sequential scans on {#DBNAME} - 1h delta' type: CALCULATED - key: 'pgmon_db_delta[tup_returned,1h,{#DBNAME}]' + key: 'pgmon_db_delta[{#AGENT},{#CLUSTER},tup_returned,1h,{#DBNAME}]' delay: 10m - params: 'last(//pgmon_db[tup_returned,{#DBNAME}]) - last(//pgmon_db[tup_returned,{#DBNAME}], #1:now-1h)' + params: 'last(//pgmon_db[{#AGENT},{#CLUSTER},tup_returned,{#DBNAME}]) - last(//pgmon_db[{#AGENT},{#CLUSTER},tup_returned,{#DBNAME}], #1:now-1h)' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 4b361814e2e2414d8ee589f00330cc79 name: 'Tuples returned by sequential scans on {#DBNAME} - 1m delta' type: CALCULATED - key: 'pgmon_db_delta[tup_returned,1m,{#DBNAME}]' + key: 'pgmon_db_delta[{#AGENT},{#CLUSTER},tup_returned,1m,{#DBNAME}]' delay: 10m - params: 'last(//pgmon_db[tup_returned,{#DBNAME}]) - last(//pgmon_db[tup_returned,{#DBNAME}], #1:now-1m)' + params: 'last(//pgmon_db[{#AGENT},{#CLUSTER},tup_returned,{#DBNAME}]) - last(//pgmon_db[{#AGENT},{#CLUSTER},tup_returned,{#DBNAME}], #1:now-1m)' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 77204dc6d31e465eab99e780ea647a78 name: 'Tuples returned by sequential scans on {#DBNAME} - 5m delta' type: CALCULATED - key: 'pgmon_db_delta[tup_returned,5m,{#DBNAME}]' + key: 'pgmon_db_delta[{#AGENT},{#CLUSTER},tup_returned,5m,{#DBNAME}]' delay: 10m - params: 'last(//pgmon_db[tup_returned,{#DBNAME}]) - last(//pgmon_db[tup_returned,{#DBNAME}], #1:now-5m)' + params: 'last(//pgmon_db[{#AGENT},{#CLUSTER},tup_returned,{#DBNAME}]) - last(//pgmon_db[{#AGENT},{#CLUSTER},tup_returned,{#DBNAME}], #1:now-5m)' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' lld_macro_paths: + - lld_macro: '{#AGENT}' + path: $.agent + - lld_macro: '{#CLUSTER}' + path: $.cluster - lld_macro: '{#DBNAME}' path: $.datname - uuid: fd2db56cbc4d4ad38595d51a8f5c1d1b @@ -482,10 +662,17 @@ zabbix_export: history: '0' trends: '0' value_type: TEXT + tags: + - tag: Agent + value: '{#AGENT}' + - tag: Cluster + value: '{#CLUSTER}' + - tag: Database + value: '{#DBNAME}' - uuid: 333f6f3c7ae749d998ea3e679f52fee1 name: 'Flush lag for {#REPID}' type: DEPENDENT - key: 'pgmon_rep[flush_lag,repid={#REPID}]' + key: 'pgmon_rep[{#AGENT},{#CLUSTER},flush_lag,repid={#REPID}]' delay: '0' value_type: FLOAT description: 'Time elapsed between flushing recent WAL locally and receiving notification that this standby server has written and flushed it (but not yet applied it). This can be used to gauge the delay that synchronous_commit level on incurred while committing if this server was configured as a synchronous standby.' @@ -496,14 +683,20 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},rep_stats,repid={#REPID}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' - tag: Component value: Replication + - tag: Database + value: '{#DBNAME}' - uuid: 42303bb6d62c4288a19049352a0752d7 name: 'Last flush LSN for {#REPID}' type: DEPENDENT - key: 'pgmon_rep[flush_lsn,repid={#REPID}]' + key: 'pgmon_rep[{#AGENT},{#CLUSTER},flush_lsn,repid={#REPID}]' delay: '0' trends: '0' value_type: TEXT @@ -515,14 +708,20 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},rep_stats,repid={#REPID}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' - tag: Component value: Replication + - tag: Database + value: '{#DBNAME}' - uuid: 5838b1afd66e4063b793ee4b597e89fa name: 'Replay lag for {#REPID}' type: DEPENDENT - key: 'pgmon_rep[replay_lag,repid={#REPID}]' + key: 'pgmon_rep[{#AGENT},{#CLUSTER},replay_lag,repid={#REPID}]' delay: '0' value_type: FLOAT description: 'Time elapsed between flushing recent WAL locally and receiving notification that this standby server has written, flushed and applied it. This can be used to gauge the delay that synchronous_commit level remote_apply incurred while committing if this server was configured as a synchronous standby.' @@ -533,14 +732,20 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},rep_stats,repid={#REPID}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' - tag: Component value: Replication + - tag: Database + value: '{#DBNAME}' - uuid: 9fdd3add95b04e65ba4e14f1fa2af864 name: 'Last replay LSN for {#REPID}' type: DEPENDENT - key: 'pgmon_rep[replay_lsn,repid={#REPID}]' + key: 'pgmon_rep[{#AGENT},{#CLUSTER},replay_lsn,repid={#REPID}]' delay: '0' trends: '0' value_type: TEXT @@ -552,14 +757,20 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},rep_stats,repid={#REPID}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' - tag: Component value: Replication + - tag: Database + value: '{#DBNAME}' - uuid: 2c8088ff43c548e2b30511468a0446aa name: 'Last sent LSN for {#REPID}' type: DEPENDENT - key: 'pgmon_rep[sent_lsn,repid={#REPID}]' + key: 'pgmon_rep[{#AGENT},{#CLUSTER},sent_lsn,repid={#REPID}]' delay: '0' trends: '0' value_type: TEXT @@ -571,14 +782,20 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},rep_stats,repid={#REPID}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' - tag: Component value: Replication + - tag: Database + value: '{#DBNAME}' - uuid: 1f3371bfd3d84af8aca6080024dc14aa name: 'Replication state for {#REPID}' type: DEPENDENT - key: 'pgmon_rep[state,repid={#REPID}]' + key: 'pgmon_rep[{#AGENT},{#CLUSTER},state,repid={#REPID}]' delay: '0' trends: '0' value_type: TEXT @@ -596,14 +813,20 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},rep_stats,repid={#REPID}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' - tag: Component value: Replication + - tag: Database + value: '{#DBNAME}' - uuid: 69bfddf63bba4740a3ddc1d729eac0f4 name: 'Write lag for {#REPID}' type: DEPENDENT - key: 'pgmon_rep[write_lag,repid={#REPID}]' + key: 'pgmon_rep[{#AGENT},{#CLUSTER},write_lag,repid={#REPID}]' delay: '0' value_type: FLOAT description: 'Time elapsed between flushing recent WAL locally and receiving notification that this standby server has written it (but not yet flushed it or applied it). This can be used to gauge the delay that synchronous_commit level remote_write incurred while committing if this server was configured as a synchronous standby.' @@ -614,14 +837,20 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},rep_stats,repid={#REPID}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' - tag: Component value: Replication + - tag: Database + value: '{#DBNAME}' - uuid: 53185c929b8c430e854d7ffb28a9ce8f name: 'Last write LSN for {#REPID}' type: DEPENDENT - key: 'pgmon_rep[write_lsn,repid={#REPID}]' + key: 'pgmon_rep[{#AGENT},{#CLUSTER},write_lsn,repid={#REPID}]' delay: '0' trends: '0' value_type: TEXT @@ -633,13 +862,23 @@ zabbix_export: master_item: key: 'pgmon[{#AGENT},{#CLUSTER},rep_stats,repid={#REPID}]' tags: + - tag: Agent + value: '{#AGENT}' - tag: Application value: PostgreSQL + - tag: Cluster + value: '{#CLUSTER}' - tag: Component value: Replication + - tag: Database + value: '{#DBNAME}' lld_macro_paths: + - lld_macro: '{#AGENT}' + path: $.agent - lld_macro: '{#CLIENT_ADDR}' path: $.client_addr + - lld_macro: '{#CLUSTER}' + path: $.cluster - lld_macro: '{#REPID}' path: $.repid - lld_macro: '{#STATE}'