[MXS-1619] Maxscale v2.2 user authentication issue Created: 2018-01-19 Updated: 2021-06-21 Resolved: 2018-06-12 |
|
| Status: | Closed |
| Project: | MariaDB MaxScale |
| Component/s: | N/A |
| Affects Version/s: | None |
| Fix Version/s: | N/A |
| Type: | Bug | Priority: | Major |
| Reporter: | Chandranana | Assignee: | Unassigned |
| Resolution: | Cannot Reproduce | Votes: | 0 |
| Labels: | None | ||
| Attachments: |
|
| Description |
|
We are facing issues in user authentication in client server communication via Maxscale on s390x.
More details as below,we have a container with IPs as follows: User With Password: On Master server below are the users with their privileges: MariaDB [(none)]> SELECT User, Host, Password FROM mysql.user;
-------- MariaDB [(none)]> show grants for 'maxuser'@'172.17.0.4';
--------------------------------------------------------------------------------------------------------------------------
-------------------------------------------------------------------------------------------------------------------------- MariaDB [(none)]> show grants for 'maxuser'@'172.17.0.10';
---------------------------------------------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------------------------------------------- When we try to connect from client to mariadb master via maxscale we get the below error in red: _ mysql -h 172.17.0.4 -u maxuser -p -P 4008 _ ERROR 1045 (28000): Access denied for user 'maxuser'@'172.17.0.10' (using password: YES) Maxscale configuration is as below: [maxscale] [server1] [server2] [MariaDB-Monitor] [Read-Only-Service] [Read-Write-Service] [MaxAdmin-Service] [Read-Only-Listener] [Read-Write-Listener] [MaxAdmin-Listener] User Without Password: Users & privileges are as below: MariaDB [(none)]> SELECT User, Host, Password FROM mysql.user;
--------
-------- MariaDB [(none)]> show grants for 'maxuser'@'172.17.0.10';
--------------------------------------------------------
-------------------------------------------------------- MariaDB [(none)]> show grants for 'maxuser'@'172.17.0.4';
-------------------------------------------------------
------------------------------------------------------- When we try to connect to master from client via maxscale without password being set, the connection is successful. mysql -h 172.17.0.4 -u maxuser -p -P 4008 Copyright (c) 2000, 2017, Oracle, MariaDB Corporation Ab and others. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. MySQL [(none)]> ====================================================================== All permissions are granted for these users. Maxscale.log doesn't show any errors for authentication except error : Failed to read journal file: Expected 671088640 bytes, read 40 bytes. PFA the maxscale log. Please refer to https://groups.google.com/forum/#!topic/maxscale/X19k13cHBfA for further communication on this. Please let us know if there are any pointers on this, what could be missing to get this work. |
| Comments |
| Comment by Chandranana [ 2018-01-22 ] | |||||||||||||||||
|
Any update on this? Please let us know if any, as it will speed up our Maxscale testing. | |||||||||||||||||
| Comment by Chandranana [ 2018-01-29 ] | |||||||||||||||||
|
Team, | |||||||||||||||||
| Comment by dapeng huang [ 2018-01-29 ] | |||||||||||||||||
|
Are you sure your password is correct? | |||||||||||||||||
| Comment by Chandranana [ 2018-01-29 ] | |||||||||||||||||
|
The password that we enter is "maxpwd" for maxuser
---------
--------- 4 rows in set (0.00 sec) Password seems to be correct:
-------------------------------------------
------------------------------------------- | |||||||||||||||||
| Comment by Johan Wikman [ 2018-01-30 ] | |||||||||||||||||
|
If you do not see the same behaviour on an x86 platform, then I would guess (a pure guess) that this is somehow related to the fact that Linux on s390x is big-endian while Linux on x86 is little-endian. | |||||||||||||||||
| Comment by ZhenweiYang [ 2020-10-27 ] | |||||||||||||||||
|
HI All, My maxscale version is 2.5.5, I checked log and found that the password is changing every time when I login. And every thing is ok when use maxscale 2.4.1. How I can fix this issue ? [root@db_1111_middle_02-210-37 maxscale]# maxscale -V 2020-10-27 16:45:15 info : (2) (find_user): Found matching user 'sysbench'@'10.0.0.108' for client 'sysbench'@'10.0.0.108' with sufficient privileges. | |||||||||||||||||
| Comment by Karl Klepper [ 2021-06-21 ] | |||||||||||||||||
|
Same issue here, CentOS 8. Tried both with MariaDB 10.3 and 10.5 and Maxscale 2.4 and 2.5. with docker volumes to make maxuser permanent. MariaDB [(none)]> SELECT user, host, password FROM mysql.user ORDER BY 1;
--------
-------- master_1 | 2021-06-21 12:08:15 22 [Warning] Access denied for user 'maxuser'@'192.168.0.5' (using password: YES) Same for slaves, of course. This is really unpleasant. What happens here? ~# id=$(docker ps -a | grep "_maxscale" | grep -v "xited" | awk ' {print $1}') && docker exec -it $id maxscale -V | |||||||||||||||||
| Comment by Karl Klepper [ 2021-06-21 ] | |||||||||||||||||
|
Sorry forgot to list the rights, given by a tutorial: GRANT SELECT ON mysql.user TO 'maxuser'@'%'; | |||||||||||||||||
| Comment by Karl Klepper [ 2021-06-21 ] | |||||||||||||||||
|
Another fact: I use docker. Here is my compose file version: '2'
slave1:
slave2:
maxscale:
volumes: |