Configuring affinity and nodeSelector rules for Dynamic Engine
Last updated: 10/29/2026Use nodeSelector and affinity rules in Dynamic Engine Helm charts to control pod scheduling across different node groups in your Kubernetes cluster.
Starting with Dynamic Engine v1.1.0, you can set specific affinity rules to isolate services on specific nodes for security, performance, or resource optimization purposes. For example, you can appropriate a large-size group of nodes for intense pod runs.
Dynamic Engine v1.1.0 supports both nodeSelector (simple label-based selection) and affinity rules (complex scheduling logic) in Helm values files.
Before you begin
- Your Kubernetes cluster must be configured with multiple node groups (node pools) with appropriate labels. See the related documentation from your cloud provider on how to set up this configuration, for example, if you are using Kubernetes with GKE, see Create and manage cluster and node pool labels.
- You must have basic knowledge of Kubernetes affinity rules.
About this task
By default, Dynamic Engine pods are scheduled on any available nodes in your cluster. With node affinity and node selector rules, you can control pod placement to achieve specific objectives such as:
- Isolate permanent services on smaller, dedicated nodes
- Run workloads like Jobs, Routes, or Data Services on larger nodes with particular instance types
- instanceType=large
- instanceType=medium
- qlik-dynamic-engine-tasks=true
Procedure
Results
Once deployed successfully, all Dynamic Engine and environment pods are scheduled according to your custom affinity and nodeSelector rules. Permanent services for the infrastructure run on their designated nodes, and customer workloads run on nodes optimized for their resource requirements.
If a pod (or pods) cannot be scheduled on a node, use the following steps to diagnose and resolve the issue.
- Identify the scheduling failure:
Use the kubectl describe pod command to get detailed information about the scheduling error:
kubectl describe pod <pod-name> -n <namespace>Look for the Events section, which provides clues about why the scheduler failed. Common reasons include:
- Rules not matching any nodes
- Insufficient CPU or memory resources on available nodes
- Taint and toleration issues on nodes that prevent pod scheduling
- Verify rules:
Ensure that the nodes have the required labels specified in your rules:
kubectl get nodes --show-labelsCompare the labels on your nodes with the labels specified in your values files.
- Verify resource constraints:
One of the most common reasons for scheduling failures is insufficient resources (CPU, memory). Verify the resource requests and limits in your pods:
kubectl describe nodesIf your cluster does not have enough nodes to satisfy resource requests, scale up your cluster by adding more nodes.
- Verify the taint and toleration specifications on the designated nodes.
Taints can prevent nodes from scheduling certain pods. If your nodes have taints and your pods do not have corresponding tolerations, pods cannot be scheduled. For further information about Kubernetes taints and tolerations, see Taints and Tolerations.
Starting with Dynamic Engine v1.4.0, tolerations are supported in Helm values files. To configure toleration rules and allow pods to be scheduled on tainted nodes, see Configuring tolerations rules for Dynamic Engine.