Comments - MaxScale Troubleshooting

1 year, 5 months ago Testing User A Test

I got no problem in start MaxScale on my 3-node MariaDB Galera cluster. But on node1 alone I got the following error message from /var/log/maxscale/maxscale.log:

error : [MariaDB-Monitor] Failed to connect to server 'server1' ([10.0.2.14]:33063) when checking monitor user credentials and permissions.

On node2 and node3, I did not get that error message. Here are the 'maxctrl' results on all the nodes:

node1 --------

  1. maxctrl list servers ┌─────────┬───────────┬───────┬─────────────┬─────────────────────────┬──────┬─────────────────┐ │ Server │ Address │ Port │ Connections │ State │ GTID │ Monitor │ ├─────────┼───────────┼───────┼─────────────┼─────────────────────────┼──────┼─────────────────┤ │ server1 │ 10.0.2.14 │ 33063 │ 0 │ Auth Error, Down │ │ MariaDB-Monitor │ ├─────────┼───────────┼───────┼─────────────┼─────────────────────────┼──────┼─────────────────┤ │ server2 │ 10.0.2.15 │ 33063 │ 0 │ Master, Synced, Running │ │ MariaDB-Monitor │ ├─────────┼───────────┼───────┼─────────────┼─────────────────────────┼──────┼─────────────────┤ │ server3 │ 10.0.2.16 │ 33063 │ 0 │ Slave, Synced, Running │ │ MariaDB-Monitor │ └─────────┴───────────┴───────┴─────────────┴─────────────────────────┴──────┴─────────────────┘

node2 --------

  1. maxctrl list servers ┌─────────┬───────────┬───────┬─────────────┬─────────────────────────┬──────┬─────────────────┐ │ Server │ Address │ Port │ Connections │ State │ GTID │ Monitor │ ├─────────┼───────────┼───────┼─────────────┼─────────────────────────┼──────┼─────────────────┤ │ server1 │ 10.0.2.14 │ 33063 │ 0 │ Slave, Synced, Running │ │ MariaDB-Monitor │ ├─────────┼───────────┼───────┼─────────────┼─────────────────────────┼──────┼─────────────────┤ │ server2 │ 10.0.2.15 │ 33063 │ 0 │ Master, Synced, Running │ │ MariaDB-Monitor │ ├─────────┼───────────┼───────┼─────────────┼─────────────────────────┼──────┼─────────────────┤ │ server3 │ 10.0.2.16 │ 33063 │ 0 │ Slave, Synced, Running │ │ MariaDB-Monitor │ └─────────┴───────────┴───────┴─────────────┴─────────────────────────┴──────┴─────────────────┘

node3 --------

  1. maxctrl list servers ┌─────────┬───────────┬───────┬─────────────┬─────────────────────────┬──────┬─────────────────┐ │ Server │ Address │ Port │ Connections │ State │ GTID │ Monitor │ ├─────────┼───────────┼───────┼─────────────┼─────────────────────────┼──────┼─────────────────┤ │ server1 │ 10.0.2.14 │ 33063 │ 0 │ Slave, Synced, Running │ │ MariaDB-Monitor │ ├─────────┼───────────┼───────┼─────────────┼─────────────────────────┼──────┼─────────────────┤ │ server2 │ 10.0.2.15 │ 33063 │ 0 │ Master, Synced, Running │ │ MariaDB-Monitor │ ├─────────┼───────────┼───────┼─────────────┼─────────────────────────┼──────┼─────────────────┤ │ server3 │ 10.0.2.16 │ 33063 │ 0 │ Slave, Synced, Running │ │ MariaDB-Monitor │ └─────────┴───────────┴───────┴─────────────┴─────────────────────────┴──────┴─────────────────┘

node1, node2, node3 ---------------------------

  1. maxctrl list services ┌────────────────────┬────────────────┬─────────────┬───────────────────┬───────────────────────────┐ │ Service │ Router │ Connections │ Total Connections │ Targets │ ├────────────────────┼────────────────┼─────────────┼───────────────────┼───────────────────────────┤ │ Read-Write-Service │ readwritesplit │ 0 │ 0 │ server1, server2, server3 │ └────────────────────┴────────────────┴─────────────┴───────────────────┴───────────────────────────┘
  1. maxctrl list listeners Read-Write-Service ┌─────────────────────┬──────┬─────────┬─────────┬────────────────────┐ │ Name │ Port │ Host │ State │ Service │ ├─────────────────────┼──────┼─────────┼─────────┼────────────────────┤ │ Read-Write-Listener │ 4006 │ 0.0.0.0 │ Running │ Read-Write-Service │ └─────────────────────┴──────┴─────────┴─────────┴────────────────────┘

What's wrong?

 
1 year, 5 months ago Testing User A Test

On all the nodes, I have the following section defined on /etc/maxscale.cnf:

[MariaDB-Monitor] type=monitor

  1. module=mariadbmon module=galeramon servers=server1,server2,server3 user=monitor password=testing monitor_interval=2s

I have already created the user 'monitor' on mariadb with the following statement:

CREATE USER 'monitor'@'%' IDENTIFIED BY 'testing';

 
1 year, 5 months ago Markus Mäkelä

The Failed to connect to server 'server1' error means the monitor was not able to connect to the server when it was checking if the user configured for it has all the required grants. Usually you'll also get other errors in the log stating what the actual problem was.

I'd recommend checking the user account on server1' for any problems.

 
1 year, 5 months ago Testing User A Test

The '1.' text was changed from '#', which is a comment line on 'module=mariadbmon' statement.

 
Content reproduced on this site is the property of its respective owners, and this content is not reviewed in advance by MariaDB. The views, information and opinions expressed by this content do not necessarily represent those of MariaDB or any other party.