将云数据库 Tair(兼容 Redis)实例迁移到同地域内的其它可用区。
接口说明
执行本接口前需要先释放公网连接地址等,更多信息请参见迁移可用区。
如果实例是从经典网络切换到专有网络的,并且保留了经典网络的连接地址,则需等到经典网络连接地址到期释放后才能执行可用区迁移。
迁移之后实例的连接地址不会改变,但 VIP 会发生变化,请在业务中使用连接地址连接实例而非其 VIP 地址。
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
调试
授权信息
|
操作 |
访问级别 |
资源类型 |
条件关键字 |
关联操作 |
|
kvstore:MigrateToOtherZone |
update |
*DBInstance
|
无 | 无 |
请求参数
|
名称 |
类型 |
必填 |
描述 |
示例值 |
| DBInstanceId |
string |
是 |
实例 ID。 |
r-bp1zxszhcgatnx**** |
| ZoneId |
string |
是 |
要迁移到的目标主可用区 ID,可调用 DescribeZones 接口查询。 |
cn-hangzhou-g |
| VSwitchId |
string |
否 |
虚拟交换机的 ID 。 说明
|
vsw-bp1e7clcw529l773d**** |
| EffectiveTime |
string |
否 |
数据迁移后执行数据库切换的时间,取值:
说明
默认值:Immediately。 枚举值:
|
Immediately |
| SecondaryZoneId |
string |
否 |
要迁移到的目标备可用区 ID,可调用 DescribeZones 接口查询。 说明
传入本参数可以实现主备数据节点分布在不同的可用区,实现跨可用区容灾,可承受机房级别的故障。 |
cn-hangzhou-h |
| ReplicaCount |
integer |
否 |
主可用区的备节点数(个)。 说明
|
1 |
| SlaveReplicaCount |
integer |
否 |
备可用区的备节点数(个)。 |
1 |
| ReadOnlyCount |
integer |
否 |
主可用区的只读节点数(个)。 说明
|
1 |
| SlaveReadOnlyCount |
integer |
否 |
备可用区的只读节点数(个)。 |
1 |
返回参数
|
名称 |
类型 |
描述 |
示例值 |
|
object |
|||
| RequestId |
string |
请求 ID。 |
29B0BF34-D069-4495-92C7-FA6D9452**** |
示例
正常返回示例
JSON格式
{
"RequestId": "29B0BF34-D069-4495-92C7-FA6D9452****"
}
错误码
|
HTTP status code |
错误码 |
错误信息 |
描述 |
|---|---|---|---|
| 400 | NetworkType.NotSupport | Specified network type does not support this operation. | 当前实例已开启公网访问/直连访问,暂不支持此操作.请关闭公网访问/直连访问后执行此操作 |
| 400 | InstanceStatus.NotSupport | Instance status does not support this operation. | 当前实例状态不支持此操作 |
| 400 | MissingSwitchId | VSwitchId is mandatory for this action. | |
| 400 | IzNotSupportVpcError | Specify zone not support VPC. | |
| 400 | InvalidReginAvzNotFound | Specified user does not find the region and zone. | |
| 400 | ClusterNotSupport | The Specified cluster does not support. | |
| 400 | InvalidVSwitchId.Mismatch | The Specified vSwitchId does not matched VPC. | |
| 400 | InvalidIzNo.NotSupported | The Specified Zone does not supported. | |
| 500 | VpcServiceError | Invoke VPC service failed. | |
| 500 | ZoneMigrationError.StillingRunning | Zone migration task is still running. | |
| 404 | DBInstanceNotFound | Specified instance does not exist. |
访问错误中心查看更多错误码。
变更历史
更多信息,参考变更详情。