|
6 | 6 | [id="virt-configuring-live-migration-limits_{context}"] |
7 | 7 | = Configuring live migration limits and timeouts |
8 | 8 |
|
9 | | -Configure live migration limits and timeouts for the cluster by adding updated |
10 | | -key:value fields to the `kubevirt-config` configuration file, which is located in the |
| 9 | +Configure live migration limits and timeouts for the cluster by updating the `HyperConverged` custom resource (CR), which is located in the |
11 | 10 | `openshift-cnv` namespace. |
12 | 11 |
|
13 | 12 | .Procedure |
14 | 13 |
|
15 | | -* Edit the `kubevirt-config` configuration file and add the necessary |
16 | | -live migration parameters. The following example shows the default values: |
| 14 | +* Edit the `HyperConverged` CR and add the necessary live migration parameters. |
17 | 15 | + |
18 | | - |
19 | 16 | [source,terminal] |
20 | 17 | ---- |
21 | | -$ oc edit configmap kubevirt-config -n openshift-cnv |
| 18 | +$ oc edit hco -n openshift-cnv kubevirt-hyperconverged |
22 | 19 | ---- |
23 | 20 | + |
24 | 21 | .Example configuration file |
25 | 22 | [source,yaml] |
26 | 23 | ---- |
27 | | -apiVersion: v1 |
28 | | -data: |
29 | | - default-network-interface: masquerade |
30 | | - feature-gates: DataVolumes,SRIOV,LiveMigration,CPUManager,CPUNodeDiscovery,Sidecar,Snapshot |
31 | | - migrations: |- |
32 | | - parallelMigrationsPerCluster: "5" |
33 | | - parallelOutboundMigrationsPerNode: "2" |
34 | | - bandwidthPerMigration: "64Mi" |
35 | | - completionTimeoutPerGiB: "800" |
36 | | - progressTimeout: "150" |
37 | | - machine-type: pc-q35-rhel8.3.0 |
38 | | - selinuxLauncherType: virt_launcher.process |
39 | | - smbios: |- |
40 | | - Family: Red Hat |
41 | | - Product: Container-native virtualization |
42 | | - Manufacturer: Red Hat |
43 | | - Sku: 2.6.0 |
44 | | - Version: 2.6.0 |
45 | | -kind: ConfigMap |
| 24 | +apiVersion: hco.kubevirt.io/v1beta1 |
| 25 | +kind: HyperConverged |
46 | 26 | metadata: |
47 | | - creationTimestamp: "2021-03-26T18:01:04Z" |
48 | | - labels: |
49 | | - app: kubevirt-hyperconverged |
50 | | - name: kubevirt-config |
| 27 | + name: kubevirt-hyperconverged |
51 | 28 | namespace: openshift-cnv |
52 | | - resourceVersion: "15371295" |
53 | | - selfLink: /api/v1/namespaces/openshift-cnv/configmaps/kubevirt-config |
54 | | - uid: <uuid> |
| 29 | +spec: |
| 30 | + liveMigrationConfig: <1> |
| 31 | + bandwidthPerMigration: 64Mi |
| 32 | + completionTimeoutPerGiB: 800 |
| 33 | + parallelMigrationsPerCluster: 5 |
| 34 | + parallelOutboundMigrationsPerNode: 2 |
| 35 | + progressTimeout: 150 |
55 | 36 | ---- |
| 37 | +<1> In this example, the `spec.liveMigrationConfig` array contains the default values for each field. |
| 38 | ++ |
| 39 | +[NOTE] |
| 40 | +==== |
| 41 | +You can restore the default value for any `spec.liveMigrationConfig` field by deleting that key/value pair and saving the file. For example, delete `progressTimeout: <value>` to restore the default `progressTimeout: 150`. |
| 42 | +==== |
0 commit comments