Check UHost resource capacity - CheckUHostResourceCapacity
Overview
Check the remaining configuration resources of UHost
Definition
Public Parameters
| Parameter Name | Type | Description Information | Required |
|---|---|---|---|
| Action | string | Corresponding API command name, the current API is CheckUHostResourceCapacity. | Yes |
| PublicKey | string | The user’s public key can be obtained from Console | Yes |
| Signature | string | User signature generated based on public key and API command, see Signature Algorithm | Yes |
Request Parameters
| Parameter Name | Type | Description Information | Required |
|---|---|---|---|
| Region | string | Region. See Region and Availability Zone List | Yes |
| Zone | string | Zone. See Zone List | Yes |
| ProjectId | string | Project ID. If not filled in, it will be set as the default project. Sub-account must be filled in. Please refer to the GetProjectList API | No |
| ImageId | string | Image ID. Please obtain it through DescribeImage | Yes |
| Disks.N.IsBoot | string | Is it a system disk. Enumeration values: > True, it is a system disk > False, it is a data disk (default). There must be exactly one disk in the Disks array that is a system disk. | Yes |
| Disks.N.Type | string | Disk type. Please refer to Disk type. | Yes |
| Disks.N.Size | int | Disk size, in GB. Please refer to Disk type. | Yes |
| Disks.N.BackupType | string | Disk backup scheme. Enumeration values: > NONE, no backup > DATAARK, data ark > SNAPSHOT, snapshot The backup modes supported by the current disk refer to disk type, default value: NONE | No |
| Disks.N.CouponId | string | Cloud disk voucher id. Not applicable to system disk/local disk. Please query through the DescribeCoupon interface, or log in to the user center to view | No |
| Disks.N.BackupMode | string | Specify the snapshot backup strategy. This parameter takes effect when Disks.N.BackupType is set to “SNAPSHOT”. Enumeration values: “Lite”: Lite version, “Base”: Basic version, “Ultimate”: Ultimate version, “Custom”: Custom backup chain; default value: “Base” | No |
| Disks.N.CustomBackup.Journal | string | When Disks.N.BackupMode is set to “Custom”, perform settings based on multiples of 12 hours, such as 12, 24, 36, and 48. | No |
| Disks.N.CustomBackup.Hour | string | When Disks.N.BackupMode is set to “Custom”, the setting is made based on a 24-hour interval, with multiples expanded, such as 24, 48, 72, and 96. | No |
| Disks.N.CustomBackup.Day | string | When Disks.N.BackupMode is set to “Custom”, perform settings based on a 5-day interval and multiply it by a factor, such as 5, 10, 15, 20, 25, or 30. | No |
| Disks.N.SnapshotId | string | The snapshot ID used when creating a disk from a snapshot currently only supports data disks | No |
| ChargeType | string | Billing mode. The enumeration values are: > Year, paid annually; > Month, paid monthly; > Dynamic, prepaid hourly; > Postpay, postpaid hourly (shutdown free of charge, currently supported in some availability zones only, please contact your customer manager); > Spot billing for spot instances (in beta phase); default is monthly payment | No |
| CPU | int | Number of virtual CPU cores. Optional parameter: 1-64 (refer to the console for the specific mapping between machine types and CPUs). Default value: 4. | No |
| Memory | int | Memory size. Unit: MB. Range: [1024, 262144], values are multiples of 1024 (refer to the console for optional range). Default value: 8192 | No |
| GpuType | string | GPU type, enumeration values [“K80”, “P40”, “V100”, “T4”, “T4A”, “T4S”, “2080Ti”, “2080Ti-4C”, “1080Ti”, “T4/4”, “MI100”, “V100S”, “2080”, “2080TiS”, “2080TiPro”, “3090”, “A100”, “4090”, “4090Pro”, “4090_48G”, “5090”], required when MachineType is G | No |
| GPU | int | Number of GPU card cores. This field is only supported for GPU-based machine types (the optional range is related to MachineType+GpuType) | No |
| NetCapability | string | Network Enhancement Feature. Enumeration values: Normal, not enabled; Super, enable Network Enhancement 1.0; Ultra, enable Network Enhancement 2.0 (For details, refer to the official website documentation) | No |
| HotplugFeature | boolean | Hot upgrade feature. True indicates enabled, False indicates disabled, and the default is False. | No |
| IsolationGroup | string | Hardware isolation group ID. It can be obtained through DescribeIsolationGroup. | No |
| MachineType | string | For the virtual machine type (V2.0), only one of this field and field UHostType is required. The enumeration values are [“N”, “C”, “G”, “O”, “OS”, “OM”, “OPRO”, “OMAX”, “O.BM”, “O.EPC”]. Please refer to Virtual Machine Type Description. | No |
| MinimalCpuPlatform | string | Minimum CPU platform, enumeration values [“Intel/Auto”, “Intel/IvyBridge”, “Intel/Haswell”, “Intel/Broadwell”, “Intel/Skylake”, “Intel/Cascadelake”, “Intel/CascadelakeR”, “Intel/IceLake”, “Amd/Epyc2”, “Amd/Auto”, “Ampere/Auto”, “Ampere/Altra”], with the default value being “Intel/Auto”. | No |
| MaxCount | int | The maximum number of hosts created this time has a value range of [1,100], with a default value of 1. | No |
| Features.UNI | boolean | Elastic network interface feature. This feature becomes effective only when the elastic network interface permission bit is enabled. The default setting is false, indicating it is not enabled. When true, it is enabled. It is only compatible with NetCapability Normal. | No |
| SecurityMode | string | Host security mode. Firewall: firewall; SecGroup: security group; Default: firewall. | No |
| UHostFamily | string | Specification family. Consisting of a model code and a CPU platform, it is used to specify the hardware type and processor platform of a cloud host. When MachineType is “O” (O-type), the following values are supported: o1i: QuickStep O1 generation, Intel platform o1a: FastJet O1 generation, AMD platform o1r: Fast and Efficient O1 Generation, ARM Platform o2i: QuickJet O2 generation, Intel platform Default value: o1i or o1a (the system will automatically choose based on resource availability) When MachineType is “OM” (Omni-shared), the following values are supported: om1i: FastJet Memory Enhanced OM1 Generation, Intel Platform om2i: FastJet Memory Enhanced OM2 Generation, Intel Platform ⚠️ Note: The specification family must match the MachineType, otherwise the request will be rejected. | No |
| MinCount | int | The minimum number of hosts to create this time has a value range of [1,100], with a default value of 1. | No |
Response Field
| Field Name | Type | Description Information | Required |
|---|---|---|---|
| RetCode | int | Return status code. If it is 0, it means successful return. If it is not 0, it means failure. | Yes |
| Action | string | Operation command name. | Yes |
| Message | string | Returns an error message, providing detailed description when RetCode is non-zero. | No |
| ResourceEnough | boolean | Resource is enough | No |
| RdmaClusterIds | array[string] | The RdmaClusterId array corresponding to the random resource. If the resource is insufficient, it will be empty. Only the KJ series models and A800 may have this field | No |
Example
Request Example
https://api.surfercloud.com/?Action=CheckUHostResourceCapacity
&Region=yrhcTIkN
&Zone=RTUmtdBU
&ProjectId=aFwMOPWe
&ImageId=ruVbIOch
&Disks.N.IsBoot=gKJVxkeX
&Disks.N.Type=OqRcseqx
&Disks.N.Size=6
&LoginMode=OifhVpnR
&Password=PrNAnpTZ
&Name=arqiAbYy
&Tag=isFaWptf
&ChargeType=JMlYuMUL
&Quantity=2
&UHostType=hAYJSdHH
&CPU=8
&Memory=4
&GpuType=tnzkTaQe
&GPU=9
&StorageType=SiIWRbfM
&BootDiskSpace=2
&DiskSpace=3
&NetCapability=OZYggYJp
&TimemachineFeature=yes
&HotplugFeature=true
&DiskPassword=EilAQtUD
&NetworkId=RbGBaRkB
&VPCId=nJhYlNOb
&SubnetId=DjWGJOmk
&PrivateIp.N=PBlZkKsG
&PrivateMac=rGdLvUID
&SecurityGroupId=slPJvzMj
&HostType=vTqwVJAH
&InstallAgent=WXdwITJq
&ResourceType=sqWRzKIQ
&Disks.N.BackupType=HRhYZxzi
&IsolationGroup=clmfdFLB
&Disks.N.Encrypted=false
&Disks.N.KmsKeyId=nPdTWgSu
&Disks.N.CouponId=pzCdPilE
&AlarmTemplateId=1
&MachineType=ghDhssxZ
&MinimalCpuPlatform=ZwIYLzag
&MaxCount=8
&NetworkInterface.N.EIP.Bandwidth=4
&NetworkInterface.N.EIP.PayMode=jCldwuLw
&NetworkInterface.N.EIP.ShareBandwidthId=WzUVKNyc
&NetworkInterface.N.EIP.OperatorName=olWGnMJQ
&NetworkInterface.N.EIP.CouponId=jTBAXgPS
&SetId=3
&HostIp=SIRCXOSm
&NetworkInterface.N.IPv6.ShareBandwidthId=dbeXTCKs
&UserData=lvaELEkM
&Disks.N.Id=GXsgZDcp
&AutoDataDiskInit=SLfEFjiW
&NetworkInterface.N.IPv6.Address=jfKSnEKH
&CharacterName=COePftry
&PromotionId=FgbFbSsI
&ImageOsName=ONVimjaE
&PodId=PFxmFtRE
&BillActivityId=7
&BillActivityRuleId=5
&RestrictMode=UbnnCGVz
&Volumes.N.Type=iDyfOtNp
&Volumes.N.IsBoot=VOLsVJUt
&Volumes.N.Size=8
&Volumes.N.VolumeId=sRAqdPdc
&Volumes.N.CouponId=KMumcwIf
&HpcEnhanced=true
&NetworkInterface.N.CreateCernetIp=false
&KeyPairId=zuBajawQ
&Features.UNI=true
&Disks.N.BackupMode=peDmjWzg
&Disks.N.CustomBackup.Journal=ZjGVleal
&Disks.N.CustomBackup.Hour=aLrCWdGU
&Disks.N.CustomBackup.Day=EkPpEDez
&SecGroupId.N.Id=sKHFDbkJ
&SecGroupId.N.Priority=3
&SecurityMode=EDocrOUM
&UDSetId=SWidLJSg
&UDHostId=AHmYPuis
&HostBinding=true
&Disks.N.SnapshotId=pZToDOkj
&CouponId=hzEwaBBa
&MinCount=1
&UHostFamily=zezirASdResponse Example
{
"Action": "CheckUHostResourceCapacityResponse",
"IPs": [
"cdFjKkOy"
],
"MountedUFSId": "twOVPrtX",
"RdmaClusterIds": [
"BXhwDYBZ"
],
"ResourceEnough": false,
"RetCode": 0,
"UHostIds": [
"rpovxuRq"
]
}