-
Bug
-
Resolution: Unresolved
-
Undefined
-
None
-
4.20
-
None
Description of problem:
If I try to install the o-cloud-manager operator from catalog using a non-default namespace, the controller fails to launch services. The operator is using a fixed namespace value, rather than getting it from the OCLOUD_MANAGER_NAMESPACE env variable.
Additionally, the HWMGR_PLUGIN_NAMESPACE env variable in the deployment is also using a fixed namespace value. This should either be dropped altogether in favour of OCLOUD_MANAGER_NAMESPACE, or updated to use the same fieldRef.
- name: HWMGR_PLUGIN_NAMESPACE
value: oran-o2ims
- name: OCLOUD_MANAGER_NAMESPACE
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: metadata.namespace
$ oc rsh -n o-cloud-manager oran-o2ims-controller-manager-6d97cb7cfd-t2srw env | grep NAMESPACE
NAR_CALLBACK_SERVICE_NAMESPACE=o-cloud-manager
HWMGR_PLUGIN_NAMESPACE=oran-o2ims
OCLOUD_MANAGER_NAMESPACE=o-cloud-manager
$ oc get pods -n o-cloud-manager
NAME READY STATUS RESTARTS AGE
oran-o2ims-controller-manager-6d97cb7cfd-t2srw 1/1 Running 0 6m55s
postgres-server-788bd5f4fd-fzwv2 1/1 Running 0 6m53s
{"time":"2025-10-21T12:08:11Z","level":"INFO","msg":"[CreateK8sCR] CR not found, CREATE it","logger":"oranUtilsLog","name":"resource-server","namespace":"oran-o2ims"}
{"time":"2025-10-21T12:08:11Z","level":"ERROR","msg":"Failed to deploy the Resource server.","controller":"O-Cloud Manager","error":"failed to deploy ManagerServer: failed to create CR oran-o2ims/resource-server: namespaces \"oran-o2ims\" not found","resource":"Inventory","name":"default","namespace":"o-cloud-manager","action":"reconcile_start","resourceVersion":"1027599080","generation":1,"phase":"infrastructure_setup","phase":"database_setup","phase":"networking_rbac_setup","phase":"o2ims_servers_setup"}
{"time":"2025-10-21T12:08:11Z","level":"ERROR","msg":"Failed to setup Resource Server","controller":"O-Cloud Manager","error":"failed to deploy ManagerServer: failed to create CR oran-o2ims/resource-server: namespaces \"oran-o2ims\" not found","resource":"Inventory","name":"default","namespace":"o-cloud-manager","action":"reconcile_start","resourceVersion":"1027599080","generation":1,"phase":"infrastructure_setup","phase":"database_setup","phase":"networking_rbac_setup","phase":"o2ims_servers_setup"}
{"time":"2025-10-21T12:08:11Z","level":"ERROR","msg":"Reconciliation failed","controller":"O-Cloud Manager","duration":397410506,"error":"failed to deploy ManagerServer: failed to create CR oran-o2ims/resource-server: namespaces \"oran-o2ims\" not found","resource":"Inventory","name":"default","namespace":"o-cloud-manager","action":"reconcile_start","resourceVersion":"1027599080","generation":1}
{"time":"2025-10-21T12:08:11Z","level":"INFO","msg":"Warning: Reconciler returned both a non-zero result and a non-nil error. The result will always be ignored if the error is non-nil and the non-nil error causes reqeueuing with exponential backoff. For more details, see: https://pkg.go.dev/sigs.k8s.io/controller-runtime/pkg/reconcile#Reconciler","controller":"o2ims-inventory","controllerGroup":"ocloud.openshift.io","controllerKind":"Inventory","Inventory":{"name":"default","namespace":"o-cloud-manager"},"namespace":"o-cloud-manager","name":"default","reconcileID":"6b7d7b51-9af9-4c76-bc3d-405be52aa636"}
{"time":"2025-10-21T12:08:11Z","level":"ERROR","msg":"Reconciler error","controller":"o2ims-inventory","controllerGroup":"ocloud.openshift.io","controllerKind":"Inventory","Inventory":{"name":"default","namespace":"o-cloud-manager"},"namespace":"o-cloud-manager","name":"default","reconcileID":"6b7d7b51-9af9-4c76-bc3d-405be52aa636","err":"failed to deploy ManagerServer: failed to create CR oran-o2ims/resource-server: namespaces \"oran-o2ims\" not found"}
Version-Release number of selected component (if applicable):
How reproducible:
Steps to Reproduce:
1.
2.
3.
Actual results:
Expected results:
Additional info:
- blocks
-
OCPBUGS-64610 O-Cloud Manager fails to launch services if installed in non-default namespace
-
- Closed
-
- is cloned by
-
OCPBUGS-64610 O-Cloud Manager fails to launch services if installed in non-default namespace
-
- Closed
-
- links to
- mentioned on