All namespaces migration
The AllNamespaces migration migrates a single
shared instance of foundational services that
is commonly deployed in the openshift-operators
namespace.
This migration method is used in the following situations:
- A single instance of foundational services is shared by all IBM Cloud Paks in the entire cluster
- You want to upgrade all of its core foundational services
operators to the cluster-scope namespace
openshift-operatorswithout creating new instances.
Prerequisites
- See supported starting versions in Migrating foundational services v3.x to 4.x.
- Only a single instance of foundational services is deployed and shared by all of the IBM Cloud Paks in the entire cluster
- Download the scripts and go to the
installer_scriptsdirectory. For more information, see Downloading scripts for additional configuration from specific version CASE bundle. - Mirror new images and create new CatalogSource, or update the
existing CatalogSource to the new 4.x version.
- If your cluster is in a restricted (air-gapped) network environment mirror new images. For more information, see Mirroring images for an air-gapped cluster.
- Add the catalog source to make the operators available to your cluster. For more information, see Adding catalog sources to a cluster.
Upgrade by using the script
-
Execute the script
migrate_tenant.shwith the following options:./migrate_tenant.sh --license-accept --enable-licensing \ --operator-namespace openshift-operators \ --cert-manager-source ibm-cert-manager-catalog \ --licensing-source ibm-licensing-catalog \ -c v4.3 -i Automatic \ -s opencloud-operators -v 1 -
After executing the preceding automation script, IBM Cloud Paks should update all OperandRequests in the IBM Cloud Paks namespaces to only request
ibm-im-operatorandibm-platformui-operator(for example,tenant1-cp4i-capability-1-namespaceandtenant1-cp4i-capability-2-namespace):apiVersion: operator.ibm.com/v1alpha1 kind: OperandRequest metadata: name: common-service namespace: tenant1-cp4i-capability-1-namespace spec: requests: - operands: - name: ibm-im-operator - name: ibm-platformui-operator registry: common-service registryNamespace: ibm-common-services- All remaining operators must be migrated from
ibm-common-servicestoopenshift-operatorsnamespace. - All the services stay in their original
ibm-common-servicesand IBM Cloud Paks namespaces. - IBM NamespaceScope operator in
ibm-common-servicesand its corresponding custom resources (CR) will be automatically removed after foundational services 4.x.x upgrade is completed.
- All remaining operators must be migrated from
Upgrade by using manual steps
-
Scale down the original IBM Cloud Pak foundational services instances.
-
Foundational services
operator (typically in the
openshift-operatorsnamespace) is in a different namespace as the Operand Deployment Lifecycle Manager (ibm-common-servicesnamespace)
oc scale deployment ibm-common-service-operator -n openshift-operators --replicas=0 -
Foundational services
operator (typically in the
-
Delete the operandRegistry named
common-servicein theibm-common-servicesnamespace:oc delete operandregistry common-service -n ibm-common-services -
Migrate and set up a new singleton service for
LicensingandCert-Manager.-
The new singleton service migration and setup is completed by running the
setup_singleton.shscript. For more information on scripts, see Installing IBM Cert Manager and Licensing by script. -
--operator-namespaceis the parameter in the script used to locate the namespace for foundational services 3.x.x singleton service, and it will migrate the singleton service to its corresponding namespace. -
Other parameters can be customized.
./setup_singleton.sh --license-accept --enable-licensing --operator-namespace ibm-common-services -
-
Switch the channel (and switch the CatalogSource, if necessary) for
ibm-common-service-operatorin theopenshift-operatorsnamespace. After theibm-common-service-operatoris upgraded to thev4.xversion:-
ODLM is migrated from the
ibm-common-servicestoopenshift-operatorsnamespace. -
IBM Business Teams Service (BTS) and Events operator are migrated from
ibm-common-servicestoopenshift-operatorsnamespace (if installed) -
IAM, Zen, and other dependencies (such as management-ingress,
common-service-db, and CommonUI) are working still as-is inibm-common-servicesnamespace, until the IBM Cloud Paks are upgraded and stop creatingOperandRequestsforibm-iam-operatorandibm-zen-operator.
-
-
Check the status of the CommonService CR and the OperandRequests.
-
To check the status of the CommonService CR in your operator namespace, run the following command and make sure that the status is
Succeeded:oc get commonservice common-service -n <foundational-service-operator-namespace> -o jsonpath='{.status.phase}' -
Make sure that all the OperandRequests in IBM Cloud Paks namespace are in
Runningstatus before you update these OperandRequests in the next step. Run the following command:oc get operandrequest <IBM Cloud Paks-operandrequest-name> -n <IBM Cloud Paks namespace> -o jsonpath='{.status.phase}'
-
-
IBM Cloud Paks should update all OperandRequests in the IBM Cloud Paks namespaces to only request
ibm-im-operatorandibm-platformui-operator(for example,tenant1-cp4i-capability-1-namespaceandtenant1-cp4i-capability-2-namespace).apiVersion: operator.ibm.com/v1alpha1 kind: OperandRequest metadata: name: common-service namespace: tenant1-cp4i-capability-1-namespace spec: requests: - operands: - name: ibm-im-operator - name: ibm-platformui-operator registry: common-service registryNamespace: ibm-common-services- All remaining operators should be migrated from the
ibm-common-servicestoopenshift-operatorsnamespace- The IBM NamespaceScope operator is in
ibm-common-services, but it is not used at all. You can remove the IBM NamespaceScope operator and its corresponding CR after IBM Cloud Paks upgrade is done.
- The IBM NamespaceScope operator is in
- All the services stay in their original
ibm-common-servicesand IBM Cloud Paks namespaces.
- All remaining operators should be migrated from the