// Module included in the following assemblies:
//
// * virt/managing_vms/cpu_models/virt-configuring-default-cpu-model.adoc

:_mod-docs-content-type: PROCEDURE
[id="virt-configuring-default-cpu-model_{context}"]
= Configure the default CPU model

[role="_abstract"]
Use the `defaultCPUModel` setting in the `HyperConverged` custom resource (CR) to define a cluster-wide default CPU model.

When you set a cluster-wide default CPU model:

* Every new virtual machine (VM) that does not have an explicit CPU model defined receives a node selector for the chosen CPU model.
* Only nodes labeled with `cpu-model.node.kubevirt.io/<cpuModel>` are eligible to run VMs using the default model.
* Nodes that do not support the selected CPU model are not considered during VM scheduling.

[NOTE]
====
The `defaultCPUModel` is case sensitive and must match a CPU model supported by nodes in your cluster.
====

A CPU model configured at the VM level always takes precedence over the cluster-wide default CPU model.

.Prerequisites

* Install the {oc-first}.

.Procedure

. Open the `HyperConverged` CR by running the following command:
+
[source,terminal,subs="attributes+"]
----
$ oc edit {HCOCliKind} kubevirt-hyperconverged -n {CNVNamespace}
----

. Add the `defaultCPUModel` field to the CR and set the value to the name of a CPU model that exists in the cluster:
+
[source,yaml,subs="attributes+"]
----
apiVersion: hco.kubevirt.io/v1
kind: HyperConverged
metadata:
 name: kubevirt-hyperconverged
 namespace: {CNVNamespace}
spec:
  virtualization:
    virtualMachineOptions:
      defaultCPUModel: "EPYC-IBPB"
----
+
where:
+
`EPYC-IBPB`:: Specifies a CPU model that is supported by nodes in your cluster.

. Apply the YAML file to your cluster.
