Creates a host in a dedicated cluster.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
cddc:CreateDedicatedHost |
create |
*All Resource
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| DedicatedHostGroupId |
string |
Yes |
The ID of the destination cluster. You can view dedicated cluster ID on the Clusters page in the ApsaraDB for MyBase console. Note
The database engine of the host must be the same as that of dedicated cluster. |
dhg-6w7q18iwt5jo**** |
| HostClass |
string |
Yes |
The instance type of the host. For more information about the host instance types supported by different database engines, see Host instance types. |
rds.g6.4xlarge |
| PayType |
string |
Yes |
The billing method of the host. Valid value: prepaid (subscription). |
prepaid |
| Period |
string |
No |
The subscription period of the host. Valid values:
|
Month |
| UsedTime |
string |
No |
The subscription duration. Valid values:
|
1 |
| ClientToken |
string |
Yes |
The client token that is used to ensure the idempotence of the request and prevent duplicate submissions. You can use the client to generate the token. The token can contain only ASCII characters and cannot exceed 64 characters in length. |
ETnLKlblzczshOTUbOCzSBZH8**** |
| AutoRenew |
string |
No |
Specifies whether to enable auto-renewal. Valid values:
Note
Default value: false. |
false |
| ImageCategory |
string |
No |
The host image. Valid values:
Note
When you create a SQL Server host, you must specify the host image that corresponds to the SQL Server edition. |
AliLinux |
| OsPassword |
string |
No |
The password of the host. You can set a host password only when the cluster type is private deployment cluster. The password must meet the following requirements:
|
Test123456 |
| HostStorageType |
string |
No |
The cloud disk type of the host. This parameter takes effect only for Tair hosts. Valid values:
Valid values:
|
cloud_essd0 |
| HostStorage |
string |
No |
The cloud disk size of the host. This parameter takes effect only for Tair hosts. Unit: GB. Valid values:
|
512 |
| RegionId |
string |
Yes |
The region ID of the cluster where the host resides. |
cn-hangzhou |
| ZoneId |
string |
Yes |
The zone ID. You can call the DescribeRegions operation to query zone IDs. |
cn-hangzhou-i |
| VSwitchId |
string |
Yes |
The ID of the vSwitch. You can view the vSwitch ID in the Virtual Private Cloud (VPC) console. |
vsw-bp133c8ifzxd3iv6q**** |
| ClusterType |
string |
No |
The cluster type for ApsaraDB for MyBase Open Edition. Valid values: onACK and onECS. |
onACK |
| ClusterAlias |
string |
No |
The alias of the open cluster. This parameter is used for ApsaraDB for MyBase Open Edition. |
test-on-ack-cluster |
| VpcID |
string |
No |
The ID of the VPC specified for the onECS cluster in ApsaraDB for MyBase Open Edition. |
vpc-xxxxxx |
| ClusterServices |
array |
No |
The services associated with the onECS instance in ApsaraDB for MyBase Open Edition. |
|
|
string |
No |
The services associated with the onECS instance in ApsaraDB for MyBase Open Edition. |
"Orchestrator3.2.6,Promethus2.49.1,Grafana10.2.3" |
|
| MyBaseEcsClass |
object |
No |
The parameters of the onECS instance in ApsaraDB for MyBase Open Edition. |
|
| ChargeType |
string |
No |
The billing method. Valid values:
|
PrePaid |
| EcsClassCode |
string |
No |
The instance type. |
ecs.g7.large |
| Amount |
integer |
No |
The quantity. |
1 |
| Period |
integer |
No |
The subscription period of the onECS host. This parameter is required when ChargeType is set to PrePaid. |
1 |
| PeriodType |
string |
No |
The unit of the subscription period. Default value: Month. |
Month |
| SystemDiskSize |
integer |
No |
The size of the system cloud disk. Unit: GB. |
40 |
| SystemDiskCategory |
string |
No |
The cloud disk type. |
cloud_essd |
| DataDiskSize |
integer |
No |
The size of the data cloud disk. Unit: GB. |
40 |
| DataDiskCategory |
string |
No |
The type of the data cloud disk. |
cloud_essd |
| DataDiskCount |
integer |
No |
The number of data cloud disks. |
2 |
| AutoRenew |
boolean |
No |
Specifies whether to enable auto-renewal. Default value: false. |
false |
| Password |
string |
No |
The password of the ECS host. |
*********** |
| KeyPairName |
string |
No |
The name of the key pair. |
test**** |
| SecurityGroupIds |
array |
No |
The security groups to which the instance belongs. |
|
|
string |
No |
The security group to which the instance belongs. |
sg-uf64zn0tc9qakm2j**** |
|
| Tags |
array |
No |
The tags of the host. |
|
|
string |
No |
The tags of the host. |
{\"key1\":\"value1\"} |
|
| InternetMaxBandwidthOut |
integer |
No |
The maximum outbound public bandwidth. Unit: Mbit/s. Default value: 0. Setting this parameter to a value greater than 0 triggers automatic creation of a public IP address. |
100 |
| InternetChargeType |
string |
No |
The network billing method. Valid values:
|
PayByTraffic |
| DepolymentSetId |
string |
No |
The ID of the deployment set. |
**** |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| OrderId |
integer |
The order ID. |
102565235 |
| RequestId |
string |
The request ID. |
C860658E-68A6-46C1-AF6E-3AE7C4D32375 |
| ClusterName |
string |
The cluster name. |
ca-2ze0x527ovq3y**** |
| DedicateHostList |
object |
||
| DedicateHostList |
array<object> |
The information about the created hosts. |
|
|
object |
|||
| DedicatedHostId |
string |
The ID of the created host. |
ch-bp108dki3wdl6**** |
Examples
Success response
JSON format
{
"OrderId": 102565235,
"RequestId": "C860658E-68A6-46C1-AF6E-3AE7C4D32375",
"ClusterName": "ca-2ze0x527ovq3y****",
"DedicateHostList": {
"DedicateHostList": [
{
"DedicatedHostId": " ch-bp108dki3wdl6****"
}
]
}
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | InvalidParameter | The parameter is invalid. | |
| 400 | COMMODITY.INVALID_COMPONENT | Invalid component. | |
| 400 | InvalidAccountPassword.Format | The account password format is invalid. | The account password format is invalid. |
| 400 | InsufficientResourceCapacity | No host is available for the requested instance. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.