Optional: Adding object stores post-deployment
You can add extra object stores post-deployment by updating the custom resource file to
include the additional configuration information for the object store.
About this task
You can add additional object stores post-deployment by updating the CR file to include the
additional datasource under the datasource_configuration section and updating the
object store configuration under the initialize_configuration section.
Procedure
When you install by using the deployment script, follow these steps:
-
Edit the ibm_cp4a_cr_final.yaml custom resources file from the initial
installation.
To validate that you have the most recently edited version of the custom resource file that was used for the installation, compare it to the version currently being used by the operator:
oc get icp4acluster -o yaml - For each additional/new object store that you create, make a copy of an existing object
store datasource under
dc_os_datasourcesand update the required parameters for the additional/new object store.Refer to Configuring Content Cortex to understand how to update parameters. Also, see topic Datasource Parameters for more details. - Under the
initialize_configuration.ic_obj_store_creation.object_storessection in the ibm_cp4a_cr_final.yaml custom resource file:- Make a copy of the required parameters. The required parameters include
oc_cpe_obj_store_display_name,oc_cpe_obj_store_symb_name,oc_cpe_obj_store_conn.dc_os_datasource_name,oc_cpe_obj_store_conn.dc_os_xa_datasource_name, andoc_cpe_obj_store_admin_user_groups. - If the initialization includes a Content Cortex Workflow system, enter a
unique value for
oc_cpe_obj_store_workflow_pe_conn_point_nameparameter.
- Make a copy of the required parameters.
- Use the existing configuration as a guide to fill up the values for the required parameters.
- Modify the
icp4adeploy-initialization-configconfigmap with:cpe_initialized = "False"Note: If you are upgrading from a previous version or migrating from on-premises, you need to manually add the object stores. Log in to the object store wizard in the IBM Administration Console for Content Platform Engine and follow the steps that are prompted by the UI to create additional object stores.Note: Check that thesc_content_initializationparameter in ibm_cp4a_cr_final.yaml is set to true. If you have migrated from on-premises to CP4BA and theicp4adeploy-initialization-configconfigMap is not present, you only need to setsc_content_initializationto true in ibm_cp4a_cr_final.yaml. - When the edits to the CR and secret are complete, apply the updated custom resource YAML
file:
oc apply -f <ibm_cp4a_my_cr_final.yaml> --overwrite=trueNote: If you have a multi-pattern deployment, the changes will immediately be updated in the ICP4A CR instance after applying your edited CR. However, it might take some time to be propagated into the Content CR instance. Monitor your Content CR for your changes with a command such as `oc get content -o yaml` or through your Red Hat OpenShift Console. - Update the IBM Content Cortex secret
ibm-fncm-secretto have the new credentials added.See Creating secrets to protect sensitive IBM Content Cortex configuration data to prepare youribm-fncm-secretsecret. The credentials that are added in the secret must match with the credentials in thedc_os_labelparameter.Note: If you are using external secret management and adding additional object stores, update theIf you have a Separation of Duties deployment, make sure to update and apply both ibm-fncm-secret-provider-class-cp4ba-operator.yaml and ibm-fncm-secret-provider-class.yaml.ibm-fncm-secretin vault to include the new username and password with the same format. For example, if you are adding a new object store with the label ofos2, then addos2DBUserNameos2DBPassword
For exampleapiVersion: secrets-store.csi.x-k8s.io/v1 kind: SecretProviderClass metadata: name: "ibm-fncm-secret" namespace: "cp4ba-operand" labels: gcd-db-server: dbserver1 db-name: ibm-fncm-secret cp4ba.ibm.com/backup-type: mandatory spec: provider: vault parameters: roleName: "cp4a-vault-role" vaultAddress: "http://vault.default:8200" objects: | <existing_data> - secretPath: "/secret/data/cp4ba/ibm-fncm-secret" objectName: "os2DBUsername" secretKey: "os2DBUsername" - secretPath: "/secret/data/cp4ba/ibm-fncm-secret" objectName: "os2DBPassword" secretKey: "os2DBPassword"Update the existingibm-fncm-secretSecretProviderClass to include the new keys, then apply the updates by usingoc apply -f ibm-fncm-secret-provider-class.yaml - Before restarting the operators, make sure that the
cpe_initializedkey in thecp4adeploy-initialization-configconfigMap is still set to False. Then restart theibm-cp4a-operatorandibm-content-operatorby running the following commands.export CP4BA_OPERATOR_POD=$(oc get pods -n <cp4ba-namespace> | grep ibm-cp4a-operator) export CONTENT_OPERATOR_POD=$(oc get pods -n <cp4ba-namespace> | grep ibm-content-operator) oc delete pods ${CP4BA_OPERATOR_POD} oc delete pods ${CONTENT_OPERATOR_POD}