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
// To accommodate a link to the NMstate Operator, the content in this module
10
-
// is split with tags. The tag includes don't pull in the module header above.
11
-
12
-
// tag::localnet-intro[]
9
+
[role="_abstract"]
13
10
The switched `localnet` topology interconnects the workloads created as Network Attachment Definitions (NADs) through a cluster-wide logical switch to a physical network.
14
-
// end::localnet-intro[]
15
11
16
-
// tag::localnet-content[]
17
12
You must map a secondary network to the ovs-bridge to use it as an OVN-Kubernetes secondary network. Bridge mappings allow network traffic to reach the physical network. A bridge mapping associates a physical network name, also known as an interface label, to a bridge created with Open vSwitch (OVS).
18
13
19
14
You can create an `NodeNetworkConfigurationPolicy` (NNCP) object, part of the `nmstate.io/v1` API group, to declaratively create the mapping. This API is provided by the NMState Operator. By using this API you can apply the bridge mapping to nodes that match your specified `nodeSelector` expression, such as `node-role.kubernetes.io/worker: ''`. With this declarative approach, the NMState Operator applies secondary network configuration to all nodes specified by the node selector automatically and transparently.
@@ -31,22 +26,25 @@ The `localnet1` network is mapped to the `br-ex` bridge in the following example
31
26
apiVersion: nmstate.io/v1
32
27
kind: NodeNetworkConfigurationPolicy
33
28
metadata:
34
-
name: mapping <1>
29
+
name: mapping
35
30
spec:
36
31
nodeSelector:
37
-
node-role.kubernetes.io/worker: '' <2>
32
+
node-role.kubernetes.io/worker: ''
38
33
desiredState:
39
34
ovn:
40
35
bridge-mappings:
41
-
- localnet: localnet1 <3>
42
-
bridge: br-ex <4>
43
-
state: present <5>
36
+
- localnet: localnet1
37
+
bridge: br-ex
38
+
state: present
44
39
----
45
-
<1> The name for the configuration object.
46
-
<2> A node selector that specifies the nodes to apply the node network configuration policy to.
47
-
<3> The name for the secondary network from which traffic is forwarded to the OVS bridge. This secondary network must match the name of the `spec.config.name` field of the `NetworkAttachmentDefinition` CRD that defines the OVN-Kubernetes secondary network.
48
-
<4> The name of the OVS bridge on the node. This value is required only if you specify `state: present`.
49
-
<5> The state for the mapping. Must be either `present` to add the bridge or `absent` to remove the bridge. The default value is `present`.
40
+
+
41
+
where:
42
+
+
43
+
`metadata.name`:: The name for the configuration object.
44
+
`node-role.kubernetes.io/worker::` A node selector that specifies the nodes to apply the node network configuration policy to.
45
+
`localnet`:: The name for the secondary network from which traffic is forwarded to the OVS bridge. This secondary network must match the name of the `spec.config.name` field of the `NetworkAttachmentDefinition` CRD that defines the OVN-Kubernetes secondary network.
46
+
`bridge` The name of the OVS bridge on the node. This value is required only if you specify `state: present`.
47
+
`state`:: The state for the mapping. Must be either `present` to add the bridge or `absent` to remove the bridge. The default value is `present`.
50
48
+
51
49
The following JSON example configures a localnet secondary network that is named `localnet1`. Note that the value for the `mtu` parameter must match the MTU value that was set for the secondary network interface that is mapped to the `br-ex` bridge interface.
52
50
+
@@ -74,13 +72,13 @@ In the following example, the `localnet2` network interface is attached to the `
74
72
apiVersion: nmstate.io/v1
75
73
kind: NodeNetworkConfigurationPolicy
76
74
metadata:
77
-
name: ovs-br1-multiple-networks <1>
75
+
name: ovs-br1-multiple-networks
78
76
spec:
79
77
nodeSelector:
80
-
node-role.kubernetes.io/worker: '' <2>
78
+
node-role.kubernetes.io/worker: ''
81
79
desiredState:
82
80
interfaces:
83
-
- name: ovs-br1 <3>
81
+
- name: ovs-br1
84
82
description: |-
85
83
A dedicated OVS bridge with eth1 as a port
86
84
allowing all VLANs and untagged traffic
@@ -90,23 +88,26 @@ spec:
90
88
allow-extra-patch-ports: true
91
89
options:
92
90
stp: false
93
-
mcast-snooping-enable: true <4>
91
+
mcast-snooping-enable: true
94
92
port:
95
-
- name: eth1 <5>
93
+
- name: eth1
96
94
ovn:
97
95
bridge-mappings:
98
-
- localnet: localnet2 <6>
99
-
bridge: ovs-br1 <7>
100
-
state: present <8>
96
+
- localnet: localnet2
97
+
bridge: ovs-br1
98
+
state: present
101
99
----
102
-
<1> Specifies the name of the configuration object.
103
-
<2> Specifies a node selector that identifies the nodes to which the node network configuration policy applies.
104
-
<3> Specifies a new OVS bridge that operates separately from the default bridge used by OVN-Kubernetes for cluster traffic.
105
-
<4> Specifies whether to enable multicast snooping. When enabled, multicast snooping prevents network devices from flooding multicast traffic to all network members. By default, an OVS bridge does not enable multicast snooping. The default value is `false`.
106
-
<5> Specifies the network device on the host system to associate with the new OVS bridge.
107
-
<6> Specifies the name of the secondary network that forwards traffic to the OVS bridge. This name must match the value of the `spec.config.name` field in the `NetworkAttachmentDefinition` CRD that defines the OVN-Kubernetes secondary network.
108
-
<7> Specifies the name of the OVS bridge on the node. The value is required only when `state: present` is set.
109
-
<8> Specifies the state of the mapping. Valid values are `present` to add the bridge or `absent` to remove the bridge. The default value is `present`.
100
+
+
101
+
where:
102
+
+
103
+
`metadata.name`:: Specifies the name of the configuration object.
104
+
`node-role.kubernetes.io/worker`:: Specifies a node selector that identifies the nodes to which the node network configuration policy applies.
105
+
`interfaces.name`:: Specifies a new OVS bridge that operates separately from the default bridge used by OVN-Kubernetes for cluster traffic.
106
+
`mcast-snooping-enable`:: Specifies whether to enable multicast snooping. When enabled, multicast snooping prevents network devices from flooding multicast traffic to all network members. By default, an OVS bridge does not enable multicast snooping. The default value is `false`.
107
+
`port.name`:: Specifies the network device on the host system to associate with the new OVS bridge.
108
+
`localnet`:: Specifies the name of the secondary network that forwards traffic to the OVS bridge. This name must match the value of the `spec.config.name` field in the `NetworkAttachmentDefinition` CRD that defines the OVN-Kubernetes secondary network.
109
+
`bridge`:: Specifies the name of the OVS bridge on the node. The value is required only when `state: present` is set.
110
+
`state`:: Specifies the state of the mapping. Valid values are `present` to add the bridge or `absent` to remove the bridge. The default value is `present`.
110
111
+
111
112
The following JSON example configures a localnet secondary network that is named `localnet2`. Note that the value for the `mtu` parameter must match the MTU value that was set for the `eth1` secondary network interface.
112
113
+
@@ -125,4 +126,3 @@ The following JSON example configures a localnet secondary network that is named
Copy file name to clipboardExpand all lines: modules/configuring-ovnk-use-second-ovs-bridge.adoc
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -39,9 +39,9 @@ For more information about useful situations for the additional `br-ex1` bridge
39
39
+
40
40
[IMPORTANT]
41
41
====
42
-
Do not use the Kubernetes NMState Operator to define or a `NodeNetworkConfigurationPolicy` (NNCP) manifest file to define the additional interface.
42
+
Do not use the Kubernetes NMState Operator or a `NodeNetworkConfigurationPolicy` (NNCP) manifest file to define the additional interface. Ensure that the additional interface or sub-interfaces when defining a `bond` interface are not used by an existing `br-ex` OVN Kubernetes network deployment.
43
43
44
-
Also ensure that the additional interface or sub-interfaces when defining a `bond` interface are not used by an existing `br-ex` OVN Kubernetes network deployment.
44
+
As a postinstallation task, you cannot make configuration changes to the `br-ex` bridge or its underlying interfaces. As a workaround, use a secondary network interface connected to your host or switch.
45
45
====
46
46
+
47
47
.. Create the following interface definition files. These files get added to a machine configuration manifest file so that host nodes can access the definition files.
Copy file name to clipboardExpand all lines: modules/creating-manifest-file-customized-br-ex-bridge.adoc
+8-1Lines changed: 8 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,7 +19,14 @@ As an alternative to using the `configure-ovs.sh` shell script to set a `br-ex`
19
19
endif::postinstall-bare-metal[]
20
20
21
21
ifdef::postinstall-bare-metal[]
22
-
As an alternative to using the `configure-ovs.sh` shell script to set a `br-ex` bridge on a bare-metal platform, you can create a `NodeNetworkConfigurationPolicy` (NNCP) custom resource (CR) that includes an NMState configuration file. The Kubernetes NMState Operator uses the NMState configuration file to create a customized `br-ex` bridge network configuration on each node in your cluster.
22
+
As an alternative to using the `configure-ovs.sh` shell script to set a `br-ex` bridge on a bare-metal platform, you can create a `NodeNetworkConfigurationPolicy` (NNCP) custom resource (CR) that includes an NMState configuration file.
23
+
24
+
[NOTE]
25
+
====
26
+
As a postinstallation task, you cannot make configuration changes to the `br-ex` bridge or its underlying interfaces. As a workaround, use a secondary network interface connected to your host or switch.
27
+
====
28
+
29
+
The Kubernetes NMState Operator uses the NMState configuration file to create a customized `br-ex` bridge network configuration on each node in your cluster.
The `active-backup` mode provides fault tolerance for network connections by switching to a backup link where the primary link fails. The mode specifies the following ports for your cluster:
10
+
11
+
* An active port where one physical interface sends and receives traffic at any given time.
12
+
* A standby port where all other ports act as backup links and continously monitor their link status.
13
+
14
+
During a failover process, if an active port or its link fails, the bonding logic switches all network traffic to a standby port. This standby port becomes the new active port. For failover to work, all ports in a bond must share the same Media Access Control (MAC) address.
Copy file name to clipboardExpand all lines: modules/installation-network-user-infra.adoc
+3-9Lines changed: 3 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -89,17 +89,13 @@ During the initial boot, the machines require an IP address configuration that i
89
89
90
90
[NOTE]
91
91
====
92
-
* It is recommended to use a DHCP server for long-term management of the cluster machines. Ensure that the DHCP server is configured to provide persistent IP addresses, DNS server information, and hostnames to the cluster machines.
92
+
* Consider using a DHCP server for long-term management of the cluster machines. Ensure that the DHCP server is configured to provide persistent IP addresses, DNS server information, and hostnames to the cluster machines.
93
93
94
94
* If a DHCP service is not available for your user-provisioned infrastructure, you can instead provide the IP networking configuration and the address of the DNS server to the nodes at {op-system} install time. These can be passed as boot arguments if you are installing from an ISO image. See the _Installing {op-system} and starting the {product-title} bootstrap process_ section for more information about static IP provisioning and advanced networking options.
95
95
====
96
96
endif::ibm-z[]
97
97
98
-
The Kubernetes API server must be able to resolve the node names of the cluster
99
-
machines. If the API servers and worker nodes are in different zones, you can
100
-
configure a default DNS search zone to allow the API server to resolve the
101
-
node names. Another supported approach is to always refer to hosts by their
102
-
fully-qualified domain names in both the node objects and all DNS requests.
98
+
The Kubernetes API server must be able to resolve the node names of the cluster machines. If the API servers and worker nodes are in different zones, you can configure a default DNS search zone to allow the API server to resolve the node names. Another supported approach is to always refer to hosts by their fully-qualified domain names in both the node objects and all DNS requests.
You must configure the network connectivity between machines to allow {product-title} cluster
118
-
components to communicate. Each machine must be able to resolve the hostnames
119
-
of all other machines in the cluster.
113
+
You must configure the network connectivity between machines to allow {product-title} cluster components to communicate. Each machine must be able to resolve the hostnames of all other machines in the cluster.
120
114
121
115
This section provides details about the ports that are required.
0 commit comments