Memanggil AttachClassicLinkVpc untuk menghubungkan instans jenis jaringan klasik ke virtual private cloud (VPC) guna mengaktifkan peering jaringan pribadi antara instans jenis jaringan klasik dan resource cloud di VPC.
Deskripsi operasi
Saat memanggil operasi ini, perhatikan hal-hal berikut:
Sebelum menghubungkan instans jenis jaringan klasik, instans harus berada dalam status Running atau Stopped.
Fitur ClassicLink harus diaktifkan untuk VPC tujuan. Untuk informasi selengkapnya, lihat Enable ClassicLink.
Instans jenis jaringan klasik dan VPC harus berada di wilayah yang sama.
Coba sekarang
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
ecs:AttachClassicLinkVpc |
update |
*Instance
*VPC
|
|
None |
Parameter permintaan
|
Parameter |
Type |
Required |
Description |
Example |
| RegionId |
string |
Yes |
ID wilayah instans. Anda dapat memanggil DescribeRegions untuk mengkueri daftar wilayah terbaru. |
cn-hangzhou |
| InstanceId |
string |
Yes |
ID instans jenis jaringan klasik. Anda dapat memanggil DescribeInstances untuk mengkueri instans yang aktif. |
i-bp1gtjxuuvwj17zr**** |
| VpcId |
string |
Yes |
ID VPC tempat Anda mengaktifkan ClassicLink. Anda dapat memanggil DescribeVpcs untuk mengkueri VPC yang aktif. |
vpc-bp1j4z1sr8zxu4l8u**** |
Elemen respons
|
Element |
Type |
Description |
Example |
|
object |
|||
| RequestId |
string |
ID permintaan. |
473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E |
Contoh
Respons sukses
JSONformat
{
"RequestId": "473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E"
}
Respons error
JSONformat
{
"RequestId": "C0003E8B-B930-4F59-ADC0-0E209A9012A8"
}
Kode kesalahan
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 403 | InvalidInstanceId.NotFound | The InstanceId provided does not exist in our records. | |
| 403 | InvalidRegionId.Malformed | The specified parameter ?RegionId? is not valid. | |
| 403 | InvalidVpcId.Malformed | The specified parameter ?VpcId? is not valid. | |
| 403 | InvalidInstanceId.MalFormed | The specified instance is not a classic network instance. | |
| 403 | OperationDenied | The instance does not allow link to vpc. | |
| 403 | InvalidParameter.InvalidInstanceIdAndVpcId | The parameter InstanceId and VpcId are not allowed to be empty at the same time. | |
| 403 | InvalidStatus.InstanceStatus | The specified instance status is not support this operation ,expect status is running or shutted. | |
| 403 | InvalidInstanceId.NotBelong | The specified instance is not belong to you. | |
| 403 | QuotaExceeded | The link quota exceeded in this vpc. | |
| 403 | InvalidStatus.InstanceLocked | The specified instance is locked,please wait more. | |
| 403 | InvalidInstanceId.LimitedRegion | The specified instance does not support this operation due to the limitation of its region. | |
| 403 | Forbidden.SubUser | User not authorized to operate on the specified resource. | |
| 403 | InvalidRegionId.NotFound | The RegionId provided does not exist in our records. |
Lihat Error Codes untuk daftar lengkap.
Catatan rilis
Lihat Release Notes untuk daftar lengkap.