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
MGMT-21485: Enable dpu-host mode that matches DPF requirements
This commit introduces OVN_NODE_MODE environment variable to enable per-node
feature enforcement, particularly for DPU host mode where certain features
must be disabled regardless of cluster-wide configuration.
- Move feature toggles from ConfigMap (004-config.yaml) to startup scripts
- ConfigMap values cannot be reliably overridden per-node, but script logic can be conditional
- Implement OVN_NODE_MODE-based conditional feature enablement in node startup script
- Update control-plane scripts to handle moved parameters
- Add 'dpu-host' mode that automatically disables incompatible features:
- Egress IP and related features (egress firewall, egress QoS, egress service)
- Multicast support
- Multi-external gateway support
- Multi-network policies and admin network policies
- Network segmentation features
- Set gateway_interface='derive-from-mgmt-port' for DPU host nodes
- Add ovnkube_node_mode='--ovnkube-node-mode dpu-host' flag
From bindata/network/ovn-kubernetes/*/004-config.yaml:
- enable-egress-ip=true
- enable-egress-firewall=true
- enable-egress-qos=true
- enable-egress-service=true
- enable-multicast=true
- enable-multi-external-gateway=true
Note: HyperShift hosted cluster ConfigMap (managed/004-config.yaml) retains
egress feature flags as DPU host mode is not supported in hosted cluster
configurations.
- Add conditional blocks based on OVN_NODE_MODE
- Full mode (default): All features enabled as configured
- DPU host mode: Incompatible features force-disabled
- Rename egress_ip_enable_flag to egress_features_enable_flag for clarity
- Always-enabled features: Direct CLI flags (cleaner implementation)
- --enable-egress-ip=true, --enable-egress-firewall=true, etc.
- --enable-multicast, --enable-multi-external-gateway=true
- Conditional features: Script variables (matching original ConfigMap logic)
- multi_network_enabled_flag, network_segmentation_enabled_flag
- multi_network_policy_enabled_flag, admin_network_policy_enabled_flag
- Maintain backward compatibility for existing deployments
- Add comprehensive TestOVNKubernetesScriptLibCombined test covering:
- DPU host mode feature gating and disabling
- Full mode with multi-network features enabled/disabled
- Non-mode-gated features (route advertisements, DNS resolver, etc.)
- Gateway interface variable usage validation
- Multi-external gateway and egress features flag behavior across modes
- Add TestOVNKubernetesControlPlaneFlags test covering:
- Always-enabled features validation (direct CLI flags)
- Conditional features validation (script variables)
- Multi-network enablement logic (OVN_MULTI_NETWORK_ENABLE or OVN_NETWORK_SEGMENTATION_ENABLE)
- Network segmentation logic validation
- Remove redundant individual test functions after consolidation
- Update existing config rendering tests for new ConfigMap content
- Update test assertions to use correct flag names (egress_features_enable_flag)
- Create docs/ovn_node_mode.md with detailed technical explanation
- Update docs/operands.md with OVN-Kubernetes node modes section
- Update docs/architecture.md with per-node configuration explanation
- Update README.md with DPU host mode support information
- Add implementation details, feature mapping tables, and migration notes
- Document multi-external gateway as disabled feature in DPU host mode
- Update all references to use correct flag names
ConfigMap-based feature control cannot be overridden per-node, making it
impossible to disable features on specific node types (like DPU hosts) while
keeping them enabled cluster-wide. Moving the logic to startup scripts allows
the same cluster configuration to work across heterogeneous node types.
This change ensures that DPU host nodes automatically have incompatible
features disabled, preventing runtime failures and enabling mixed-mode
cluster deployments.
- Existing clusters continue to work without changes
- Default behavior (full mode) remains unchanged
- Control-plane components maintain identical functionality
- Migration is automatic during upgrade process
- No manual intervention required
- HyperShift hosted clusters unaffected (DPU host mode not supported)
Copy file name to clipboardExpand all lines: README.md
+12Lines changed: 12 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -157,6 +157,18 @@ OVNKubernetes supports the following configuration options, all of which are opt
157
157
* `egressIPConfig`: holds the configuration for EgressIP options.
158
158
* `reachabilityTotalTimeoutSeconds`: Set EgressIP node reachability total timeout in seconds, 0 means disable reachability check and the default is 1 second.
159
159
160
+
#### DPU Host Mode Support
161
+
162
+
OVN-Kubernetes supports specialized hardware deployments such as DPU (Data Processing Unit) hosts through the `OVN_NODE_MODE` environment variable. In `dpu-host` mode, certain features are automatically disabled on those nodes regardless of cluster-wide configuration:
163
+
164
+
- Egress IP and related features (egress firewall, egress QoS, egress service)
165
+
- Multicast support
166
+
- Multi-external gateway support
167
+
- Multi-network policies and admin network policies
168
+
- Network segmentation features
169
+
170
+
This per-node feature enforcement is implemented through conditional logic in the startup scripts, allowing the same cluster configuration to work across heterogeneous node types. For detailed information about node modes and the technical implementation, see `docs/ovn_node_mode.md`.
171
+
160
172
These configuration flags are only in the Operator configuration object.
161
173
162
174
Example from the `manifests/cluster-network-03-config.yml` file:
Copy file name to clipboardExpand all lines: docs/architecture.md
+6Lines changed: 6 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -141,6 +141,12 @@ The Network operator needs to make sure that the input configuration doesn't cha
141
141
142
142
The persisted configuration must **make all defaults explicit**. This protects against inadvertent code changes that could destabilize an existing cluster.
143
143
144
+
### Per-Node Configuration
145
+
146
+
For certain specialized deployments (e.g., DPU host nodes), some features need to be disabled on a per-node basis even when enabled cluster-wide. Since ConfigMap values cannot be reliably overridden per-node, the CNO implements per-node feature enforcement through conditional logic in the startup scripts.
147
+
148
+
The `OVN_NODE_MODE` environment variable is injected into `ovnkube-node` pods and consumed by the startup script (`008-script-lib.yaml`) to conditionally enable or disable features based on the node's operational mode. This ensures that unsupported features are deterministically disabled on specialized hardware regardless of cluster-wide configuration.
0 commit comments