This topic describes how to register your ApsaraDB instances in Data Management (DMS).

Prerequisites

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 are required to 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

This topic takes ApsaraDB RDS for MySQL as an example.

  1. Log on to the DMS console V5.0.
  2. In the top navigation bar, click Data Assets. In the left-side navigation pane, click Instances.
  3. On the Instance List tab, click New.
  4. In the Add Instance dialog box, set the parameters as required. The following table describes the parameters.
    SectionParameterDescription
    Data sourceN/AThe source of the database instance. You can click the Alibaba Cloud or Third-party Cloud/Self-managed tab. In this example, MySQL is selected on the Alibaba Cloud tab.
    Basic InformationDatabase TypeThe type of the database instance.
    Instance RegionThe region in which the database instance resides.
    Other primary accountsThis parameter appears if you click Cross-Alibaba Cloud account instances. The Alibaba Cloud account to which the database instance belongs.
    Note If the Alibaba Cloud account is not in the list, you can click Add User to add the Alibaba Cloud account used to purchase the Elastic Compute Service (ECS) instance on which the database is hosted. For more information, see Add a user.
    Entry modeThe method that you use to log on to the database instance. Valid values: Instance ID and Connection string address.
    Instance ID or Connection string addressThe ID of the database instance or the endpoint of the database instance.
    Note The connection string address is in the following format: Internal network address:Port number. Example: rm-XXXXXXX.mysql.rds.aliyuncs.com:3306.
    Database AccountThe account that you use to log on to the database instance.
    Note You can use the specified database account to perform operations such as read and write operations on the data of the database instance in DMS. You must specify a database account that has the required permissions.
    Database passwordThe password of the account that you use to log on to the database instance.
    Control ModeThe control mode that you use to manage the database instance in DMS. For more information, see Control modes.
    Sensitive Data ProtectionThis feature allows you to control and mask sensitive data. You can select whether to enable this feature based on your business requirements. For more information, see Enable the sensitive data protection feature.
    Classification templateIf 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 InformationEnvironment typeThe type of the environment in which the database instance is deployed. For more information, see Environment types.
    Instance NameThe name that you specify for the database instance.
    Note If you register an ApsaraDB instance for the first time, the name of the ApsaraDB instance is synchronized to DMS. DMS does not synchronize the name when you perform subsequent operations. You can change the name of the instance to manage the instance name. For more information, see Modify database instances.
    Lock-free Schema ChangeSpecifies whether to enable lock-free schema change. For more information, see Enable the lock-free schema change feature.
    • Open (DMS OnlineDDL first)
    • Open (MySQL Native OnlineDDL first)
    • Close
    Enable SSLSpecifies whether to allow DMS to connect to the database instance by using SSL connections. After this feature is enabled, DMS can 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 transit. 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.
    • Open: DMS connects to the database instance by using SSL connections. This value is invalid if you disable the SSL encryption feature for the database instance.
    • Close: DMS does not connect to the database instance by using SSL connections.
    Note This parameter is displayed only for MySQL databases.
    DBAThe DBA of the database instance. The DBA can grant permissions to users.
    query timeout(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(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.
  5. After you specify the preceding parameters, click Test connection in the lower-left corner.
    Note If the connectivity test fails, check the specified parameter values based on the error message.
  6. If the Successful connection message appears, click Submit.
    After the preceding steps are performed, the ApsaraDB instance is registered with DMS. You can view and manage your database instance in the instance list of the DMS console.

FAQ

What do I do if a whitelist error is displayed when I register an ApsaraDB instance with DMS? Configure whitelist

You can click Set whitelist in the dialog box. The system automatically adds the IP address of the DMS server to the whitelist of the ApsaraDB 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.