GithubHelp home page GithubHelp logo

thecicco / mysqlsh_plugin_role Goto Github PK

View Code? Open in Web Editor NEW
4.0 1.0 0.0 137 KB

Install mysqlsh-plugin for manage proxysql-plugin with Mysql8.0 InnoDB Replication

License: GNU General Public License v2.0

Python 96.29% Jinja 3.71%
mysql mysqlsh proxysql ansible-galaxy ansible-role

mysqlsh_plugin_role's Introduction

mysqlsh-plugin

Galaxy

Ansible Role for install mysqlsh-plugins and for manage proxysql-plugin with Mysql8.0 InnoDB Replication

More information on how to integrate proxysql in mysql innodb cluster here: https://lefred.be/content/how-to-integrate-proxysql-in-mysql-innodb-cluster/

these plugins is developed by https://github.com/lefred/mysqlshell-plugins

Requirements

This role requires Ansible 2.9 or higher.

Role Variables

The role defines its variables in defaults/main.yml:

Varibles definitition

VARIABLE DESCRIPTION DEFAULT VALUE
mysql_user user for mysql "root"
mysql_root_password password for mysql user "password"
proxysql_remoteadmin_user remote admin for proxysql "remoteadmin"
proxysql_remoteadmin_password remoteadmin password for proxysql "password"
mysql_ip ip of mysql MASTER "192.168.0.130"
proxysql_ip proxysql ip, this can be a VIP if you have 2 proxysql "192.168.0.134"

Proxysql Varibles for plugin

VARIABLE DESCRIPTION DEFAULT VALUE
max_writers ProxySQL will limit the number of Read-Write instances populated in the writer hostgroup based on the value defined in max_writers for the cluster. Any nodes exceeding this number are placed into the backup_writer_hostgroup and ProxySQL will move these to the writer_hostgroup to actively serve traffic as needed "1"
writer_is_also_reader This parameter has three possible values: (0, 1, 2). writer_is_also_reader=0: nodes with read_only=0 will be placed either in the writer_hostgroup and in the backup_writer_hostgroup after a topology change, these will be excluded from the reader_hostgroup. writer_is_also_reader=1: nodes with read_only=0 will be placed in the writer_hostgroup or backup_writer_hostgroup and are all also placed in reader_hostgroup after a topology change. writer_is_also_reader=2 : Only the nodes with read_only=0 which are placed in the backup_writer_hostgroup are also placed in the reader_hostgroup after a topology change i.e. the nodes with read_only=0 exceeding the defined max_writers. "1"
max_transaction_behind determines the maximum number of transactions behind the writers that ProxySQL should allow before shunning the node to prevent stale reads (this is determined by querying the transactions_behind field of the sys.gr_member_routing_candidate_status table in MySQL "200"
use_ssl enable ssl comunication with mysql backends "0"
monitor_user monitor user, Use Always monitor as monitor-user also in proxysql.conf "monitor"
monitor_password password for user monitor "password"

Example Playbook

Run with default vars:

---
- name: Copy adn install plugins for mysqlsh and enabale/connect proxysql-plugin 
  hosts: all
  become: true
  become_user: root
  become_method: sudo
  gather_facts: true
  roles:
    - role: mysqlsh_plugin_role

mysqlsh_plugin_role's People

Contributors

thecicco avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.