Using the MySQL Client to Connect to Doris
Doris supports the MySQL protocol. Therefore, most clients that support the MySQL protocol can access Doris, including the CLI or IDE, such as MariaDB, DBeaver, and Navicat for MySQL.
This section uses the MySQL 8.0.22 client to connect to Doris as an example.
Prerequisite
The node where the MySQL client is to be installed can communicate with the MRS cluster.
Procedure
- Log in to the node where the MySQL client is to be installed as the root user.
- Run the following command to check the version of the ncurses-libs library on which the MySQL client depends:
rpm -qa | grep ncurses
- Download the software package corresponding to the MySQL client from https://downloads.mysql.com/archives/community/. You are advised to install MySQL 8.x. The following uses Red Hat as an example:
- If the dependent library in 2 is 6.x, you are advised to download the MySQL software package whose OS version is Red Hat 8.
- If the dependent library in 2 is 5.x, you are advised to download the MySQL software package whose OS version is Red Hat 7.
For example, to install the MySQL 8.0.22 client of Red Hat, download the following software packages:
- Upload the downloaded software package to the node where the MySQL client is to be installed.
- Run the following command in the directory where the uploaded file is stored to install the MySQL client and the corresponding dependency package:
rpm -ivh mysql-community-client-8.0.22-1.el8.x86_64.rpm --nodeps --force
rpm -ivh mysql-community-client-plugins-8.0.22-1.el8.x86_64.rpm --nodeps --force
rpm -ivh mysql-community-common-8.0.22-1.el8.x86_64.rpm --nodeps --force
rpm -ivh mysql-community-libs-8.0.22-1.el8.x86_64.rpm --nodeps --force
- Run the following command to check the MySQL client version:
mysql --version
- After the MySQL client is successfully installed, you can access Doris. For details, see Getting Started with Doris.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot