How To
Summary
When the TLS certificates expire, the customer needs to request new certificates.
To install the new certificates, they can use the steps that I verified today on a customer environment.
Objective
Environment
Steps
QRadar Suite Software provides the set_cert action to the TLS certificates that are used to secure in-flight communication in the cluster when it expires or to update the existing certificates.
Before you begin
Install the command-line interface (CLI) utility cpctl from the cp-serviceability pod. For more information, see Installing the cpctl utility.
For more information about certificate requirements, see Domain name and TLS certificates.
About this task
Procedure
- Log in to your Red Hat OpenShift Container Platform cluster as a cluster administrator by typing one of the following commands, where <openshift_url> is the URL for your Red Hat OpenShift Container Platform environment.
- Using a username and password.
oc login <openshift_url> -u <cluster_admin_user> -p <cluster_admin_password>Using a token.oc login --token=<token> --server=<openshift_url>If needed, change to the namespace used for CP4S, for exampleoc project cp4s
- Using a username and password.
- To make sure that the list of available cpctl actions is up to date, enter the following command.
cpctl loadThe cpctl load command retrieves all of the available actions that can be run on QRadar Suite Software. The actions are cached to your local environment. -
Update the certificate with the following command. Please note that the certificate and key need to be in clear text.
cpctl tools update_cert --key "$(cat tls.key)" --cert "$(cat tls.crt)" --token "$(oc whoami -t)"
Renew the certificate for IBM Common Services
For updating the Common Services certificate we used the documentation https://www.ibm.com/docs/en/cloud-paks/1.0?topic=cloudpaks_start/cert-manager/3.x.x/cert_mgmt_ingress.htm#use-your-own-certificate-for-the-console-and-api-version-3-6-3-and-earlier- even if the header said (version 3.6.3 and earlier)
-
Update the
managementingressCR so thatibm-management-ingress-operatordoes not re-create theroute-certcertificate and theroute-tls-secretsecret. “Unmanaged” is case-sensitive.oc -n ibm-common-services patch managementingress default --type merge --patch '{"spec":{"managementState":"Unmanaged"}}'After this change, theibm-management-ingress-operatorpod will continue to run but it will do nothing. In the log of the pod, you see this message:do nothing for the managementingress: ibm-common-services/default because its state is unmanaged -
Get your TLS certificate as described in Before you begin. Remember to include the external hostname for the foundational services endpoint in the
subjectAltNamelist of your certificate. -
Get the
destinationCACertificatevalue from the currentcp-consoleroute.oc -n ibm-common-services get route cp-console -o jsonpath="{.spec.tls.destinationCACertificate}" > dest-ca.crt -
Update the
cp-consoleroute.a. Save the
cert,key, andca-certof your certificate in the same directory as thedestinationCACertificate. For example,# ls -l total 68 -rw-r--r-- 1 root root 2021 Oct 19 18:17 ca.crt -rw-r--r-- 1 root root 1168 Oct 19 18:28 dest-ca.crt -rw-r--r-- 1 root root 1777 Oct 19 18:18 tls.crt -rw-r--r-- 1 root root 1675 Oct 19 18:17 tls.keyYou must have your full certificate chain if the CA certificate you bring is not self-signed. The full certificate chain includes all the CA certificates that signed each intermediate CA certificate that signed your CA certificate and your root CA. Save the full certificate chain inca.crt.b. Get the hostname from the current
cp-consoleroute. For example,cp-console.apps.demo.cp.fyre.ibm.com.oc -n ibm-common-services get route cp-console -o jsonpath="{.spec.host}"c. Regenerate the route spec. In the following command, replaceHOSTNAMEwith the hostname you got in step b.oc -n ibm-common-services create route reencrypt cp-console --service=icp-management-ingress --cert=./tls.crt --key=./tls.key --ca-cert=./ca.crt --dest-ca-cert=./dest-ca.crt --hostname=HOSTNAME --insecure-policy='Redirect' --dry-run=true -o yaml > cp-console.yamld. Apply the change.oc -n ibm-common-services apply -f cp-console.yaml -
Re-create the
route-tls-secretwith your certificate.a. Delete the related certificate resource so that cert manager does not re-create your updated secret.
oc -n ibm-common-services delete certificates.v1alpha1.certmanager.k8s.io route-certb. Re-create the secret from your certificate.oc -n ibm-common-services delete secret route-tls-secret oc -n ibm-common-services create secret generic route-tls-secret --from-file=ca.crt=<your path>/ca.crt --from-file=tls.crt=<your path>/tls.crt --from-file=tls.key=<your path>/tls.keyRe-create theibm-cloud-cluster-ca-certsecret with your certificate. -
oc -n ibm-common-services delete secret ibmcloud-cluster-ca-cert oc -n ibm-common-services create secret generic ibmcloud-cluster-ca-cert --from-file=ca.crt=<your path>/ca.crtRestartauth-idppods. -
oc -n ibm-common-services delete pod -l app=auth-idpRestartoperand-deployment-lifecycle-managerpods. -
# oc -n ibm-common-services delete pod -l name=operand-deployment-lifecycle-managerAccess the console to verify that the certificate is used.
Document Location
Worldwide
Was this topic helpful?
Document Information
Modified date:
03 March 2025
UID
ibm17184677