From 881c8de6258c6299e4523b030abc35049319f819 Mon Sep 17 00:00:00 2001 From: "Dustin C. Hatch" Date: Sat, 30 Oct 2021 16:38:19 -0500 Subject: [PATCH] Switch Prometheus/collectd to pull Transitioning from push-based to pull-based monitoring with Prometheus/collectd. The *write_prometheus* plugin will be installed on all hosts, and Prometheus will be configured to scrape them directly. --- collectd.yml | 2 +- group_vars/collectd.yml | 1 + group_vars/prometheus.yml | 5 ----- host_vars/vmhost0.pyrocufflink.blue.yml | 3 --- host_vars/vmhost1.pyrocufflink.blue.yml | 3 --- hosts | 3 +++ 6 files changed, 5 insertions(+), 12 deletions(-) create mode 100644 group_vars/collectd.yml diff --git a/collectd.yml b/collectd.yml index 9645099..1ce7e41 100644 --- a/collectd.yml +++ b/collectd.yml @@ -4,7 +4,7 @@ tags: - collectd -- hosts: prometheus +- hosts: collectd-prometheus roles: - role: collectd-prometheus tags: diff --git a/group_vars/collectd.yml b/group_vars/collectd.yml new file mode 100644 index 0000000..23af0d4 --- /dev/null +++ b/group_vars/collectd.yml @@ -0,0 +1 @@ +collectd_prometheus_allow_outside: true diff --git a/group_vars/prometheus.yml b/group_vars/prometheus.yml index 9044668..e69de29 100644 --- a/group_vars/prometheus.yml +++ b/group_vars/prometheus.yml @@ -1,5 +0,0 @@ -collectd_network_servers: [] -collectd_network_listen: -- '::' -- ff18::efc0:4a42 -collectd_prometheus_host: '::1' diff --git a/host_vars/vmhost0.pyrocufflink.blue.yml b/host_vars/vmhost0.pyrocufflink.blue.yml index 0c42e2c..43b4e18 100644 --- a/host_vars/vmhost0.pyrocufflink.blue.yml +++ b/host_vars/vmhost0.pyrocufflink.blue.yml @@ -45,6 +45,3 @@ networkd_networks: samba_interfaces: - enp5s0 -collectd_network_servers: -- host: ff18::efc0:4a42 - interface: enp5s0 diff --git a/host_vars/vmhost1.pyrocufflink.blue.yml b/host_vars/vmhost1.pyrocufflink.blue.yml index 97c7f72..e2885fe 100644 --- a/host_vars/vmhost1.pyrocufflink.blue.yml +++ b/host_vars/vmhost1.pyrocufflink.blue.yml @@ -10,6 +10,3 @@ dhcpcd_interfaces: storage_iface: bond1 samba_interfaces: - enp5s0 -collectd_network_servers: -- host: ff18::efc0:4a42 - interface: enp5s0 diff --git a/hosts b/hosts index 056c29b..f8d98dd 100644 --- a/hosts +++ b/hosts @@ -20,6 +20,9 @@ burp1.pyrocufflink.blue [collectd:children] pyrocufflink +[collectd-prometheus:children] +collectd + [dch-proxy] [dch-vpn]