Registers a new database instance in DMS.
Operation description
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
dms:RegisterInstance |
create |
*All Resource
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| Tid |
integer |
No |
The tenant ID. You can call the GetUserActiveTenant operation to obtain the value of this parameter. |
3*** |
| InstanceType |
string |
Yes |
The database type. For valid values, see DbType parameter description. |
MySQL |
| InstanceSource |
string |
Yes |
The source of the database instance. Valid values:
|
RDS |
| NetworkType |
string |
Yes |
The network type. Valid values:
|
VPC |
| EnvType |
string |
Yes |
The environment type. Valid values:
|
product |
| EcsInstanceId |
string |
No |
The ECS instance ID. Note
This parameter is required if InstanceSource is set to ECS_OWN. |
i-2zei9gs1t7h8l7ac**** |
| VpcId |
string |
No |
The VPC ID. Note
This parameter is required if InstanceSource is set to VPC_IDC. |
vpc-xxxxxxxxxxxxxxxxxxxxx |
| EcsRegion |
string |
No |
The region where the instance resides. Note
This parameter is required if InstanceSource is set to RDS, ECS_OWN, or VPC_IDC. |
cn-hangzhou |
| Host |
string |
Yes |
The host address of the destination database. |
172.XX.XXX.254 |
| Port |
integer |
Yes |
The access port of the destination database. |
3306 |
| Sid |
string |
No |
The SID of the database. Note
This parameter is required if InstanceType is set to ORACLE. |
test_sid |
| DatabaseUser |
string |
Yes |
The username used to access the database. |
dmstest |
| DatabasePassword |
string |
Yes |
The password used to access the database. |
Example_passw0rd |
| InstanceAlias |
string |
Yes |
The alias of the instance. This alias helps you quickly identify and locate the instance. |
test_instance |
| DbaUid |
integer |
Yes |
The UID of the user who assumes the DBA role for the instance. You can call the ListUsers or GetInstance operation to obtain the value of this parameter. |
22275482072787**** |
| SafeRule |
string |
Yes |
The security rule set (GroupName) of the instance. You can call the ListStandardGroups or GetInstance operation to obtain the value of this parameter. |
test_rule |
| QueryTimeout |
integer |
Yes |
The query timeout period. Unit: seconds. |
60 |
| ExportTimeout |
integer |
Yes |
The export timeout period. Unit: seconds. |
600 |
| DataLinkName |
string |
No |
The name of the datalink for cross-database query. Note
|
dblink_test |
| DdlOnline |
integer |
No |
Specifies whether schema evolution is prioritized. Valid values:
Note
Supported database types: ApsaraDB RDS for MySQL, PolarDB for MySQL engine, ApsaraDB MyBase for MySQL, and MySQL databases from other sources. |
2 |
| UseDsql |
integer |
No |
Specifies whether to enable cross-instance query. Valid values:
Note
Supported database types: MySQL, SQL Server, PostgreSQL, PolarDB for PostgreSQL (Compatible with Oracle), and Redis. |
1 |
| SkipTest |
boolean |
No |
Specifies whether the instance ignores the connectivity test. Valid values:
|
true |
| EnableSellSitd |
string |
No |
Specifies whether to enable sensitive data protection. Valid values:
|
Y |
| TemplateId |
integer |
No |
The ID of the classification template. You can call the ListClassificationTemplates operation to obtain the value of this parameter. |
31*** |
| TemplateType |
string |
No |
The classification template type. You can call the ListClassificationTemplates operation to obtain the value of this parameter. |
INNER |
| DbaUidByString |
string |
No |
The string used to replace the DbaUid field. You can enter a non-numeric DBA UID, such as a role account. |
22275482072787**** |
| ResourceGroup |
string |
No |
The name of the resource group to which the instance belongs. |
group1 |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| RequestId |
string |
The request ID. |
F4E2A94B-604F-43FF-93E7-F4EE3DCF412E |
| ErrorCode |
string |
The error code. |
UnknownError |
| ErrorMessage |
string |
The error message. |
UnknownError |
| Success |
boolean |
Indicates whether the request is successful. Valid values:
|
true |
Examples
Success response
JSON format
{
"RequestId": "F4E2A94B-604F-43FF-93E7-F4EE3DCF412E",
"ErrorCode": "UnknownError",
"ErrorMessage": "UnknownError",
"Success": true
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.