Add Prometheus Mysqld exporter
Change-Id: I670597179b701aab1ca8e433be2f3abf1e78650a
This commit is contained in:
2 changed files with 40 additions and 0 deletions
@@ -34,3 +34,26 @@ Install node_exporter
cd /opt/openstack-ansible-ops/prometheus
openstack-ansible installNodeExporter.yml
If you want to deploy the mysqld_exporter, you need to create the Galera user for it first
.. code-block:: yaml
galera_additional_users:
- name:"exporter"
host:'%'
password:"{{ prometheus_mysqld_exporter_galera_password }}"
priv:'*.*:PROCESS,REPLICATION CLIENT,SELECT,SLAVE MONITOR'
resource_limits:
MAX_USER_CONNECTIONS:3
check_hostname:false
state:present
Then install the mysqld_exporter
.. code-block:: bash
cd /opt/openstack-ansible-ops/prometheus
openstack-ansible installMysqldExporter.yml
17
prometheus/installMysqldExporter.yml
Normal file
17
prometheus/installMysqldExporter.yml
Normal file
@@ -0,0 +1,17 @@
---
- name:Refresh local facts
hosts:galera_all
tasks:
- name:refresh local facts
setup:
- name:mysqld_exporter
hosts:galera_all
roles:
- role:prometheus.prometheus.mysqld_exporter
vars:
mysqld_exporter_host:"{{ ansible_host }}"
mysqld_exporter_password:"{{ prometheus_mysqld_exporter_galera_password }}"
mysqld_exporter_web_listen_address:"{{ ansible_host }}:9104"
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.