-
Bug
-
Resolution: Unresolved
-
Undefined
-
None
-
4.18, 4.18.z
Description of problem:
When a clusternetwork entry has an invalid hostPrefix, which is <= CIDR mask and the custom IPv4 join subnet is provided in the install-config, the installer gives a runtime panic error: negative shift amount The error is expected to occur as it is an invalid configuration, but a more descriptive error should be returned instead of panics.
Version-Release number of selected component (if applicable):
How reproducible:
Always
Steps to Reproduce:
Create a cluster with the following install-config (i.e. some fields are intentionally not included): ``` additionalTrustBundlePolicy: Proxyonly apiVersion: v1 baseDomain: devcluster.openshift.com compute: - architecture: amd64 hyperthreading: Enabled name: worker platform: {} replicas: 3 controlPlane: architecture: amd64 hyperthreading: Enabled name: master platform: {} replicas: 3 metadata: creationTimestamp: null name: thvo-dev networking: clusterNetwork: - cidr: 10.128.0.0/19 hostPrefix: 18 # Bad because hostPrefix must be >= 19 - cidr: 10.128.32.0/19 hostPrefix: 23 machineNetwork: - cidr: 10.0.0.0/16 networkType: OVNKubernetes serviceNetwork: - 172.30.0.0/16 ovnKubernetesConfig: ipv4: internalJoinSubnet: 101.64.0.0/16 platform: aws: region: us-east-1 publish: External ```
Actual results:
panic: runtime error: negative shift amount
Expected results:
A descriptive user-friendly error that points out why it is invalid
Additional info:
- blocks
-
OCPBUGS-49864 Runtime panic occurs when clusternetwork CIDR mask is greater than hostPrefix and OVN ipv4 join subnet is provided
-
- POST
-
- is cloned by
-
OCPBUGS-49864 Runtime panic occurs when clusternetwork CIDR mask is greater than hostPrefix and OVN ipv4 join subnet is provided
-
- POST
-
- links to