Enabling OpenShift Container Platform Monitoring

Monitoring in IBM Cloud Pak® for Integration relies on the OpenShift Container Platform (OCP) 4.6 monitoring stack. To enable monitoring of user-defined projects, you must configure OpenShift Container Platform monitoring.

If you would like to read more about the OCP 4.6 monitoring stack. see Understanding the monitoring stack in the OpenShift documentation.

Enabling the OCP monitoring stack

To enable OCP to monitor your applications, follow the steps below. Once enabled, developers can run PromQL queries on application metrics in the OpenShift web console by switching to the Developer perspective and clicking Monitoring in the navigation menu.

To enable the OCP monitoring stack:

  1. Edit or create the OperandConfig custom resource (CR) in the ibm-common-services namespace. Configure it so that the Grafana operator uses OpenShift metrics as the data source ()datasourceConfig):

    apiVersion: operator.ibm.com/v1alpha1
    kind: OperandConfig
    metadata:
      name: common-service
      namespace: ibm-common-services
    spec:
      services:
        - name: ibm-monitoring-grafana-operator
          spec:
            grafana:
              datasourceConfig:   ### Enable using the OCP metrics as a data source
                type: "openshift" ### Remove these two lines to switch back to CS Monitoring
            operandRequest: {}
  2. Edit or create the OperandRequest in the ibm-common-services namespace so that it requests only the Grafana operand under spec.requests.operands:

    apiVersion: operator.ibm.com/v1alpha1
    kind: OperandRequest
    metadata:
      name: common-service
      namespace: ibm-common-services
    spec:
      requests:
        - operands:
            - name: ibm-monitoring-grafana-operator
          registry: common-service
  3. To enable user workload monitoring, create the following ConfigMap, with enableUserWorkload: true:

    apiVersion: v1
    kind: ConfigMap
    metadata:
      name: cluster-monitoring-config
      namespace: openshift-monitoring
    data:
      config.yaml: |
        enableUserWorkload: true

    This step ensures that OCP is configured for user-defined project monitoring. For more information, see the OpenShift documentation: Enabling monitoring for user-defined projects.

Accessing monitoring from the Cloud Pak for Integration instance

  1. Log into the Cloud Pak for Integration instance (IBM Automation).

  2. Click Integration capabilities or Integration runtimes to get a list of the instances you intend to monitor: Creation form yaml

  3. Click Monitoring.