Skip to main content

Connect to Database Cluster

You can easily connect to Arvancloud database clusters and manage your data through the command line or graphical interfaces.

To get the details for connecting to the database, click on the cluster from the "All Databases" section in the Managed Database menu. In the overview tab, you can view this information as a connection parameter or string.

If you want to use third-party applications to connect, you can get the connection parameters. Also, if you choose to connect through the terminal, you can use the connection string.

Connect with CLI

You can connect to the database both through the command line and through applications with a graphical interface. To connect to database clusters through the terminal, you can use the following mysql command:

mysql -h 'HOST' -u 'USERNAME' -p'PASSWORD'

Note that instead of USERNAME, HOST, and PASSWORD, find and replace the appropriate values for your cluster from the "Connection Details" section.

If you successfully connect to the cluster, you should see an output similar to the following:

From now on you can manage your cluster with MySQL commands. For more information about the commands of this engine check out the official MySQL documentation.

Connect with GUI

To connect to your database clusters using graphical tools (GUI), you can use any software that can connect to MySQL. In this guide, we will be using Navicat. Navicat is a fast, reliable, and simple tool for database management. This software makes it easy to connect from a local system to database clusters by providing a graphical user interface.

Download the software from the following path and then install it:

https://www.navicat.com/en/download/navicat-for-mysql

After running the software, create a new connection from File > New Connection > MySQL.

In the page that opens, enter the following values:

  • Connection Name: Choose an arbitrary name for your connection.
  • Host: Copy the URL value from the "Connection Details" section of the cluster in the Arvancloud panel and paste it here.
  • Port: enter the value 3306 in this section.
  • User Name: Copy this value from the "Connection Details" section of the cluster in the Arvancloud panel and paste it in this section.
  • Password: Copy this value from the "Connection Details" section of the cluster in the Arvancloud panel and paste it here.

Then click the "Test Connection" button to check the connection. Finally, click OK to create your connection. You can view this connection in the list on the left sidebar.

From now on, you will be able to manage your cluster in Navicat. You can also get help from Navicat's official documentation to learn more about how to work with this software.