This topic describes how to register your Alibaba Cloud database instances with Data Management (DMS).
Prerequisites
The database instance that you want to register is supported by DMS. For more information about the types of Alibaba Cloud database instances that are supported by DMS, see Databases supported by DMS.
You are a database administrator (DBA) or a DMS administrator. For more information, see View system roles.
The IP address of the DMS server is added to the whitelist of the Alibaba Cloud database instance. For more information, see Configure an IP address whitelist.
Usage notes
To allow DMS users to manage database instances in the DMS console, you must grant permissions to the DMS users based on your business requirements. For more information about the syntax that you can use to grant permissions, see the official documentation of each type of database. The DMS users must have the following permissions:
To manage all the databases on an instance, a DMS user must have permissions on all the databases.
To manage one or more databases of an instance, a DMS user must have permissions on the specified databases.
To insert, delete, modify, and query data in an instance and change table schemas, a DMS user must have the required DML permissions.
To perform operations on objects, such as views, stored procedures, triggers, and functions in an instance, a DMS user must have the required permissions on these objects.
We recommend that you create a separate database account when you register a database instance.
To prevent interference, do not add spaces or special characters before or after the information that you enter when you register a database instance.
Procedure
In this example, an ApsaraDB RDS for MySQL instance is registered with DMS.
- Log on to the DMS console V5.0.
On the Home page of the DMS console, click the
icon next to Database Instance in the left-side navigation pane.
NoteAlternatively, choose
in the top navigation bar. On the Instance List tab of the Instances page, click New.In the Add Instance dialog box, configure the parameters described in the following table.
Section
Parameter
Description
Data Source
N/A
The source of the database instance. In this example, Alibaba Cloud is selected.
Basic Information
Database Type
The type of the database instance.
Instance Region
The region in which the database instance resides.
Other primary accounts
This parameter appears if you click Cross-Alibaba Cloud account instances. The Alibaba Cloud account to which the database instance belongs.
NoteIf the Alibaba Cloud account is not in the list, you can click Add User to add the Alibaba Cloud account that is used to purchase the database instance. For more information, see the Add a user section of the "Manage users" topic.
Entry mode
The method that you use to specify the information about the database instance. Valid values: Instance ID and Connection string address.
Instance ID or Connection string address
The ID of the database instance or the connection string of the database instance.
NoteThe connection string is in the following format: Internal network address:Port number. Example: rm-XXXXXXX.mysql.rds.aliyuncs.com:3306.
Database Account
The account that is used to log on to the database.
NoteYou can use the specified database account to perform operations such as read and write on the data of the database instance in DMS. You must specify a database account that has the required permissions.
Database Password
The password of the account that is used to log on to the database.
Control Mode
The control mode that is used to manage the database instance. For more information, see Control modes.
Sensitive Data Protection
Specifies whether to enable the sensitive data protection feature. This feature allows you to control and mask sensitive data. For more information, see Enable the sensitive data protection feature.
Classification template
If you turn on Sensitive Data Protection, the Classification template parameter appears.
You can bind a classification and grading template to an instance to identify whether the fields in databases and tables in the instance comply with the identification rules of the template. If the fields comply with the identification rules, the fields are labeled for classification and grading to protect the fields with high sensitivity levels. For more information, see Manage DMS classification and grading templates.
Advanced Information
Environment type
The type of the environment in which the database instance is deployed. For more information, see the Environment types section of the "Change the environment type of an instance" topic.
Instance Name
The name that you specify for the database instance.
NoteIf you register an Alibaba Cloud database instance for the first time, the name of the Alibaba Cloud database instance is synchronized to DMS. DMS does not synchronize the name if the Alibaba Cloud database instance is not registered for the first time. You can change the name of the database instance in the DMS console. For more information, see Modify database instances.
Lock-free Schema Change
Specifies whether to enable lock-free schema change. Valid values: Open (DMS OnlineDDL first), Open (MySQL Native OnlineDDL first), and Close. For more information, see Enable the lock-free schema change feature.
NoteThis parameter appears only for a MySQL database instance.
Enable SSL
Specifies whether to allow DMS to connect to the database instance by using SSL connections.
SSL encrypts network connections at the transport layer to improve the security and integrity of data in transmission. However, SSL increases the response time of network connections.
Before you use SSL connections, make sure that the SSL encryption feature is enabled for the database instance. Valid values:
Default (DMS automatically checks whether self-negotiation is enabled for the database instance.): DMS automatically checks whether the SSL encryption feature is enabled for the database instance. If the SSL encryption feature is enabled, DMS connects to the database instance by using SSL connections. Otherwise, DMS connects to the database instance without encryption.
Enabled: DMS connects to the database instance by using SSL connections. This value is invalid if the SSL encryption feature is disabled for the database instance.
Close: DMS does not connect to the database instance by using SSL connections.
NoteThis parameter appears only for a MySQL database instance.
DBA
The DBA of the database instance. The DBA can grant permissions to users.
Query Timeout Period(s)
The timeout period for the execution of an SQL query statement. If the execution of an SQL query statement lasts longer than the specified timeout period, the execution of the statement is terminated to protect the database.
Export Timeout Period(s)
The timeout period for the execution of an SQL export statement. If the execution of an SQL export statement lasts longer than the specified timeout period, the execution of the statement is terminated to protect the database.
After you specify the preceding parameters, click Test Connectivity in the lower-left corner.
NoteIf the connectivity test fails, check the specified parameter values based on the error message.
If the connection test is passed, click Submit.
After the preceding steps are performed, the Alibaba Cloud database instance is registered with DMS. You can view and manage your database instance in the instance list of the DMS console.
FAQ
When I register an Alibaba Cloud database instance with DMS, the following whitelist error message appears. How do I resolve this issue?
You can click Configure whitelist in the dialog box. The system automatically adds the IP address of the DMS server to the whitelist of the Alibaba Cloud database instance. If the IP address fails to be automatically added to the whitelist, you need to manually add it. For more information, see Configure an IP address whitelist.
I have enabled transport layer security (TLS) encryption for an ApsaraDB for Redis database instance. When I log on to the ApsaraDB for Redis database instance in the DMS console. How do I resolve this issue?
To resolve this issue, perform the following steps:
- Log on to the DMS console V5.0.
On the Home page of the DMS console, choose
in the left-side navigation pane. In the instance list that appears, right-click the ApsaraDB for Redis instance to which you want to log on and click Edit.In the Advanced Information section of the Edit dialog box, set the Enable SSL parameter to Enabled.
Click Test Connectivity.
After the connection test is passed, click Save. The database instance is connected to DMS.
For more information, see Modify database instances.