Scheduling Workloads to Arm Nodes
A CCE cluster may contain both Arm and x86 nodes. To ensure that Arm-compatible applications are scheduled correctly, or that dual-architecture images are preferentially scheduled to Arm nodes, you can use Kubernetes-native scheduling features. This section provides a complete solution ranging from preferential scheduling to forcible scheduling.
This section describes three scheduling configurations for you to choose from.
| Scenario | Scheduling Intent | Recommended Configuration |
|---|---|---|
| Pure Arm applications | Forcibly schedule workloads to Arm nodes. Workloads cannot be scheduled to x86 nodes. | nodeSelector or required node affinity |
| Dual-architecture applications, preferentially scheduled to Arm nodes | Preferentially schedule workloads to Arm nodes. If Arm node resources are insufficient, workloads can fall back to x86 nodes. | preferred node affinity |
| Dual-architecture applications, forcibly scheduled to Arm nodes | Pods must be scheduled to Arm nodes. If no Arm node is available, pods remain in the pending state. | required node affinity |
Creating an Arm Node Pool
- Log in to the CCE console.
- Click the cluster name to access the cluster console. In the navigation pane, choose Nodes. In the right pane, click the Node Pools tab.
- Click Create Node Pool in the upper right corner. In the Node Configuration area, select a Kunpeng flavor, for example, Kunpeng general computing-plus.
Kunpeng instances are available in select regions and AZs. Log in to the console and verify availability in your target region before proceeding.

- Set other parameters as needed to create the node pool. For more details, see Creating a Node Pool.
- After the node pool is created, click Resize.
- In the Resize Node Pool dialog box, set Nodes to Be Added to the desired number (for example, 2).
- Click OK and wait for the nodes to be provisioned.
Scheduling Workloads to Arm Nodes
Scenario 1: Pure Arm Applications
Pods must run on Arm nodes only. Use either nodeSelector or required nodeAffinity for scheduling.
- Method 1: Use nodeSelector.
Configuration example:
apiVersion: apps/v1 kind: Deployment metadata: name: test spec: replicas: 1 selector: matchLabels: app: test template: metadata: labels: app: test spec: containers: - name: test image: <your-arm64-only-image:latest> # Replace it with the actual image path. nodeSelector: kubernetes.io/arch: arm64 # Forcibly schedule pods to Arm nodes. imagePullSecrets: - name: default-secret - Method 2: Use nodeAffinity with requiredDuringSchedulingIgnoredDuringExecution.
Configuration example:
apiVersion: apps/v1 kind: Deployment metadata: name: test spec: replicas: 1 selector: matchLabels: app: test template: metadata: labels: app: test spec: containers: - name: test image: <your-arm64-only-image:latest> # Replace it with the actual image path. affinity: nodeAffinity: requiredDuringSchedulingIgnoredDuringExecution: # Hard constraint nodeSelectorTerms: - matchExpressions: - key: kubernetes.io/arch operator: In values: - arm64 # Forcibly schedule pods to Arm nodes. imagePullSecrets: - name: default-secret
Scenario 2: Dual-Architecture Applications (Prefer Arm)
Arm nodes are preferred, but if Arm resources are insufficient, pods can be scheduled to x86 nodes to ensure service availability. This is the recommended approach for most dual-architecture applications.
Configuration example:
apiVersion: apps/v1
kind: Deployment
metadata:
name: test
spec:
replicas: 1
selector:
matchLabels:
app: test
template:
metadata:
labels:
app: test
spec:
affinity:
nodeAffinity:
preferredDuringSchedulingIgnoredDuringExecution: # Soft constraint
- weight: 100 # A higher weight indicates a higher priority.
preference:
matchExpressions:
- key: kubernetes.io/arch
operator: In
values:
- arm64
containers:
- name: test
image: <your-multi-arch-image:latest> # Replace it with the actual image path. The image must support both amd64 and arm64 architectures.
imagePullSecrets:
- name: default-secret Scenario 3: Dual-Architecture Applications (Require Arm)
Pods must run on Arm nodes. If no Arm node is available, pods remain in the pending state and are not scheduled.
Configuration example:
apiVersion: apps/v1
kind: Deployment
metadata:
name: test
spec:
replicas: 1
selector:
matchLabels:
app: test
template:
metadata:
labels:
app: test
spec:
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution: # Hard constraint
nodeSelectorTerms:
- matchExpressions:
- key: kubernetes.io/arch
operator: In
values:
- arm64
containers:
- name: test
image: <your-multi-arch-image:latest> # Replace it with the actual image path.
imagePullSecrets:
- name: default-secret The YAML configuration is identical to Scenario 1 (pure Arm applications). The difference is the image. In this scenario, the image supports both architectures, but you force Arm scheduling for performance or cost optimization.
FAQs
How Do I Verify Arm Node Scheduling?
- Check the node where the pod is running.
kubectl get pod <pod-name> -o wide - Check the node architecture.
kubectl get node <node-name> -o jsonpath='{.metadata.labels.kubernetes\.io/arch}'If the node label contains arm64, the pod is successfully scheduled to an Arm node.
How Do I Build Dual-Architecture Images?
Use Docker's manifest list feature to build multi-architecture container images. For details, see Using a Dual-Architecture Image (x86 and Arm).
What is your overall rating for this page?
Thank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot