Using ProxySQL to Access and Manage Percona XtraDB Cluster

We will use ProxySQL as a gateway to access our Percona XtraDB Cluster. ProxySQL is a high-performance SQL proxy. ProxySQL runs as a daemon watched by a monitoring process. The process monitors the daemon and restarts it in case of a crash to minimize downtime. The daemon accepts incoming traffic from MySQL clients and forwards it to backend MySQL servers. Installing ProxySQL Node configuration Node Host IP Node 1 db1 192.168.50.31 Node 2 db2 192.168.50.32 Node 3 db3 192.168.50.33 Node 4 proxysql 192.168.50.34 Prerequisites Install CentOS 7 ...

Build Percona XtraDB Cluster using Ansible

Percona XtraDB Cluster is a database clustering solution for MySQL. It ensures high availability, prevents downtime and data loss, and provides linear scalability for a growing environment. Here we will try to install Percona XtraDB Cluster on a three nodes cluster configuration with the help from Ansible configuration management. Installing Percona XtraDB Cluster on Red Hat Enterprise Linux and CentOS 7 Node configuration Node Host IP Node 1 db1 192.168.50.31 Node 2 db2 192.168.50.32 Node 3 db3 192.168.50.33 Prerequisites Install CentOS 7 Update CentOS 7 Open firewall for TCP ports 3306, 4444, 4567, 4568: ansible -i hosts -bkKv db-cluster -m firewalld -a 'port=3306/tcp permanent=true state=enabled immediate=yes' ansible -i hosts -bkKv db-cluster -m firewalld -a 'port=4444/tcp permanent=true state=enabled immediate=yes' ansible -i hosts -bkKv db-cluster -m firewalld -a 'port=4567/tcp permanent=true state=enabled immediate=yes' ansible -i hosts -bkKv db-cluster -m firewalld -a 'port=4568/tcp permanent=true state=enabled immediate=yes' Disable or set SELinux to Permissive, set option below in /etc/selinux/config and /etc/sysconfig/selinux: ...