harloprillar.pmm2_client

Ansible Role: pmm2_client

Build Status

This Ansible role installs and sets up the Percona Monitoring and Management (PMM) client, version 2. At this time, it only works with MySQL client services. If you are using MySQL version 8.0 or higher, configuration variables can be saved automatically. For earlier versions, you need to manually add options to your server configuration file. More details can be found in the documentation.

Requirements

You need Ansible version 2.5.0 or higher.

Role Variables

Name Default Value Description
pmm2_client_server_user admin PMM server username
pmm2_client_server_password admin PMM server password
pmm2_client_server_host localhost PMM server address
pmm2_client_server_port 443 PMM server port
pmm2_client_node_address Node address (auto-detected if not set)
pmm2_client_node_type Node type (can be generic or container; defaults to generic if not set)
pmm2_client_node_name Node name (auto-detected if not set)
pmm2_client_disable_log false Stops logging to avoid cluttering logs
pmm2_client_enabled_services [] List of services to set up (currently only "mysql" is supported)
pmm2_client_mysql_login_user root MySQL username for login
pmm2_client_mysql_login_password root MySQL user password
pmm2_client_mysql_login_host localhost MySQL server address
pmm2_client_mysql_login_port 3306 MySQL server port
pmm2_client_mysql_enable_tls false Enables TLS connection to MySQL
pmm2_client_mysql_create_user true Creates a PMM user in MySQL
pmm2_client_mysql_user pmm PMM username for MySQL
pmm2_client_mysql_password pmm PMM password for MySQL
pmm2_client_mysql_host % Allowed hosts for PMM user in MySQL
pmm2_client_mysql_privileges *.*:SELECT,PROCESS,SUPER,REPLICATION CLIENT,RELOAD Permissions for PMM user in MySQL
pmm2_client_mysql_query_source perfschema Source of queries (currently only "perfschema" is supported)
pmm2_client_mysql_enable_query_response_time true Enables metrics for query response times
pmm2_client_mysql_disable_tablestats false Stops collecting table stats when the limit is reached (MySQL)
pmm2_client_mysql_disable_tablestats_limit 1000 Limit for table stats collection (0 means no limit)
pmm2_client_mysql_enable_user_statistics true Enables user statistics in MySQL

Example Playbook

Here is an example playbook for installing and configuring the PMM client with MySQL service:

- hosts: mysql-servers
  vars:
    pmm2_client_server_host: instance-pmm-server
    pmm2_client_server_user: admin
    pmm2_client_server_password: admin
    pmm2_client_enabled_services:
      - mysql
    pmm2_client_mysql_login_host: instance-mysql
    pmm2_client_mysql_login_user: root
    pmm2_client_mysql_login_password: root
  roles:
     - harloprillar.pmm2_client

License

MIT

Informazioni sul progetto

Percona Monitoring and Management 2 client for Debian based and Red Hat based distributions

Installa
ansible-galaxy install harloprillar.pmm2_client
Licenza
Unknown
Download
134
Proprietario