-
Notifications
You must be signed in to change notification settings - Fork 999
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[ERROR] RECEIVED AN UNKNOWN COMMAND: 31 -- PLEASE REPORT A BUG #2021
Comments
Hi @nicolasgarfinkiel . Thank you for the report. |
This error occurs on the following version: proxysql-1.4.12-1.2.el7.x86_64 as well. |
did u find a workaround @nicolasgarfinkiel ?? |
Hi @rohitkeshwani07, sorry for the late reply. The workaround was to specify in the client to use 5.7 version of MySQL protocol to force use of COM_CHANGE_USER instead of COM_RESET_CONNECTION (that's command 31). They are basically the same, one being more lightweight than the other. Besides, in my use case there was no need to connect with a higher protocol version, even if using MySQL and sending queries that rely on MySQL 8+. |
I am guessing you did that by specifying |
Nope, that's something you specify at client level, ie: MySqlConnector |
ok... Don't u think, if proxysql is informing version as 5.7 to the client... as it picks from |
I just noticed (due to server disk space filling up) that I am seeing this in my logs hundreds of times per second. What is the path forward here? Is there a way to silence these logs or fix clients? I am unable to downgrade to 5.7 protocol on some of my connecting clients so the above "workaround" is not an easy solution for me. |
@peppy With MySqlConnector setting client version to 5.7 only affects the way the connection is cleaned up when it returns to the pool, instead of using COM_RESET_CONNECTION (31), it uses COM_CHANGE_USER. The former is a lighter version of the latter, but it does not affect performance whatsoever. However, I dunno if changing the client version on other platforms affects client another behaviour. |
Unfortunately it does affect behaviour for us (laravel sends commands with proxysql cannot handle if set to 5.x). Is there any other solution? |
@peppy i think that is just u can overwrite this function |
Also this is happening for me only when we run an alter query directly on mysql without going from proxysql... so we decided to stop proxysql when running alters. you may want to test this as well. |
Is there any way to get an actual fix for this pushed? We've fixed laralvel, but I have JDBC connectors which are also complaining about the version mismatch (trying to access |
@renecannao |
FYI - I ran into this same problem with our .NET connector code in an older .NET Core 2.1 application (using MySqlConnector 0.57.0). I found that setting mysql-server_version to 5.5.0 resolved the problem, although I admit to not knowing exactly why that worked. We originally set mysql-server_version to 5.7.32-log to match our Azure MySQL server, but then we had this problem spamming our logs constantly.
|
…tored multiple tests functions #2021
…nnection_com_change_user-t.cpp' #2021
Added support for 'COM_RESET_CONNECTION' and 'COM_CHANGE_USER' fixes - Closes #2021
Thanks so much for making this fix happen! Will give it a test when it hits a release. |
…tored multiple tests functions #2021
…nnection_com_change_user-t.cpp' #2021
Added support for 'COM_RESET_CONNECTION' and 'COM_CHANGE_USER' fixes - Closes #2021
Release it quickly. |
Hello,
Using MySqlConnector client for .NET (https://github.com/mysql-net/MySqlConnector) I get the following error in ProxySQL, version 2.0.:
[ERROR] RECEIVED AN UNKNOWN COMMAND: 31 -- PLEASE REPORT A BUG
Looking at the source code I see that
[1f] COM_RESET_CONNECTION (31)
is not implemented in MySQL_Session.cpp, I see_MYSQL_COM_RESET_CONNECTION
in proxysql_structs.h, but it is not used.Any chance that it can be implemented? Maybe temporarily using change user functionality?
Thanks in advance!
The text was updated successfully, but these errors were encountered: