Create a DB instance before connecting to it. For details, see Buying an RDS for MySQL Instance. You can connect to an RDS for MySQL instance through a command-line interface (CLI), graphical user interface (GUI), or using Java database connectivity (JDBC).
Connection Method | Connection Address | Description |
|---|---|---|
Connecting to an RDS for MySQL Instance Through the MySQL CLI Client | For details, see Connecting to a DB Instance over a Private or Public Network Using a CLI. | In Linux, you need to install the mysql client on the ECS and connect to the instance through the MySQL CLI over a private or public network.
|
EIP for read/write | In Windows, you can use any common database client to connect to an RDS for MySQL instance. | |
Floating IP address for read/write or EIP for read/write | RDS for MySQL is compatible with the community ecosystem and does not provide driver services. You can select a community driver version as required. If you are connecting to an instance through JDBC, an SSL certificate is optional, but using an SSL certificate can improve the security of your data. SSL is disabled by default for RDS for MySQL instances. You can enable it by referring to Configuring an SSL Connection. SSL encrypts connections to databases but it increases the connection response time and CPU usage. Therefore, you are advised not to enable SSL. |
Table 2 lists how to use a CLI to connect to an RDS for MySQL instance over a private or public network.
Figure 1 Connecting to a DB instance over a private or public network

Connection Method | IP Address | Security Group Rules | Description |
|---|---|---|---|
Floating IP address |
|
| |
You need to buy an EIP. | To access a DB instance from resources outside the security group that the DB instance is associated with, you need to configure an inbound rule for the security group. For details, see Configuring Security Group Rules. |
|