Updating the config map per NCP doc to the [nsx_v3] section
container_ip_blocks = 10.10.0.0/16,10.11.0.0/16
The existing cluster was built with just 10.10.0.0/16
Restarting the operator doesn’t pass that info from the configmap in nsx-system-operator to the config map in nsx-system. The one in nsx-system stays with container_ip_blocks = 10.10.0.0/16
OpenShift 4.x
NCP 4.x
NSX 3.x 4.x
NCP does NOT rely on the container_ip_blocks from Operator ConfigMap. NCP Operator reads the CIDR from cluster network CRD.
apiVersion: config.openshift.io/v1
kind: Network
metadata:
...
spec:
clusterNetwork:
- cidr: 10.10.0.0/16
hostPrefix: 23
- cidr: 10.11.0.0/16 <<<<< additional IP block
hostPrefix: 23 <<<<<
message: 'Not applying unsafe configuration change: invalid configuration: [adding/removing clusterNetwork entries of the same type is not supported]. Use ''oc edit network.operator.openshift.io cluster'' to undo the change.'
reason: InvalidOperatorConfig
status: "True"
type: Degraded
oc -n openshift-network-operator delete cm/applied-cluster
Note that the NCP operator always reconciles the Network CRD, not only upon initial installation. The network CR can be updated after OC installation. The NCP Operator monitors the change at runtime. There is no need to restart the NCP Operator.