Script to make a proxy (ie HAProxy) capable of monitoring Percona XtraDB Cluster nodes properly. The clustercheck script is distributed under the BSD license.
BSD 3-Clause "New" or "Revised" License
173
stars
108
forks
source link
clustercheck not running correctly as MYSQL_USERNAME:=-clustercheckuser #29
$ ./clustercheck
HTTP/1.1 503 Service Unavailable
Content-Type: text/plain
Connection: close
Content-Length: 44
Percona XtraDB Cluster Node is not synced
$ mysql -u clustercheckuser -p -e "SHOW STATUS LIKE 'wsrep_local_state';"
Enter password:
+-------------------+-------+
| Variable_name | Value |
+-------------------+-------+
| wsrep_local_state | 4 |
+-------------------+-------+
When I corrected the MYSQL_USERNAME to "clustercheckuser", the script now runs correctly. I have created a pull request for this.
$ ./clustercheck
HTTP/1.1 200 OK
Content-Type: text/plain
Connection: close
Content-Length: 40
Percona XtraDB Cluster Node is synced.
On my test DB server running a MariaDB cluster:
When I corrected the MYSQL_USERNAME to "clustercheckuser", the script now runs correctly. I have created a pull request for this.