ALIYUN::CDDC::DedicatedHostGroup

更新时间:
复制 MD 格式

Creates a dedicated cluster for ApsaraDB for MyBase.

For more information about dedicated clusters, see What is ApsaraDB for MyBase?

Syntax

{
  "Type": "ALIYUN::CDDC::DedicatedHostGroup",
  "Properties": {
    "DiskAllocationRatio": Integer,
    "AllocationPolicy": String,
    "VpcId": String,
    "MemAllocationRatio": Integer,
    "HostReplacePolicy": String,
    "CpuAllocationRatio": Integer,
    "Engine": String,
    "DedicatedHostGroupDesc": String,
    "OpenPermission": String
  }
}

Properties

Property

Type

Required

Editable

Description

Constraint

Engine

String

Yes

No

The database engine type.

Valid values:

  • MySQL

  • SQLServer

  • PostgreSQL

  • Redis

VpcId

String

Yes

No

The ID of the virtual private cloud (VPC) in which the dedicated cluster resides.

None.

AllocationPolicy

String

No

Yes

The resource allocation policy for hosts in the dedicated cluster.

Valid values:

  • Evenly (default): Preferentially allocates resources to hosts with no or fewer allocated resources, maximizing system stability.

  • Intensively: Preferentially allocates resources to hosts created earlier with more allocated resources, maximizing resource utilization.

CpuAllocationRatio

Integer

No

Yes

The CPU overcommit ratio of the dedicated cluster.

Valid values: 100 to 300. Unit: percentage.

Default value: 200, which means the allocatable CPU resources are twice the physical CPU resources, maximizing resource utilization.

DedicatedHostGroupDesc

String

No

Yes

The name of the dedicated cluster.

The name must be 1 to 64 characters in length and can contain letters, digits, underscores (_), and hyphens (-). It must start with a letter.

DiskAllocationRatio

Integer

No

Yes

The storage overcommit ratio of the dedicated cluster.

Valid values: 100 to 300. Unit: percentage.

Default value: 200, which means the allocatable storage resources are twice the physical storage resources, maximizing resource utilization.

HostReplacePolicy

String

No

Yes

The host failure handling policy.

Valid values:

  • Auto (default): Faulty hosts are automatically replaced.

  • Manual: Faulty hosts must be manually replaced.

Note

You can set this property to either value only when the dedicated cluster runs the MySQL database engine. For other database engines, this property must be set to Auto.

MemAllocationRatio

Integer

No

Yes

The memory overcommit ratio of each host in the dedicated cluster.

Valid values: 0 to 100. Unit: percentage.

Default value: 100.

OpenPermission

String

No

Yes

Whether to grant host OS permissions.

Valid values:

  • 0

  • 1 (default)

Return values

Fn::GetAtt

  • DeployType: the instance deployment mode.

  • DiskAllocationRatio: the storage overcommit ratio of the host.

  • DiskUsedAmount: the used disk size.

  • InstanceNumber: the number of instances on the host.

  • AllocationPolicy: the resource allocation policy for hosts in the dedicated cluster.

  • HostReplacePolicy: the host failure handling policy.

  • DedicatedHostGroupId: the ID of the dedicated cluster.

  • BastionInstanceId: the ID of the primary instance on the host.

  • MemAllocatedAmount: the allocated memory size.

  • OpenPermission: whether host OS permissions are granted.

  • MemAllocateRation: the memory allocation ratio.

  • DiskAllocatedAmount: the allocated disk size.

  • Engine: the database engine type of the host.

  • MemUtility: the memory usage ratio.

  • MemAllocationRatio: the memory overcommit ratio of the host.

  • CpuAllocateRation: the ratio of requested CPU cores.

  • Text: the description of the host.

  • MemUsedAmount: the used memory size.

  • DedicatedHostGroupDesc: the name of the dedicated cluster.

  • VpcId: the ID of the VPC in which the dedicated cluster resides.

  • DiskUtility: the disk usage ratio.

  • CpuAllocationRatio: the CPU overcommit ratio of the host.

  • DiskAllocateRation: the disk allocation ratio.

  • HostNumber: the number of hosts.

  • CpuAllocatedAmount: the number of requested CPU cores.

Examples

YAML format

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  VpcId:
    Type: String
    Description: VPC ID
    AssociationProperty: ALIYUN::ECS::VPC::VPCId
  Engine:
    Type: String
    Description: Database Engine Type
    Default: MySQL
Resources:
  CDDCDedicatedHostGroup:
    Type: ALIYUN::CDDC::DedicatedHostGroup
    Properties:
      VpcId:
        Ref: VpcId
      Engine:
        Ref: Engine
Outputs:
  DeployType:
    Description: DeployType
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - DeployType
  DiskAllocationRatio:
    Description: Disk Allocation Ratio
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - DiskAllocationRatio
  DiskUsedAmount:
    Description: DiskUsedAmount
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - DiskUsedAmount
  InstanceNumber:
    Description: Total Instance Number
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - InstanceNumber
  AllocationPolicy:
    Description: Allocation Policy
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - AllocationPolicy
  HostReplacePolicy:
    Description: Host Replace Policy
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - HostReplacePolicy
  DedicatedHostGroupId:
    Description: Dedicated Host Group ID
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - DedicatedHostGroupId
  BastionInstanceId:
    Description: BastionInstanceId
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - BastionInstanceId
  MemAllocatedAmount:
    Description: MemAllocatedAmount
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - MemAllocatedAmount
  OpenPermission:
    Description: Whether Open OS Permission
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - OpenPermission
  MemAllocateRation:
    Description: MemAllocateRation
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - MemAllocateRation
  DiskAllocatedAmount:
    Description: DiskAllocatedAmount
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - DiskAllocatedAmount
  Engine:
    Description: Database Engine Type
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - Engine
  MemUtility:
    Description: MemUtility
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - MemUtility
  MemAllocationRatio:
    Description: Memory Allocation Ratio
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - MemAllocationRatio
  CpuAllocateRation:
    Description: CpuAllocateRation
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - CpuAllocateRation
  Text:
    Description: Text
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - Text
  MemUsedAmount:
    Description: MemUsedAmount
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - MemUsedAmount
  DedicatedHostGroupDesc:
    Description: Dedicated Host Group Description
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - DedicatedHostGroupDesc
  VpcId:
    Description: VPC ID
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - VpcId
  DiskUtility:
    Description: DiskUtility
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - DiskUtility
  CpuAllocationRatio:
    Description: Cpu Allocation Ratio
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - CpuAllocationRatio
  DiskAllocateRation:
    Description: DiskAllocateRation
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - DiskAllocateRation
  HostNumber:
    Description: Total Host Number
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - HostNumber
  CpuAllocatedAmount:
    Description: CpuAllocatedAmount
    Value:
      Fn::GetAtt:
        - CDDCDedicatedHostGroup
        - CpuAllocatedAmount

JSON format

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "VpcId": {
      "Type": "String",
      "Description": "VPC ID",
      "AssociationProperty": "ALIYUN::ECS::VPC::VPCId"
    },
    "Engine": {
      "Type": "String",
      "Description": "Database Engine Type",
      "Default": "MySQL"
    }
  },
  "Resources": {
    "CDDCDedicatedHostGroup": {
      "Type": "ALIYUN::CDDC::DedicatedHostGroup",
      "Properties": {
        "VpcId": {
          "Ref": "VpcId"
        },
        "Engine": {
          "Ref": "Engine"
        }
      }
    }
  },
  "Outputs": {
    "DeployType": {
      "Description": "DeployType",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "DeployType"
        ]
      }
    },
    "DiskAllocationRatio": {
      "Description": "Disk Allocation Ratio",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "DiskAllocationRatio"
        ]
      }
    },
    "DiskUsedAmount": {
      "Description": "DiskUsedAmount",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "DiskUsedAmount"
        ]
      }
    },
    "InstanceNumber": {
      "Description": "Total Instance Number",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "InstanceNumber"
        ]
      }
    },
    "AllocationPolicy": {
      "Description": "Allocation Policy",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "AllocationPolicy"
        ]
      }
    },
    "HostReplacePolicy": {
      "Description": "Host Replace Policy",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "HostReplacePolicy"
        ]
      }
    },
    "DedicatedHostGroupId": {
      "Description": "Dedicated Host Group ID",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "DedicatedHostGroupId"
        ]
      }
    },
    "BastionInstanceId": {
      "Description": "BastionInstanceId",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "BastionInstanceId"
        ]
      }
    },
    "MemAllocatedAmount": {
      "Description": "MemAllocatedAmount",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "MemAllocatedAmount"
        ]
      }
    },
    "OpenPermission": {
      "Description": "Whether Open OS Permission",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "OpenPermission"
        ]
      }
    },
    "MemAllocateRation": {
      "Description": "MemAllocateRation",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "MemAllocateRation"
        ]
      }
    },
    "DiskAllocatedAmount": {
      "Description": "DiskAllocatedAmount",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "DiskAllocatedAmount"
        ]
      }
    },
    "Engine": {
      "Description": "Database Engine Type",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "Engine"
        ]
      }
    },
    "MemUtility": {
      "Description": "MemUtility",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "MemUtility"
        ]
      }
    },
    "MemAllocationRatio": {
      "Description": "Memory Allocation Ratio",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "MemAllocationRatio"
        ]
      }
    },
    "CpuAllocateRation": {
      "Description": "CpuAllocateRation",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "CpuAllocateRation"
        ]
      }
    },
    "Text": {
      "Description": "Text",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "Text"
        ]
      }
    },
    "MemUsedAmount": {
      "Description": "MemUsedAmount",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "MemUsedAmount"
        ]
      }
    },
    "DedicatedHostGroupDesc": {
      "Description": "Dedicated Host Group Description",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "DedicatedHostGroupDesc"
        ]
      }
    },
    "VpcId": {
      "Description": "VPC ID",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "VpcId"
        ]
      }
    },
    "DiskUtility": {
      "Description": "DiskUtility",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "DiskUtility"
        ]
      }
    },
    "CpuAllocationRatio": {
      "Description": "Cpu Allocation Ratio",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "CpuAllocationRatio"
        ]
      }
    },
    "DiskAllocateRation": {
      "Description": "DiskAllocateRation",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "DiskAllocateRation"
        ]
      }
    },
    "HostNumber": {
      "Description": "Total Host Number",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "HostNumber"
        ]
      }
    },
    "CpuAllocatedAmount": {
      "Description": "CpuAllocatedAmount",
      "Value": {
        "Fn::GetAtt": [
          "CDDCDedicatedHostGroup",
          "CpuAllocatedAmount"
        ]
      }
    }
  }
}