全部產品
Search
文件中心

Resource Orchestration Service:ALIYUN::CDDC::DedicatedHost

更新時間:Jun 25, 2024

ALIYUN::CDDC::DedicatedHost類型用於添加專屬叢集主機。

關於專屬叢集的更多資訊,請參見什麼是雲資料庫專屬叢集MyBase

文法

{
  "Type": "ALIYUN::CDDC::DedicatedHost",
  "Properties": {
    "HostClass": String,
    "OsPassword": String,
    "ZoneId": String,
    "DedicatedHostGroupId": String,
    "AutoRenew": String,
    "VSwitchId": String,
    "UsedTime": String,
    "ImageCategory": String,
    "Period": String,
    "PaymentType": String,
    "HostName": String,
    "Tags": List
  }
}

屬性

屬性名稱

類型

必須

允許更新

描述

約束

DedicatedHostGroupId

String

目標專屬叢集ID。

HostClass

String

主機的規格。

更多資訊,請參見主機規格詳情

PaymentType

String

主機的付費類型。

取值:PrePaid,表示預付費,即訂用帳戶。

VSwitchId

String

交換器的ID。

ZoneId

String

可用性區域ID。

取值樣本:cn-hangzhou-i,其中cn-hangzhou為地區資訊。

您可以調用DescribeRegions介面查詢地區資訊。

AutoRenew

String

是否開啟自動續約功能。

取值:

  • true:開啟。

  • false(預設值):關閉。

HostName

String

主機的名稱。

長度為1~64個字元,以英文字母或漢字開頭,可包含英文字母、漢字、數字、底線(_)和短劃線(-)。

ImageCategory

String

主機的鏡像。

取值:

  • WindowsWithMssqlEntAlwaysonLicense:SQL Server叢集版。

  • WindowsWithMssqlStdLicense:SQL Server標準版。

  • WindowsWithMssqlEntLicense:SQL Server企業版。

  • WindowsWithMssqlWebLicense:SQL Server Web版。

  • AliLinux:其他主機鏡像。

OsPassword

String

主機的密碼。

僅叢集類型為私人部署叢集時,支援建立主機密碼。

長度為8~30個字元。必須至少包含大寫英文字母、小寫英文字母、數字和特殊字元其中三項,支援的特殊字元為()\~!@#$%^&*-_+=|{}[]:;'<>,.?/

Period

String

主機的預付費周期。

取值:

  • Year:包年。

  • Month:包月。

  • Week:包周。

Tags

List

標籤。

更多資訊,請參見Tags屬性

UsedTime

String

購買時間長度。

取值範圍:

  • 當Period取值為Year時:1~5。

  • 當Period取值為Month時:1~9。

  • 當Period取值為Week時:1~3。

Tags文法

"Tags": [
  {
    "TagKey": String,
    "TagValue": String
  }
]

Tags屬性

屬性名稱

類型

必須

允許更新

描述

約束

TagKey

String

標籤鍵。

長度為1~128個字元,不能以aliyunacs:開頭,不能包含http://https://

TagValue

String

標籤值。

長度為0~128個字元,不能以aliyunacs:開頭,不能包含http://https://

傳回值

Fn::GetAtt

  • DiskAllocationRatio:磁碟使用率,單位為百分比。

  • DedicatedHostId:專屬叢集主機ID。

  • MemAllocationRatio:記憶體使用量率,單位為百分比。

  • ZoneId:可用性區域ID。

  • DedicatedHostGroupId:目標專屬叢集ID。

  • AutoRenew:是否開啟自動續約功能。

  • VSwitchId:交換器ID。

  • ImageCategory:主機的鏡像類型。

  • HostStorage:主機的儲存總量,單位為GB。

  • StorageUsed:儲存使用量,單位為GB。

  • OpenPermission:主機的作業系統許可權開放狀態。

  • HostType:主機的儲存類型。

  • HostClass:主機的規格。

  • HostCpu:主機CPU。

  • VpcId:專用網路ID。

  • EcsClassCode:ECS規格代碼。

  • CpuAllocationRatio:CPU使用率。

  • HostMem:主機的記憶體。

  • PaymentType:付費類型。

  • MemoryUsed:記憶體使用量量,單位為GB。

  • IpAddress:主機的IP地址。

  • CpuUsed:CPU使用量,單位為核。

  • HostName:主機的名稱。

樣本

YAML格式

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  HostClass:
    Type: String
    Description: Host Class
    Default: rds.i2g.2xlarge
  OsPassword:
    Type: String
    Default: Password123
  ZoneId:
    Type: String
    Description: Zone ID
    Default: cn-hangzhou-i
  DedicatedHostGroupId:
    Type: String
    Description: Dedicated Host Group ID
    Default: dhg-23h5e2axmuf4****
  VSwitchId:
    Type: String
    AssociationProperty: ALIYUN::ECS::VSwitch::VSwitchId
    AssociationPropertyMetadata:
      ZoneId: ${ZoneId}
  PaymentType:
    Type: String
    Description: Payment Type
    Default: PrePaid
Resources:
  CDDCDedicatedHost:
    Type: ALIYUN::CDDC::DedicatedHost
    Properties:
      HostClass:
        Ref: HostClass
      OsPassword:
        Ref: OsPassword
      ZoneId:
        Ref: ZoneId
      DedicatedHostGroupId:
        Ref: DedicatedHostGroupId
      VSwitchId:
        Ref: VSwitchId
      PaymentType:
        Ref: PaymentType
Outputs:
  DiskAllocationRatio:
    Description: Disk Allocation Ratio
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - DiskAllocationRatio
  DedicatedHostId:
    Description: The first ID of the resource
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - DedicatedHostId
  MemAllocationRatio:
    Description: Memory Allocation Ratio
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - MemAllocationRatio
  ZoneId:
    Description: Zone ID
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - ZoneId
  DedicatedHostGroupId:
    Description: Dedicated Host Group ID
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - DedicatedHostGroupId
  AutoRenew:
    Description: Whether Auto Renew
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - AutoRenew
  VSwitchId:
    Description: VSwitch ID
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - VSwitchId
  ImageCategory:
    Description: Host Image Category
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - ImageCategory
  HostStorage:
    Description: Host Storage
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - HostStorage
  StorageUsed:
    Description: Storage Used
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - StorageUsed
  OpenPermission:
    Description: Whether Open OS Permission
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - OpenPermission
  HostType:
    Description: Host Storage Type
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - HostType
  HostClass:
    Description: Host Class
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - HostClass
  HostCpu:
    Description: Host CPU
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - HostCpu
  VpcId:
    Description: VPC ID
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - VpcId
  EcsClassCode:
    Description: ECS Class Code
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - EcsClassCode
  CpuAllocationRatio:
    Description: CPU Allocation Ratio
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - CpuAllocationRatio
  HostMem:
    Description: Host Memory
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - HostMem
  PaymentType:
    Description: Payment Type
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - PaymentType
  MemoryUsed:
    Description: Host Memory Used
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - MemoryUsed
  IpAddress:
    Description: Host IP Address
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - IpAddress
  CpuUsed:
    Description: CPU Used
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - CpuUsed
  HostName:
    Description: Host Name
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHost
        - HostName

JSON格式

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "HostClass": {
      "Type": "String",
      "Description": "Host Class",
      "Default": "rds.i2g.2xlarge"
    },
    "OsPassword": {
      "Type": "String",
      "Default": "Password123"
    },
    "ZoneId": {
      "Type": "String",
      "Description": "Zone ID",
      "Default": "cn-hangzhou-i"
    },
    "DedicatedHostGroupId": {
      "Type": "String",
      "Description": "Dedicated Host Group ID",
      "Default": "dhg-23h5e2axmuf4****"
    },
    "VSwitchId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::VSwitch::VSwitchId",
      "AssociationPropertyMetadata": {
        "ZoneId": "${ZoneId}"
      }
    },
    "PaymentType": {
      "Type": "String",
      "Description": "Payment Type",
      "Default": "PrePaid"
    }
  },
  "Resources": {
    "CDDCDedicatedHost": {
      "Type": "ALIYUN::CDDC::DedicatedHost",
      "Properties": {
        "HostClass": {
          "Ref": "HostClass"
        },
        "OsPassword": {
          "Ref": "OsPassword"
        },
        "ZoneId": {
          "Ref": "ZoneId"
        },
        "DedicatedHostGroupId": {
          "Ref": "DedicatedHostGroupId"
        },
        "VSwitchId": {
          "Ref": "VSwitchId"
        },
        "PaymentType": {
          "Ref": "PaymentType"
        }
      }
    }
  },
  "Outputs": {
    "DiskAllocationRatio": {
      "Description": "Disk Allocation Ratio",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "DiskAllocationRatio"
        ]
      }
    },
    "DedicatedHostId": {
      "Description": "The first ID of the resource",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "DedicatedHostId"
        ]
      }
    },
    "MemAllocationRatio": {
      "Description": "Memory Allocation Ratio",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "MemAllocationRatio"
        ]
      }
    },
    "ZoneId": {
      "Description": "Zone ID",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "ZoneId"
        ]
      }
    },
    "DedicatedHostGroupId": {
      "Description": "Dedicated Host Group ID",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "DedicatedHostGroupId"
        ]
      }
    },
    "AutoRenew": {
      "Description": "Whether Auto Renew",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "AutoRenew"
        ]
      }
    },
    "VSwitchId": {
      "Description": "VSwitch ID",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "VSwitchId"
        ]
      }
    },
    "ImageCategory": {
      "Description": "Host Image Category",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "ImageCategory"
        ]
      }
    },
    "HostStorage": {
      "Description": "Host Storage",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "HostStorage"
        ]
      }
    },
    "StorageUsed": {
      "Description": "Storage Used",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "StorageUsed"
        ]
      }
    },
    "OpenPermission": {
      "Description": "Whether Open OS Permission",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "OpenPermission"
        ]
      }
    },
    "HostType": {
      "Description": "Host Storage Type",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "HostType"
        ]
      }
    },
    "HostClass": {
      "Description": "Host Class",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "HostClass"
        ]
      }
    },
    "HostCpu": {
      "Description": "Host CPU",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "HostCpu"
        ]
      }
    },
    "VpcId": {
      "Description": "VPC ID",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "VpcId"
        ]
      }
    },
    "EcsClassCode": {
      "Description": "ECS Class Code",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "EcsClassCode"
        ]
      }
    },
    "CpuAllocationRatio": {
      "Description": "CPU Allocation Ratio",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "CpuAllocationRatio"
        ]
      }
    },
    "HostMem": {
      "Description": "Host Memory",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "HostMem"
        ]
      }
    },
    "PaymentType": {
      "Description": "Payment Type",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "PaymentType"
        ]
      }
    },
    "MemoryUsed": {
      "Description": "Host Memory Used",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "MemoryUsed"
        ]
      }
    },
    "IpAddress": {
      "Description": "Host IP Address",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "IpAddress"
        ]
      }
    },
    "CpuUsed": {
      "Description": "CPU Used",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "CpuUsed"
        ]
      }
    },
    "HostName": {
      "Description": "Host Name",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHost",
          "HostName"
        ]
      }
    }
  }
}