All Products
Search
Document Center

Create ECS clusters

Last Updated: Feb 01, 2019

To create an ECS cluster for an application, you need to complete the following steps:

  1. [Create an ECS cluster]#CreateEmptyECSCluster)
  2. Add ECS instances

When no application is deployed on an ECS instance in a cluster and the ECS instance is no longer needed, you can remove to release the ECS instance.

Create clusters

  1. Log on to the EDAS console.

  2. In the left-side navigation pane, choose Resource Management > Clusters.

  3. On the Clusters page, select Region and Namespace. Then, click Create Instance on the right of the page.

  4. In the Create Cluster dialog box, set the cluster parameters and click Create.

    Create ECS clusters

    Description of cluster parameters:

    • Cluster Name: Enter the cluster name.The name can only contain letters, digits, underscores (_), and periods (.), with a length up to 64 characters.
    • Cluster type: Select ECS.
    • Network Type: Select Classic Network or VPC.Select a network type from the drop-down list as needed.If you select the VPC Network, ensure that you have created a VPC instance first.
    • VPC Network: Select a VPC instance you created from the drop-down list.
    • Namespace: indicates the namespace displayed on the Clusters page, which cannot be modified.If you do not make a selection, the name of the displayed region is selected by default.

    After creating the cluster, you will see the message Created successfully in the upper-right corner of the page, and the cluster is displayed in the cluster list.

Note: The created cluster is empty.Only after you add an ECS instance can you meet the requirements of applications.

Add ECS instances

There are currently two ways of adding ECS instances to a cluster in EDAS:

  • Direct import: Image conversion is not required.
  • Import after conversion: The EDAS official image is used to reinstall the system.After re-installation, all data in the ECS instance is deleted and the ECS instance login password needs to be reset.

An ECS instance cannot be directly imported in any of the following conditions:

  • The ECS instance was created before December 1, 2017.
  • A classic network ECS instance is imported into a classic network cluster.The ECS instance is not running (it is stopped, starting, or stopping).
  • The ECS instance is a Windows instance or does not support simple shell commands.

Direct import

  1. On the Clusters page, click the name of the cluster you created.

  2. On the Cluster Details page, click Add ECS Instance in the upper-right corner.

  3. On the Select Cluster and ECS page, select an import method and ECS instance in the instance list, and then click Next.

    • Import ECS: You cannot modify the namespace and the imported cluster. Additionally, ECS instances are imported from the default namespace and cluster in this region.
    • From Existing Cluster: A namespace and a cluster are selected from the region.Then, the ECS instance is moved from the left pane to the right pane on the page.

    If no instances meet the necessary conditions, click Create ECS Instance in the upper-right corner of the page. This takes you to the ECS purchase page on the Alibaba Cloud official website, where you can purchase and create a new ECS instance.For more information, see Create ECS instances.

    ![ [Add ECS instances].(http://docs-aliyun.cn-hangzhou.oss.aliyun-inc.com/assets/pic/57453/cn_zh/1546428404616/edas-resourcemgmt-cluster-addECS-selectClusterandECS.png)

  4. On the Ready to Import page, view the selected ECS instance information, and click Confirm and Import.

  5. On the Import page, view the import progress of the ECS instance.

    When Direct import successful is displayed, the ECS instance has been successfully added to the cluster.

    Click Click to return to the Cluster Details page. After the ECS instance is imported, the Health Check status of the ECS instance is Running.

Import after conversion

You need to reset the password during import. An ECS instance may be reinstalled and the original data may be deleted in the process.

  1. See steps 1 to 3 of [Direct import] to select an ECS instance.

  2. On the Ready to import page, check the information about the selected ECS instance and select I agree to convert the above instances, and fully understand that the data in the original systems will be lost after conversion.Enter the new password of the root user for logging on to the system after conversion, and click Confirm and Import.

  3. On the Import page, view the import progress of the ECS instance.

    When you begin the import, the Status of the ECS instance is Converting now. This might take 5 minutes.

    Click Click to return to the Cluster Details page. The Health Check status of the ECS instance is Converting and the progress percentage is displayed.

    When the ECS instance is imported, the Health Check status is Running.

Remove an ECS instance

  1. In the ECS Instances and Applications area of the Cluster Details page, locate the row that contains the target ECS instance and click Remove in the Actions column.

  2. In the Remove an ECS instance dialog box, confirm the instance information and click Remove.

    In the removal process, the Health Check status of the ECS instance is Deleting and the progress percentage is displayed.

    After the ECS instance is deleted, it is no longer displayed in the instance list.