Membuat instans Gateway Load Balancer (GWLB).
Deskripsi operasi
Ensure that you fully understand the billing methods and pricing of GWLB before calling this operation.
-
When you create a GWLB instance, the service-linked role AliyunServiceRoleForGwlb is automatically created.
-
CreateLoadBalancer is an asynchronous operation. After a request is sent, the system returns a request ID and runs the task in the background. You can call the GetLoadBalancerAttribute operation to query the status of a GWLB instance.
If the GWLB instance is in the Provisioning state, the GWLB instance is being created.
If the GWLB instance is in the Active state, the GWLB instance is created.
Coba sekarang
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
gwlb:CreateLoadBalancer |
create |
*LoadBalancer
*VSwitch
*VPC
|
None | None |
Parameter permintaan
|
Parameter |
Type |
Required |
Description |
Example |
| AddressIpVersion |
string |
No |
Versi IP. Nilai valid:
|
IPv4 |
| LoadBalancerName |
string |
No |
Nama instans GWLB. Nama harus terdiri dari 2 hingga 128 karakter, dan dapat berisi huruf, angka, titik (.), garis bawah (_), dan tanda hubung (-). Nama harus diawali dengan huruf. |
testGwlbName |
| VpcId |
string |
Yes |
ID virtual private cloud (VPC). |
vpc-uf6qcgpv22ttrnnjh**** |
| ZoneMappings |
array<object> |
Yes |
Pemetaan antara zona dan vSwitch. Anda harus menentukan setidaknya satu zona. Anda dapat menentukan paling banyak 20 zona. Jika wilayah mendukung dua zona atau lebih, tentukan setidaknya dua zona. |
|
|
object |
No |
|||
| VSwitchId |
string |
Yes |
The ID of the vSwitch in the zone. You can specify only one vSwitch (subnet) in each zone of a GWLB instance. |
vsw-2f0eb020**** |
| ZoneId |
string |
Yes |
The zone ID. You can call the DescribeZones operation to query the most recent zone list. |
cn-hangzhou-a |
| Tag |
array<object> |
No |
Tag yang ditambahkan ke instans. |
|
|
object |
No |
The tag. You can specify up to 20 tags in each call. |
||
| Key |
string |
No |
The tag key. The tag key cannot be an empty string. It can be up to 128 characters in length, cannot start with |
testTagKey |
| Value |
string |
No |
The tag value. It can be up to 256 characters in length and cannot contain |
testTagValue |
| ResourceGroupId |
string |
No |
ID kelompok sumber daya. |
rg-acfmwbufq6q3**** |
| DryRun |
boolean |
No |
Apakah akan menjalankan dry run, tanpa menjalankan permintaan aktual. Nilai valid:
|
false |
| ClientToken |
string |
No |
Token klien yang digunakan untuk memastikan idempotensi permintaan. Anda dapat menggunakan klien untuk menghasilkan token, tetapi Anda harus memastikan bahwa token tersebut unik di antara permintaan yang berbeda. Token klien hanya dapat berisi karakter ASCII. Catatan
Jika Anda tidak menentukan parameter ini, sistem secara otomatis menggunakan request ID sebagai token klien. Request ID mungkin berbeda untuk setiap permintaan. |
123e4567-e89b-12d3-a456-426655440000 |
Elemen respons
|
Element |
Type |
Description |
Example |
|
object |
|||
| LoadBalancerId |
string |
The GWLB instance ID. |
gwlb-9njtjmqt7zfcqm**** |
| RequestId |
string |
The request ID. |
00B19438-66BB-58C3-8C2F-DA5B6F95CBDA |
Contoh
Respons sukses
JSONformat
{
"LoadBalancerId": "gwlb-9njtjmqt7zfcqm****",
"RequestId": "00B19438-66BB-58C3-8C2F-DA5B6F95CBDA"
}
Kode kesalahan
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | DuplicatedParam.ZoneId | The param of ZoneId is duplicated. | Duplicate ZoneId parameter in list |
| 400 | OperationDenied.VSwitchNotSupportIpv6 | The operation is not allowed because of VSwitchNotSupportIpv6. | The operation is not allowed because IPv6 is not enabled for the vSwitch. |
| 400 | ResourceNotEnough.VSwitchIp | The specified resource of VSwitchIp is not enough. | Insufficient vSwitch IP resources |
| 400 | DuplicatedParam.VSwitchId | The param of VSwitchId is duplicated. | Duplicate vSwitchId parameter in list |
| 400 | IllegalParamSize.ZoneMappings | The param size of ZoneMappings is illegal. | Illegal number of ZoneMappings lists |
| 400 | Mismatch.ZoneIdAndVSwitchId | The ZoneId and VSwitchId are mismatched. | The value of the ZoneId parameter does not match that of the vSwitchId |
| 400 | QuotaExceeded.LoadBalancersNum | The quota of %s is exceeded for resource %s, usage %s/%s. | The quota gwlb_quota_loadbalancers_num has exceeded the quota limit. |
| 400 | DuplicatedParam.TagKey | The param of %s is duplicated. | The parameter of tag key is duplicated. |
| 400 | IllegalParam.TagKey | The param of %s is illegal. |
Lihat Error Codes untuk daftar lengkap.
Catatan rilis
Lihat Release Notes untuk daftar lengkap.