Creating a Cluster

Last updated: 2020-03-04 18:12:41

PDF

Operation Scenarios

When creating a cluster, it not only supports the addition of Cloud Virtual Machine as the initial node of the cluster, but also supports selecting the existing Cloud Virtual Machine as the initial node of the cluster. This document guides you through these two ways to create a cluster.

Notes on the OS

  • Changes to the OS only apply to new nodes and reinstalled nodes, but not existing nodes.
  • Currently, you can only create an image of the same type of OS. For example, you can use the CentOS basic image to create a CentOS custom image.
  • To use the custom image feature, please apply by Submitting a ticket .

If you use the custom image feature, please create custom images based on the basic image provided by TKE.

Steps

Enter Cluster Information

  1. Log in to the TKE console .

  2. In the left sidebar, click Clusters To go to the cluster management page.

  3. On the cluster management page, click CREATE .

  4. On the "Create a cluster" page, set the basic information of the cluster.

    • Cluster Name : The name of a cluster to create, with a length limited to 60 characters.
    • Project of New-added Resource : Select based on actual needs. Newly added resources will be automatically assigned to this project.
      For a comparison of the features of different versions, see Supported Versions of the Kubernetes Documentation .
    • Runtime Component Choose "docker" or "containerd". For more details, see Differences Between Containerd and Docker .
    • Region : Select the closest region based on your location. This helps minimize access latency and improve download speed.
    • Cluster Network : Assigns an IP address that is within the node's network address range to the CVMs in the cluster. For details, see Container and Node Network Configuration .
    • Container Network : Assigns an IP address that is within the container's network address range to the containers in the cluster. For details, see Container and Node Network Configuration .
    • Image Provider : To be selected based on your requirements.
    • Operating System : To be selected based on your requirements.
    • Cluster description : Enter the information about the cluster, which will be displayed on the Cluster information Page。
    • Advanced Settings : You can set IPVS.
      IPVS is suitable for scenarios where large-scale services are run on a cluster, and it cannot be disabled once enabled. For more information, see Enabling IPVS in a Cluster .
  5. Click Next .

Selecting a Model

  1. In "choose Model", determine whether to use the existing Cloud Virtual Machine to create a cluster.


Create a cluster using existing CVMs

To create a cluster using the existing Cloud Virtual Machine, you should pay attention to the following:

  • The selected CVM requires Reinstall system. All data of Cloud Virtual Machine system disk will be cleared after Reinstall.
  • The selected CVM will be migrated to the project to which the cluster belongs.
  • Cloud Virtual Machine's migration project will cause the security group to be unbound and need to be re-bound.
  1. In "Select a model", select the deployment mode and model.
    Main parameters include:

    • Master The deployment method of Master determines the management mode of your cluster. We provide two cluster hosting modes. For more information, please see Cluster Overview .
    • Node : Configures the worker node that is actually used by the cluster to run services. You can purchase a CVM as the Node When you create the cluster, or you can add the Node After the cluster has been created.
    • Master&Etcd Model According to the following requirements, Cloud Virtual Machine is selected.
      • The selected Cloud Virtual Machine configuration needs to be larger than CPU 4 core and requires selection > = 3 Cloud Virtual Machine.
      • Cloud Virtual Machine cannot be a node of another TKE cluster.
      • Cloud Virtual Machine's status must be [in operation].
      • Can be selected across availability zones.
    • Node Model : This can be selected when Node Is selected as Add . You can select an existing CVM as the Node And you can also add a Node After the cluster is created.
  2. Click [next], Configure Cloud Virtual Machine .


Create a cluster using existing CVMs

  1. In "Select a model", select the deployment mode and model.
    Main parameters include:

    • Master The deployment method of Master determines the management mode of your cluster. We provide two cluster hosting modes. Refer to Cluster Overview .
    • Node : Configures the worker node that is actually used by the cluster to run services. You can purchase a CVM as the Node When you create the cluster, or you can add the Node After the cluster has been created.
    • Billing method : Both pay-as-you-go and monthly subscription are supported. For more details, please see Billing Method .
      Master&Etcd models
    • Availability zone : You can select multiple availability zones at the same time to deploy your Master or Node nodes to ensure higher availability of the cluster.
    • Node network : You can select multiple subnet resources at the same time to deploy your Master or Node nodes to ensure higher availability of the cluster.
    • Model Select Model with a core larger than CPU 4. For more information, please see Instance specifications .
    • System disk The default is "Local hard disk 50G". You can select local hard disk, HDD cloud disk, SSD, Premium Cloud Storage and so on according to Model. For storage disk selection, please refer to Storage Overview .
    • Data disk : As it is recommended not to deploy other applications in the Master, no data disk is configured for it by default. You can add a cloud disk to it after purchase.
    • Public network bandwidth : Select Public network access And the system will assign a public IP for free. Two billing methods are available. For a detailed comparison, see Public Network Billing Method .
      At least 3 Masters models should be deployed. Cross-AZ deployment is supported.
    • Node model When " Node Select as Add "optional.
    • Availability zone : You can select multiple availability zones at the same time to deploy your Master or Node nodes to ensure higher availability of the cluster.
    • Node network : You can select multiple subnet resources at the same time to deploy your Master or Node nodes to ensure higher availability of the cluster.
    • Model Model chooses a plan, see Instance specifications .
    • System disk The default is "Local hard disk 50G". You can select local hard disk, HDD cloud disk, SSD, Premium Cloud Storage and so on according to Model. For storage disk selection, please refer to Storage Overview .
    • Data disk : As it is recommended not to deploy other applications in the Master, no data disk is configured for it by default. You can add a cloud disk to it after purchase.
    • Public network bandwidth : Select Public network access And the system will assign a public IP for free. Two billing methods are available. For a detailed comparison, see Public Network Billing Method .
    • Type : To be selected based on your requirements.
  2. Click [next], Configure Cloud Virtual Machine .


CVM Configuration

  1. In "CVM configuration", configure other settings for the CVM instance.
    Main parameters include:

    • Data disk mount Checked by default.
    • Security group : The security group works as a firewall to control network access of the CVM. For more information, see TKE Security Group Settings .
    • Login method : Three login methods are available.
    • Custom Password : Set a corresponding password as prompted.
    • SSH Key Pair : A key pair is a pair of parameters generated by an algorithm. It is a way to log in to a CVM instance that is more secure than regular passwords. For more details, see SSH Key .
    • Random Password : A password will be automatically generated and sent to you through internal message.
    • Auto adjustment : A scaling group with a maximum of two nodes can be created automatically.
    1. Click Next To check and confirm the configuration information.
    2. Click Finish .