Create a Cluster on Alauda OS

On this path, creates clusters whose nodes run Alauda OS, an image-based, read-only operating system. The nodes are virtual machines on Huawei DCS, Huawei Cloud Stack, or VMware vSphere, or physical servers on Bare Metal.

Architecture

A cluster on Alauda OS is described by Cluster API objects on the global cluster. Two providers run on global and act on those objects:

  • The Alauda Container Platform Cluster Bootstrap Provider turns machines into Kubernetes nodes with kubeadm and runs the control plane.
  • An infrastructure provider, one for each IaaS platform, creates the machines from Alauda OS images. On Bare Metal, it reinstalls physical servers that you have registered instead of creating virtual machines.

Cluster API Architecture

What ac Does and What the Platform Does

You create a cluster with ac adm alpha cluster create. ac renders the Cluster API and provider objects from one install-config.yaml, checks them, and applies them to the global cluster. From then on, the providers on global create the machines and keep the cluster running. Node changes are covered in Manage Nodes on Alauda OS Clusters, and version changes in the upgrade documentation.

Nodes Are Replaced, Not Changed in Place

A Kubernetes or Alauda OS version change replaces the nodes one at a time. On Huawei DCS, Huawei Cloud Stack, and VMware vSphere, each node is replaced with a new virtual machine. On Bare Metal, the existing hosts are reinstalled; a host removed from the cluster returns to its pool, and its declared data volumes stay with that host. The replacement node gets the same host, and its data volumes, only when the pool has no other available host. Supported OS settings are changed through Machine Configuration.

A cluster with a single control plane node is for testing and cannot be upgraded.

DataWhen a node is replaced
Data on the node's own disks, such as hostPath volumes and local PersistentVolumes, unless they are on pool-managed persistent disks (Bare Metal: declared data volumes)Not kept. Keep data that must survive on CSI storage or on a pool-managed persistent disk.
Data on pool-managed persistent disks (Huawei DCS, Huawei Cloud Stack, VMware vSphere) and on declared data volumes (Bare Metal), such as the platform data in /var/cpaasKept when the replacement node takes over the pool entry or host of the node it replaces.
External storage, such as volumes provided through CSINot affected.

Fixed at Creation

Decide the following before you create the cluster. They cannot be changed on an existing cluster:

  • The control plane endpoint mode and address. See Plan the Control Plane Endpoint.
  • The image registry of the cluster: the registry of the global cluster or a dedicated one. See Choose the Image Registry for a Workload Cluster.
  • On Huawei DCS, Huawei Cloud Stack, and VMware vSphere, the layout of an existing persistent disk, such as its size and, on Huawei DCS, its datastore. On VMware vSphere, the addresses and disks of a pool slot are also fixed once a machine takes the slot. Plan the disks of each node pool before you create the cluster.

Supported Providers

ProviderMachinesControl plane endpointNotable for planning
Bare MetalPhysical servers that register once from an installation ISO built by the platform and are listed per node group in a poolSelf-built VIP (default), or an external load balancerYou register the hosts and create the pools before you run ac.
Huawei DCSVirtual machines cloned from a DCS VM templateExternal load balancer (default), or a Self-built VIPEach node has a fixed address and hostname that you reserve; DCS does not reserve them. The Kubernetes version comes from the VM template.
Huawei Cloud StackECS instances in an existing VPC, subnet, and security groupAn HCS ELB that the provider createsEach node pool is placed in one availability zone. The ELB takes one VIP and two L4 and two L7 addresses.
VMware vSphereVirtual machines cloned from a vSphere VM template, each with a static IP address and hostname from install-config.yaml (no DHCP)External load balancer (default), or a Self-built VIPEvery node group needs its own machine config pool. A dedicated image registry is not available.

Control Plane Endpoint

What to prepare for each endpoint mode is in Plan the Control Plane Endpoint.

Install the Providers on the global Cluster

Install the provider for the IaaS platform, and the Cluster Bootstrap Provider, on the global cluster as described in Install the Infrastructure Provider. A global cluster installed with ac already runs the Cluster Bootstrap Provider and the provider of its own platform.

Upgrading Kubernetes on an Alauda OS global cluster also requires the provider for that IaaS platform to be uploaded and installed on the global cluster first.

Cluster Creation Workflow

Create a workload cluster on Alauda OS in the following order. Prepare describes the first three steps in the same order.

  1. Install the Provider: Install the provider for your IaaS platform, and the Cluster Bootstrap Provider, on the global cluster.
  2. Infrastructure Resources: Prepare what the provider requires, as listed in its Prerequisites page. With ac, this is mainly the credential Secret and the IaaS objects that install-config.yaml names.
  3. Plan the Cluster: Read Prepare for the decisions that apply to every provider, such as the control plane endpoint mode and the image registry of the cluster. Also check the following before you create the cluster:
    • Node Labels and Taints: If dedicated node pools (monitoring, logging, ingress) are planned, read how to declare role labels and taints on the pool in Infra Nodes before creating the pools.
    • CPU Baseline: For x86_64 cluster nodes that use ACP-provided Alauda OS images, the underlying CPUs must support the x86-64-v2 ISA baseline. For details, see OS Support Matrix.
  4. Create a Cluster: Create the cluster, including its first worker nodes, with ac adm alpha cluster create from one install-config.yaml.

Each provider has its own pages for these steps:

If a failure is not provider-specific, see Troubleshooting.

ScenarioDocumentation
Install the global cluster on Alauda OSInstalling the global Cluster
Plan disaster recovery for the global clusterCreate a Global Cluster Disaster Recovery Pair
Learn how Kubernetes and Alauda OS are upgraded on each providerWho Upgrades Kubernetes
Upgrade the global clusterUpgrade the global Cluster
Upgrade workload clustersUpgrade Workload Clusters
Manage cluster nodesManage Nodes on Alauda OS Clusters
Configure machines (OS or kernel level)Machine Configuration
Look up Cluster API and provider resourcesCluster API Reference and Provider APIs

Prepare

Bare Metal

Huawei DCS

Huawei Cloud Stack

VMware vSphere

Troubleshooting