nav-img
Advanced

Overview

Before connecting to a DB instance, you must create one first. For details about how to create a DB instance, see Step 1: Create a DB Instance. You can connect to a DB instance through a private network or a public network.

Table 1 RDS connection methods

Connect Through

IP Address

Scenarios

Description

Floating IP

RDS provides a floating IP address by default.

When your applications are deployed on an ECS that is in the same region and VPC as RDS, you are advised to use a floating IP address to connect to the RDS DB instance through the ECS.

  • Secure and high-performance
  • Recommended

EIP

If you cannot access an RDS DB instance through a floating IP address, bind an EIP to the DB instance and connect the DB instance through the EIP.

  • Less secure compared with other connection methods
  • To achieve a higher transmission rate and security level, you are advised to migrate your applications to an ECS that is in the same VPC as your RDS DB instance and use a floating IP address to access the DB instance.
Note
  • VPC: Virtual Private Cloud
  • ECS: Elastic Cloud Server
  • EIP: Elastic IP
  • If the ECS is in the same VPC as your RDS DB instance, you do not need to apply for an EIP.

Figure 1 illustrates the connection over a private network or a public network.

Figure 1 DB instance connection