User-defined network status condition types

To troubleshoot your network deployment in Red Hat OpenShift Container Platform, evaluate the status condition types returned for ClusterUserDefinedNetwork and UserDefinedNetwork custom resources (CRs). Reviewing these conditions ensures that you can identify and resolve configuration errors.

Table 57. NetworkCreated condition types (ClusterDefinedNetwork and UserDefinedNetwork CRs)
Condition type Status Reason and Message

NetworkCreated

True

When True, the following reason and message is returned:

Reason

Message

NetworkAttachmentDefinitionCreated

'NetworkAttachmentDefinition has been created in following namespaces: [example-namespace-1, example-namespace-2, example-namespace-3]'`

NetworkCreated

False

When False, one of the following messages is returned:

Reason

Message

SyncError

failed to generate NetworkAttachmentDefinition

SyncError

failed to update NetworkAttachmentDefinition

SyncError

primary network already exist in namespace "<namespace_name>": "<primary_network_name>"

SyncError

failed to create NetworkAttachmentDefinition: create NAD error

SyncError

foreign NetworkAttachmentDefinition with the desired name already exist

SyncError

failed to add finalizer to UserDefinedNetwork

NetworkAttachmentDefinitionDeleted

NetworkAttachmentDefinition is being deleted: [<namespace>/<nad_name>]

Table 58. NetworkAllocationSucceeded condition types (UserDefinedNetwork CRs)
Condition type Status Reason and Message

NetworkAllocationSucceeded

True

When True, the following reason and message is returned:

Reason

Message

NetworkAllocationSucceeded

Network allocation succeeded for all synced nodes.

NetworkAllocationSucceeded

False

When False, the following message is returned:

Reason

Message

InternalError

Network allocation failed for at least one node: [<node_name>], check UDN events for more info.

Table 59. Invalid mtu scenarios types for the ClusterUserDefinedNetwork CR
Condition type Reason, Message, Resolution

invalid mtu

One of the following messages is returned when the mtu is set incorrect:

Reason

Message

Resolution

The mtu field is set higher than 65536.

spec.network.localnet.mtu in body should be less than 65536.

You must set the mtu field lower than 65536.

The mtu field is set lower than 576.

spec.network.localnet.mtu in body should be greater than or equal to 576.

You must set the mtu field greater than or equal to 576.

The mtu field must be at least 1280 when using the IPv6 subnet.

MTU should be greater than or equal to 1280 when an IPv6 subnet is used

You must set the mtu field higher than or equal to 1280 when you have an IPv6 subnet defined on your user-defined network configuration.

Table 60. Invalid PhysicalNetworkName scenarios types for the ClusterUserDefinedNetwork CR
Condition type Reason, Message, Resolution

invalid PhysicalNetworkName

One of the following messages is returned when the PhysicalNetworkName is set incorrect:

Reason

Message

Resolution

The name of the physical network is not set.

spec.network.localnet.physicalNetworkName: Required value

You must set the physicalNetworkName field.

The name of the physical network does not meet minimum length requirements.

spec.network.localnet.physicalNetworkName in body should be at least 1 chars long

You must set physical network name to be at least one character in length.

The name of the physical network exceeds the maximum character limit of 253.

spec.network.localnet.physicalNetworkName: Too long: may not be more than 253 bytes

You must set physical network name to not exceed the 253 character in length.

The name of the physical network must not contain , or :.

physicalNetworkName cannot contain "," or ":" characters.

You must remove the , or : from the physical network name.

Table 61. Invalid role scenarios types for the ClusterUserDefinedNetwork CR
Condition type Reason, Message, Resolution

role unset or role is primary

One of the following messages is returned when the spec.network.localnet.role is set incorrect:

Reason

Message

Resolution

The role field must be set for your localnet topology.

spec.network.localnet.role: Required value

You must set the role field.

Primary is not a supported value for the Localnet topology.

spec.network.localnet.role: Unsupported value: "Primary": supported values: "Secondary"

You must set the role field for your Localnet topology to Secondary-the accepted value.

Table 62. Invalid subnets and ipam scenarios types for the ClusterUserDefinedNetwork CR
Condition type Reason, Message, Resolution

LocalnetInvalidSubnets

One of the following messages is returned when either the spec.network.localnet.subnets or spec.network.localnet.ipam is set incorrect:

Reason

Message

Resolution

The optional fields, subnets and ipam.mode, have to be set together.

Subnets is required with ipam.mode is Enabled or unset, and forbidden otherwise

You must set the subnets field unless the spec.network.localnet.ipam.mode is explicitly disabled.

The spec.network.localnet.subnets must have an acceptable value when using this optional field.

The ClusterUserDefinedNetwork "localnet-empty-subnets-fail" is invalid: spec.network.localnet.subnets: Invalid value: 0: spec.network.localnet.subnets in body should have at least 1 items

You must set an acceptable value for spec.network.localnet.subnets. Acceptable values are IPv4 and IPv6 Classless Inter-Domain Routing (CIDR) ranges that do not overlap with any CIDR ranges used by Red Hat OpenShift Container Platform.

The subnet field must be set when using the optional spec.network.localnet.excludeSubnets field.

excludeSubnets must be unset when subnets is unset

You must set the spec.network.localnet.subnets field when using the spec.network.localnet.excludeSubnet field.

The excludeSubnets must be a value within the subnets field.

excludeSubnets must be subnetworks of the networks specified in the subnets field

You must set the value for the excludeSubnets field to be within the subnets field. For example, a subnets value of 192.168.100.0/24 and an excludeSubnets value of 192.168.200.1/32 is invalid.

The CIDR range is invalid.

The ClusterUserDefinedNetwork "localnet-subnets-invalid-ipv4-cidr-fail" is invalid: spec.network.localnet.subnets[0]: Invalid value: "string": CIDR is invalid

You must set an acceptable CIDR range for spec.network.localnet.subnets field. Acceptable values are IPv4 and IPv6 CIDR ranges which are not in use or reserved by Red Hat OpenShift Container Platform.

You must set the subnets field when the ipam.mode is Enabled or when the IPAM mode is unset because the default value is Enabled.

Subnets is required with ipam.mode is Enabled or unset, and forbidden otherwise.

You must set the spec.network.localnet.subnets field unless the spec.network.localnet.ipam.mode is explicitly disabled.

Setting two CIDR ranges for spec.network.localnet.subnets field requires that one be IPv4 and the other be IPv6.

Invalid value…​When 2 CIDRs are set, they must be from different IP families.

You must change one of your CIDR ranges to a different IP family.

The spec.network.localnet.ipam.mode is Disabled but the spec.network.localnet.lifecycle has a value of Persistent.

lifecycle Persistent is only supported when ipam.mode is Enabled

You must set the ipam.mode to Enabled when the optional field lifecycle has a value of Persistent.

Table 63. Invalid vlan scenarios types for the ClusterUserDefinedNetwork CR
Condition type Reason, Message, Resolution

invalid vlan or invalid mode

One of the following messages is returned when the spec.network.localnet.vlan is set incorrect:

Reason

Message

Resolution

The spec.network.localnet.vlan.mode field must be set.

spec.network.localnet.vlan.mode: Unsupported value: "Disabled": supported values: "Access

You must set the spec.network.localnet.vlan.mode field to Access mode.

The spec.network.localnet.vlan field must be set when spec.network.localnet.vlan.mode is set to Access mode.

vlan access config is required when vlan mode is 'Access', and forbidden otherwise.

You must set spec.network.localnet.vlan.mode.access field when using Access mode.

The spec.network.localnet.vlan.access.id value must be set when using Access mode.

spec.network.localnet.vlan.access.id: Required value

You must set a value for spec.network.localnet.mode.access.id.

Acceptable values for access.id are greater than or equal to 1.

spec.network.localnet.vlan.access.id in body should be greater than or equal to 1

You must set a value of 1 or greater for access.id field.

Acceptable values for access.id are less than or equal to 4094.

spec.network.localnet.vlan.access.id in body should be less than or equal to 4094

You must set a value of 4094 or less for access.id field.