Merge branch 'bjk/update_prom_versions' into 'master'
Update Prometheus components See merge request gitlab-org/omnibus-gitlab!1968
This commit is contained in:
commit
1f847e9e96
|
@ -19,7 +19,7 @@
|
|||
require "#{Omnibus::Config.project_root}/lib/gitlab/version"
|
||||
|
||||
name 'postgres-exporter'
|
||||
version = Gitlab::Version.new('postgres-exporter', '0.1.2')
|
||||
version = Gitlab::Version.new('postgres-exporter', '0.2.3')
|
||||
default_version version.print
|
||||
|
||||
license 'Apache-2.0'
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
require "#{Omnibus::Config.project_root}/lib/gitlab/version"
|
||||
|
||||
name 'prometheus'
|
||||
version = Gitlab::Version.new('prometheus', '1.6.3')
|
||||
version = Gitlab::Version.new('prometheus', '1.7.2')
|
||||
default_version version.print
|
||||
|
||||
license 'APACHE-2.0'
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
require "#{Omnibus::Config.project_root}/lib/gitlab/version"
|
||||
|
||||
name 'redis-exporter'
|
||||
version = Gitlab::Version.new('redis-exporter', '0.10.9.1')
|
||||
version = Gitlab::Version.new('redis-exporter', '0.12.2')
|
||||
default_version version.print
|
||||
|
||||
license 'MIT'
|
||||
|
|
|
@ -53,6 +53,7 @@ template File.join(postgres_exporter_dir, 'queries.yaml') do
|
|||
source 'postgres-queries.yaml'
|
||||
owner postgresql_user
|
||||
mode '0644'
|
||||
notifies :restart, 'service[postgres-exporter]'
|
||||
end
|
||||
|
||||
if node['gitlab']['bootstrap']['enable']
|
||||
|
|
|
@ -1,9 +1,12 @@
|
|||
pg_replication:
|
||||
query: "SELECT EXTRACT(EPOCH FROM (now() - pg_last_xact_replay_timestamp()))::INT as lag"
|
||||
query: "SELECT EXTRACT(EPOCH FROM (now() - pg_last_xact_replay_timestamp()))::INT as lag, CASE WHEN pg_is_in_recovery() THEN 1 ELSE 0 END as is_replica"
|
||||
metrics:
|
||||
- lag:
|
||||
usage: "GAUGE"
|
||||
description: "Replication lag behind master in seconds"
|
||||
- is_replica:
|
||||
usage: "GAUGE"
|
||||
description: "Indicates if this host is a slave"
|
||||
|
||||
pg_postmaster:
|
||||
query: "SELECT pg_postmaster_start_time as start_time_seconds from pg_postmaster_start_time()"
|
||||
|
@ -12,26 +15,6 @@ pg_postmaster:
|
|||
usage: "GAUGE"
|
||||
description: "Time at which postmaster started"
|
||||
|
||||
pg_settings_shared_buffers:
|
||||
query: "SELECT 8192*setting::bigint as bytes from pg_settings where name = 'shared_buffers'"
|
||||
metrics:
|
||||
- bytes:
|
||||
usage: "GAUGE"
|
||||
description: "Size of shared_buffers"
|
||||
|
||||
pg_settings_checkpoint:
|
||||
query: "select (select setting::int from pg_settings where name = 'checkpoint_segments') as segments, (select setting::int from pg_settings where name = 'checkpoint_timeout') as timeout_seconds, (select setting::float from pg_settings where name = 'checkpoint_completion_target') as completion_target"
|
||||
metrics:
|
||||
- segments:
|
||||
usage: "GAUGE"
|
||||
description: "Number of checkpoint segments"
|
||||
- timeout_seconds:
|
||||
usage: "GAUGE"
|
||||
description: "Checkpoint timeout in seconds"
|
||||
- completion_target:
|
||||
usage: "GAUGE"
|
||||
description: "Checkpoint completion target, ranging from 0 to 1"
|
||||
|
||||
pg_stat_user_tables:
|
||||
query: "SELECT schemaname, relname, seq_scan, seq_tup_read, idx_scan, idx_tup_fetch, n_tup_ins, n_tup_upd, n_tup_del, n_tup_hot_upd, n_live_tup, n_dead_tup, n_mod_since_analyze, last_vacuum, last_autovacuum, last_analyze, last_autoanalyze, vacuum_count, autovacuum_count, analyze_count, autoanalyze_count FROM pg_stat_user_tables"
|
||||
metrics:
|
||||
|
@ -99,6 +82,24 @@ pg_stat_user_tables:
|
|||
usage: "COUNTER"
|
||||
description: "Number of times this table has been analyzed by the autovacuum daemon"
|
||||
|
||||
pg_total_relation_size:
|
||||
query: |
|
||||
SELECT relnamespace::regnamespace as schemaname,
|
||||
relname as relname,
|
||||
pg_total_relation_size(oid) bytes
|
||||
FROM pg_class
|
||||
WHERE relkind = 'r';
|
||||
metrics:
|
||||
- schemaname:
|
||||
usage: "LABEL"
|
||||
description: "Name of the schema that this table is in"
|
||||
- relname:
|
||||
usage: "LABEL"
|
||||
description: "Name of this table"
|
||||
- bytes:
|
||||
usage: "GAUGE"
|
||||
description: "total disk space usage for the specified table and associated indexes"
|
||||
|
||||
pg_blocked:
|
||||
query: |
|
||||
SELECT
|
||||
|
|
Loading…
Reference in New Issue