MySQL Connectivity Check Utility
1.7K
To evaluate downtime during MySQL cluster maintenance, we can use this simple utility to measure the downtime
Check MySQL connectivity with command "SELECT 1"
./mysql-connectivity \
--user tester \
--pass mySecr3tP@ssword \
--addr mysql.example.dev \
--dbname testdb \
--command "SELECT 1"
Sample Output:
INFO[2021-03-13T23:55:45+08:00] Opening database connection
INFO[2021-03-13T23:55:45+08:00] Ping pass
DEBU[2021-03-13T23:55:46+08:00] 1
DEBU[2021-03-13T23:55:47+08:00] 1
DEBU[2021-03-13T23:55:48+08:00] 1
DEBU[2021-03-13T23:55:49+08:00] 1
DEBU[2021-03-13T23:55:50+08:00] 1
DEBU[2021-03-13T23:55:51+08:00] 1
$ go get -u github.com/guessi/mysql-connectivity
$ go install github.com/guessi/mysql-connectivity
Content type
Image
Digest
sha256:b94f9a026…
Size
9.2 MB
Last updated
7 months ago
docker pull guessi/mysql-connectivity