All Products
Search
Document Center

ApsaraDB RDS:CopyDatabase

Last Updated:Mar 13, 2024

Replicates the databases of an instance that runs SQL Server 2008 R2 to another instance. This operation is phased out.

Operation description

This operation is phased out.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
rds:CopyDatabaseWRITE
  • DBInstance
    acs:rds:{#regionId}:{#accountId}:dbinstance/{#dbinstanceId}
  • rds:ResourceTag
none

Request parameters

ParameterTypeRequiredDescriptionExample
ResourceGroupIdstringNo

The ID of the resource group.

rg-acfmy*****

Response parameters

ParameterTypeDescriptionExample
object

The response parameters.

DBNamestring

The name of the database.

test02
TaskIdstring

The ID of the task.

2562****
DBStatusstring

The status of the database. Valid values:

  • Creating
  • Running
  • Deleting
Creating
RequestIdstring

The ID of the request.

1AD222E9-E606-4A42-BF6D-8A4442913CEF

Examples

Sample success responses

JSONformat

{
  "DBName": "test02",
  "TaskId": "2562****",
  "DBStatus": " Creating",
  "RequestId": "1AD222E9-E606-4A42-BF6D-8A4442913CEF"
}

Error codes

HTTP status codeError codeError messageDescription
400InvalidDBName.FormatSpecified DB name is not valid.The database name is invalid. Specify a valid name. The name can be up to 16 characters in length and can contain lowercase letters, digits, and underscores (_). The name must start with a lowercase letter and end with a lowercase letter or a digit.
400InvalidDBName.ForbidSpecified DB name is a keyword in RDS.Failed to specify the database name. The database name cannot contain the forbidden keyword DBName. Modify the database name.
400InvalidDBName.DuplicateSpecified DB name already exists in the This instance.A database with the same name has been created on the RDS instance. Specify a different name.
400InvalidAccountName.FormatSpecified account name is not valid.The username is invalid.
400InvalidAccountName.ForbidSpecified account name is a keyword in RDS.The username is invalid. Forbidden keywords cannot be used for a username. Modify the username.
400InvalidCharacterSetName.FormatSpecified character set name is not valid.The character set is invalid. ApsaraDB RDS supports the following character sets: gbk, utf8, euckr, and ascii.
400InvalidAccountPrivilege.MalformedSpecified account privilege is not valid.Your account does not have the required permissions.
400InvalidAccountPassword.FormatSpecified account password is not valid.The password of the account is invalid. Specify a valid password.
400InvalidDBDescription.FormatSpecified DB description is not valid.The database description is invalid. Specify a valid description.
400InvalidReserveAccount.FormatSpecified ReserveAccount is not valid.-
400IncorrectEngineVersionCurrent engine version does not support operations.The operation failed. The operation is not supported for the version of the database engine that is run on the RDS instance.
403DBLimitExceededDBQuotaExceeded: Exceeding the allowed amount of DB.The number of databases in the RDS instance reaches the upper limit. Delete unused databases from the RDS instance.
403AccountLimitExceededAccountQuotaExceeded: Exceeding the allowed amount of accountThe number of accounts exceeds the maximum number of accounts that are allowed.
403IncorrectDBInstanceStateCurrent DB instance state does not support this operation.-
403IncorrectDBInstanceTypeCurrent DB instance type does not support this operation.The operation failed. The RDS instance is not in a ready state.
403OperationDenied.AccountModeThe operation is not permitted due to account mode of instance.The operation is not supported for the account type of the RDS instance. ApsaraDB RDS supports two types of accounts: privileged accounts and standard accounts.
404InvalidDBName.NotFoundSpecified one or more DB name does not exist or DB status does not support.The operation failed. The instance name cannot be found.
404IncorrectDBInstanceLockModeCurrent DB instance lock mode does not support this operation.The operation failed. The RDS instance is locked.
404InvalidDBInstance.NotFoundSpecified instance does not exist or not support.The RDS instance cannot be found, is deleted, or does not support the operation.

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
2023-07-21The Error code has changed. The request parameters of the API has changedsee changesets
Change itemChange content
Error CodesThe Error code has changed.
    delete Error Codes: 400
    delete Error Codes: 403
    delete Error Codes: 404
Input ParametersThe request parameters of the API has changed.
    Added Input Parameters: ResourceGroupId
2022-09-01The Error code has changed. The response structure of the API has changedsee changesets
Change itemChange content
Error CodesThe Error code has changed.
    delete Error Codes: 400
    delete Error Codes: 403
Output ParametersThe response structure of the API has changed.