You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
= Example: Node network configuration policy for virtual functions
8
8
9
9
Update host network settings for Single Root I/O Virtualization (SR-IOV) network virtual functions (VF) in an existing cluster by applying a `NodeNetworkConfigurationPolicy` manifest.
10
10
11
-
:FeatureName: Updating host network settings for SR-IOV network VFs
You can apply a `NodeNetworkConfigurationPolicy` manifest to an existing cluster to complete the following tasks:
15
12
16
13
* Configure QoS host network settings for VFs to optimize performance.
@@ -23,7 +20,7 @@ To update host network settings for SR-IOV VFs by using NMState on physical func
23
20
====
24
21
25
22
The following YAML file is an example of a manifest that defines QoS policies for a VF.
26
-
This file includes samples values that you must replace with your own information.
23
+
This YAML includes samples values that you must replace with your own information.
27
24
28
25
[source,yaml]
29
26
----
@@ -59,12 +56,12 @@ spec:
59
56
<9> Identifies the VF with an ID of `0`.
60
57
<10> Sets a maximum transmission rate, in Mbps, for the VF. This sample value sets a rate of 200 Mbps.
61
58
62
-
The following YAML file is an example of a manifest that creates a VLAN interface on top of a VF and adds it to a bonded network interface.
63
-
It includes samples values that you must replace with your own information.
59
+
The following YAML file is an example of a manifest that adds a VF for a network interface.
60
+
61
+
In this sample configuration, the `ens1f1v0` VF is created on the `ens1f1` physical interface, and this VF is added to a bonded network interface `bond0`. The bond uses `active-backup` mode for redundancy. In this example, the VF is configured to use hardware offloading to manage the VLAN directly on the physical interface.
64
62
65
63
[source,yaml]
66
64
----
67
-
68
65
apiVersion: nmstate.io/v1
69
66
kind: NodeNetworkConfigurationPolicy
70
67
metadata:
@@ -75,39 +72,40 @@ spec:
75
72
maxUnavailable: 3
76
73
desiredState:
77
74
interfaces:
78
-
- name: ens1f0v1 <4>
75
+
- name: ens1f1 <4>
79
76
type: ethernet
80
77
state: up
81
-
- name: ens1f0v1.477 <5>
82
-
type: vlan
83
-
state: up
84
-
vlan:
85
-
base-iface: ens1f0v1 <6>
86
-
id: 477
87
-
- name: bond0 <7>
88
-
description: Add vf <8>
89
-
type: bond <9>
90
-
state: up <10>
78
+
ethernet:
79
+
sr-iov:
80
+
total-vfs: 1 <5>
81
+
vfs:
82
+
- id: 0
83
+
trust: true <6>
84
+
vlan-id: 477 <7>
85
+
- name: bond0 <8>
86
+
description: Attach VFs to bond <9>
87
+
type: bond <10>
88
+
state: up <11>
91
89
link-aggregation:
92
-
mode: active-backup <11>
90
+
mode: active-backup <12>
93
91
options:
94
-
primary: ens1f1v0.477 <12>
95
-
port: <13>
96
-
- ens1f1v0.477
97
-
- ens1f0v0.477
98
-
- ens1f0v1.477 <14>
92
+
primary: ens1f0v0 <13>
93
+
port: <14>
94
+
- ens1f0v0
95
+
- ens1f1v0 <15>
99
96
----
100
97
<1> Name of the policy.
101
98
<2> Optional: If you do not include the `nodeSelector` parameter, the policy applies to all nodes in the cluster.
102
-
<3> This example applies to all nodes with the `worker` role.
99
+
<3> The example applies to all nodes with the `worker` role.
103
100
<4> Name of the VF network interface.
104
-
<5> Name of the VLAN network interface.
105
-
<6> The VF network interface to which the VLAN interface is attached.
106
-
<7> Name of the bonding network interface.
107
-
<8> Optional: Human-readable description of the interface.
108
-
<9> The type of interface.
109
-
<10> The requested state for the interface after configuration.
110
-
<11> The bonding policy for the bond.
111
-
<12> The primary attached bonding port.
112
-
<13> The ports for the bonded network interface.
113
-
<14> In this example, this VLAN network interface is added as an additional interface to the bonded network interface.
101
+
<5> Number of VFs to create.
102
+
<6> Setting to allow failover bonding between the active and backup VFs.
103
+
<7> ID of the VLAN. The example uses hardward offloading to define a VLAN directly on the VF.
104
+
<8> Name of the bonding network interface.
105
+
<9> Optional: Human-readable description of the interface.
106
+
<10> The type of interface.
107
+
<11> The requested state for the interface after configuration.
108
+
<12> The bonding policy for the bond.
109
+
<13> The primary attached bonding port.
110
+
<14> The ports for the bonded network interface.
111
+
<15> In this example, the VLAN network interface is added as an additional interface to the bonded network interface.
0 commit comments