Skip to content

Commit 296bb46

Browse files
committed
virt, DPDK: Remove nodeSelector from VM def
Currently, the DPDK VM definition contains a node selector with a label that will not necessarily be present in the cluster. kube-scheduler probably has enough constraints to schedule the virt-launcher pod to a node configured for DPDK: 1. runtimeClass defined in KubeVirt CR `defaultRuntimeClass`. 2. HugePages. 3. Resource associated with the SR-IOV network. Signed-off-by: Orel Misan <[email protected]>
1 parent 1485b8a commit 296bb46

File tree

1 file changed

+8
-11
lines changed

1 file changed

+8
-11
lines changed

modules/virt-configuring-vm-dpdk.adoc

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -31,12 +31,10 @@ spec:
3131
cpu-quota.crio.io: disable <2>
3232
irq-load-balancing.crio.io: disable <3>
3333
spec:
34-
nodeSelector:
35-
node-role.kubernetes.io/worker-dpdk: "" <4>
3634
domain:
3735
cpu:
38-
sockets: 1 <5>
39-
cores: 5 <6>
36+
sockets: 1 <4>
37+
cores: 5 <5>
4038
threads: 2
4139
dedicatedCpuPlacement: true
4240
isolateEmulatorThread: true
@@ -51,24 +49,23 @@ spec:
5149
rng: {}
5250
memory:
5351
hugepages:
54-
pageSize: 1Gi <7>
52+
pageSize: 1Gi <6>
5553
guest: 8Gi
5654
networks:
5755
- name: default
5856
pod: {}
5957
- multus:
60-
networkName: dpdk-net <8>
58+
networkName: dpdk-net <7>
6159
name: nic-east
6260
# ...
6361
----
6462
<1> This annotation specifies that load balancing is disabled for CPUs that are used by the container.
6563
<2> This annotation specifies that the CPU quota is disabled for CPUs that are used by the container.
6664
<3> This annotation specifies that Interrupt Request (IRQ) load balancing is disabled for CPUs that are used by the container.
67-
<4> The label that is used in the `MachineConfigPool` and `PerformanceProfile` manifests that were created when configuring the cluster for DPDK workloads.
68-
<5> The number of sockets inside the VM. This field must be set to `1` for the CPUs to be scheduled from the same Non-Uniform Memory Access (NUMA) node.
69-
<6> The number of cores inside the VM. This must be a value greater than or equal to `1`. In this example, the VM is scheduled with 5 hyper-threads or 10 CPUs.
70-
<7> The size of the huge pages. The possible values for x86-64 architecture are 1Gi and 2Mi. In this example, the request is for 8 huge pages of size 1Gi.
71-
<8> The name of the SR-IOV `NetworkAttachmentDefinition` object.
65+
<4> The number of sockets inside the VM. This field must be set to `1` for the CPUs to be scheduled from the same Non-Uniform Memory Access (NUMA) node.
66+
<5> The number of cores inside the VM. This must be a value greater than or equal to `1`. In this example, the VM is scheduled with 5 hyper-threads or 10 CPUs.
67+
<6> The size of the huge pages. The possible values for x86-64 architecture are 1Gi and 2Mi. In this example, the request is for 8 huge pages of size 1Gi.
68+
<7> The name of the SR-IOV `NetworkAttachmentDefinition` object.
7269

7370
. Save and exit the editor.
7471
. Apply the `VirtualMachine` manifest:

0 commit comments

Comments
 (0)