About issue with MySQL Version in Azure

juan polanco 0 Reputation points
2023-02-02T14:04:59.7933333+00:00

Dear Azure community,

I'm having issues with the version for MySQL server in Azure.

When I login to the Server (through Console), I noticed the VERSION of the server is : 5.6.47.0 :

[08:37:37][root@VM][/root] # mysql -h SERVER -u USER@SERVER -p

Welcome to the MySQL monitor.  Commands end with ; or \g.

Your MySQL connection id is XXXXXX

Server version:5.6.47.0 MySQL Community Server (GPL)


But the server variables say different:
| version                 | 5.7.32-log                   |

mysql> select @@version;

+------------+

| @@version  |

+------------+

| 5.7.32-log |

+------------+

1 row in set (0.01 sec)

AND when we look at the AZURE Portal, the version is 5.7:
----------------------------------------------------------------------------------------------------------------image.png


We need to fix this because we have an issue with Temporal tool that cannot work with Azure and we think it is because of the compatibility with 5.7. We need to make the version officially to be 5.7.
https://docs.temporal.io/clusters#dependency-versions

MySQL v5.7 and v8.0

Azure Database for MySQL
Azure Database for MySQL
An Azure managed MySQL database service for app development and deployment.
986 questions
{count} votes

1 answer

Sort by: Most helpful
  1. GeethaThatipatri-MSFT 29,542 Reputation points Microsoft Employee Moderator
    2023-02-03T14:26:09.28+00:00

    Hi, @juan polanco Welcome to the Microsoft Q&A forum, Thanks for posting your question.

    In Single Server, a gateway is used to redirect the connections to server instances in the backend. After the connection is established, the MySQL client displays the version of MySQL set in the gateway, not the actual version running on the MySQL server instance. This is why you may see 5.6 in the initial connection. If you use the SELECT VERSION(); command at the MySQL prompt it will display the version of MySQL instance.

     The default port 3306 to connect to Azure Database for MySQL reaches gateway that runs MySQL client version 5.6 (least common denominator) to support connections to servers of all 2 supported major versions. However, if there is a requirement to connect to a specific major version say v5.7 or v8.0, you can do so by changing the port in your server connection string.

     Gateway nodes listen on port 3308 for v5.7 clients and port 3309 for v8.0 clients. If you would like to connect to v5.7 gateway client, use port 3308 and, similarly, to connect to v8.0 gateway client, use port 3309.

     This is documented here: Azure Database for MySQL managing updates and upgrades | Microsoft Learn

    Hope this information helps. Please let us know if any further queries.

    Regards

    Geetha

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.