When you have one or more dedicated hosts, you can create an Elastic Compute Service (ECS) instance on a dedicated host. The specifications of the ECS instance and the dedicated host must be the same.

Prerequisites

Before you create an ECS instance on a dedicated host, follow these steps:
  • Create a dedicated host. For more information, see Create a dedicated host.
  • If you create an ECS instance a region inside mainland China, you must complete real-name registration. For more information, see Real-name registration.
  • In the target region where the dedicated host resides, create an IPv4 virtual private cloud (VPC). For more information, see Create an IPv4 VPC.
  • If you do not use the default security group provided by the system, you must create a security group in the target region and specify security group rules according to your business needs. For more information, see Create a security group and Add security group rules.
  • If you want to bind an SSH key pair to a Linux instance, you must create an SSH key pair in the target region. For more information, see Use an SSH key pair.
  • To configure user data, you must prepare the user data of the instance. For more information, see User data.
  • If you want the instance to assume a RAM role, you must create the instance RAM role and associate the role to the instance. For more information, see Bind an instance RAM role.

Background information

Only VPC-connected ECS instances can be created on a dedicated host. ECS instances on a dedicated host differ from ECS instances on a shared host. For more information, see Comparison of ECS instances on different hosts.

Procedure

  1. Log on to the ECS console.
  2. In the left-side navigation pane, choose Instances & Images > Dedicated Hosts.
  3. In the top navigation bar, select a region.
  4. Find the dedicated host on which you want to create the instance. In the Operations column, click Create Instance.
  5. Complete the Basic Configurations.
    1. Select a Dedicated Host.
      The default value is the original dedicated host that you selected. You can select a different dedicated host.
    2. Set the Associate with DDH feature.
      • If you select Associate with DDH: When a stopped instance is restarted, it is still deployed on the current dedicated host. If the resources of the current dedicated host are insufficient, the instance fails to be restarted.
      • If you clear Associate with DDH: When a stopped instance is restarted and the resources of the current dedicated host are insufficient, the instance is automatically deployed on another dedicated host that meets the deployment conditions in your account. For more information, see Host association.
    3. Select a Billing Method.

      Select an ECS instance billing method based on the billing method of the dedicated host. For a subscription dedicated host, you can select Subscription or Pay-As-You-Go as the billing method for the ECS instance.

    4. Confirm the Region.
      The ECS instance and the dedicated host must share the same region and zone.
    5. Select an instance type and set the number of instances.
      The available instance types are based on the specifications and available resources of the dedicated host. For more information about dedicated host specifications, see Dedicated host types.
    6. Select an image for the instance.
      You can select a public image, custom image, shared image, or marketplace image. For more information about how to select an image, see Select an image.
      Note
      • If you want to use an SSH key pair, you must select Linux.
      • If you want to set user data for the instance, you can only select specific images. For more information, see Manage user data.
    7. Select the storage for the instance.
      • System Disk: It is used to install the operating system. You must set the system disk. Specify the category and capacity of the system disk.
        • Disk category: All disk categories available in the current region are displayed.
        • Capacity: The default capacity for the system disk is 40 GiB, and the maximum capacity is 500 GiB. If the selected image size is larger than 40 GiB, the image size is the default capacity. The following table lists the capacity range of the system disks based on the images.
          Operating system System disk capacity
          Linux (excluding CoreOS) and FreeBSD [Max {20, image size}, 500] GiB
          CoreOS [Max {30, image size}, 500] GiB
          Windows [Max {40, image size}, 500] GiB
      • Data Disk: To add a data disk, you must select the disk category, capacity, and quantity. You can select whether to enable Disk Encryption. You can create an empty data disk or use a snapshot to create a data disk. You can add a maximum of 16 data disks.
        Note The created disks have the following characteristics:
        • The billing method of the disks and the instance must be the same.
        • A subscription data disk can only be released along with the instance. You can also set the pay-as-you-go data disk to be released along with the instance.
      • If you create an instance from an instance family with local SSDs attached (such as i2), you cannot configure the disks, the disk configuration of the instance type is displayed instead. For more information about local SSDs, see Instance families.
    8. Click Next: Networking.
  6. Complete the Networking configurations.
    1. Select a Network Type.
      You can only select VPC as the network type. Select a VPC and VSwitch. If you have not created a VPC or VSwitch, you can use the default VPC or VSwitch.
    2. Set the Network Billing Method.
      • If you want to assign a public IP address to the created instance, you must select Assign Public IP Address. Then, select Pay-By-Traffic as the billing method of public bandwidth, and specify the bandwidth. The public IP address that is assigned this way cannot be unbound from the instance. For more information about the billing method of public bandwidth, see Billing of Internet bandwidth.
      • If your instance does not access the public network or it uses an Elastic IP Address (EIP), do not select Assign Public IP Address.
    3. Select a Security Group.
      Specify the rules of the selected security group according to your business needs.
      Note If you have not created a security group, you can use the default security group. For more information about the rules of the default security group, see Default security group rules.
    4. Add an ENI.
      If the selected instance type supports ENIs, you can add an ENI and select a VSwitch for the ENI.
      Note The ENI is released along with the instance by default. You can also call the DetachNetworkInterface operation to detach the instance from the ENI.
    5. Click Next: System Configurations.
  7. Optional: Complete the System Configurations.
    1. Select and set the Logon Credentials.
      You can set the password directly, or select Set Later and set the password after you create the instance. Select a logon credential based on the operating system of the image.
      • Linux: You can use either a key pair or password as the logon credential.
      • Windows: Only a password can be used as the logon credential.
    2. Set the Instance Name and Host.
    3. Set the Advanced configurations.
      • RAM Role: You can assign a RAM role to the instance.
      • User Data: You can customize the startup behavior of an instance or pass data to the instance.
    4. Click Next: Grouping.
  8. Optional: Complete the Grouping configurations.

    If you have multiple instances, we recommend that you add tags to the instances to better identify and manage the instances.

  9. Confirm the order and create the instance.
    1. In the Configurations Selected section, confirm the configurations of the instance.
      You can click the icon icon to change the configuration.
    2. If the instance billing method is Pay-As-You-Go, you can select Automatic Release to set the automatic release time of the instance.
    3. If the instance billing method is Subscription, you can set the duration of the subscription, and select whether to enable Auto-renewal.
      Note The end date of the subscription for the instance cannot be later than the expiration date of the dedicated host.
    4. Confirm the Total cost. The displayed fees include system disks, data disks (if any), and Internet bandwidth.
    5. Read and agree to the ECS Terms of Service.
    6. Click Create Instance.

Result

After the instance is created, click Console to go back to the ECS console. You can view the new ECS instance. In the Instances list, you can view the instance ID, public IP address, private IP address, and other information about the new instance. If you have set Column Filters, you can also view the host information of the ECS instance.
Note For more information about Column Filters, see Migrate ECS instances between different dedicated hosts.

What to do next