Skip to content

Set up Continuous Profiling with Kubernetes

This guide provides step-by-step instructions for setting up Continuous Profiling (CP) in a Kubernetes environment. Coralogix Continuous Profiling allows you to capture low-overhead CPU, helping you identify performance bottlenecks directly within the Coralogix platform.

You can install Continuous Profiling in two ways:

Prerequisites

  • Ensure that kubectl is installed.
  • Confirm environment requirements:

    • Kubernetes v1.24+
    • Helm v3.9+

    To verify your Helm version, run the following:

    helm version
    

Install with CP agent and Coralogix collector (Helm)

This installation path provides full control over deployment and configuration using Helm. The Coralogix collector, which includes the OpenTelemetry (OTel) collector, serves as the central component for receiving and forwarding telemetry data-including profiling, traces, and metrics-into the Coralogix platform. By deploying the CP agent alongside the collector, you enable comprehensive observability across your Kubernetes workloads.

Note

If you have the Coralogix collector already installed, you can skip steps 1 and 2.

  1. Add the Coralogix Helm chart repository and update your local Helm repo cache by running:

    helm repo add coralogix https://cgx.jfrog.io/artifactory/coralogix-charts-virtual
    helm repo update
    
  2. Create the required secret. Ensure a Kubernetes secret named coralogix-keys exists and includes your Coralogix Private API Key. If it doesn't, use the command below to create it:

    kubectl create secret generic coralogix-keys --from-literal=PRIVATE_KEY="<Your Coralogix Private API Key>"
    
  3. Add the following to your values.yaml file:

    opentelemetry-agent:
      enabled: true
      presets:
        profilesCollection:
          enabled: true
    
      command:
        extraArgs: [ "--feature-gates=service.profilesSupport" ]
    
    coralogix-ebpf-profiler:
      enabled: true
    
  4. Deploy Continuous Profiling by running the following. Replace <cluster name> and <Your Coralogix Region Domain> with the appropriate values:

    helm upgrade --install otel-coralogix-integration coralogix/otel-integration \
      --version=0.0.223 \
      --render-subchart-notes \
      --set global.domain="<Your Coralogix Domain>" \
      --set global.clusterName="<cluster name>" \
      -f values.yaml
    

    Note

    By default, the Coralogix Continuous Profiling agent collects profiling data from all services across your Kubernetes cluster.

    To limit data collection to specific nodes—for instance, to avoid monitoring system-critical or infrastructure-dedicated nodes—you can configure node affinity, anti-affinity, and tolerations.

    These Kubernetes features allow fine-grained control over pod scheduling, enabling you to tailor where the profiling agent is deployed based on node characteristics and cluster topology.

Install with Kubernetes Complete Observability (UI)

Coralogix provides a UI-based onboarding flow for Kubernetes complete observability. This method simplifies setup by guiding you through the installation process.

Note

This integration is designed and tested for clean installs. Applying it to existing deployments may require additional checks and adjustments.

Warning

If you’ve already installed the integration using the default values.yaml, be aware that upgrading may overwrite existing configurations, and behavior in your environment is unpredictable. We strongly recommend testing updates in a staging environment first to verify compatibility, stability, and ensure you can take full advantage of new features and best practices.

Set up the integration in Coralogix

  1. In your Coralogix toolbar, navigate to Data Flow > Integrations.
  2. From the Integrations section, select Kubernetes Complete Observability.
  3. On the Kubernetes Complete Observability integration page, click + Setup Collector to create a new integration. For existing integrations, click the arrow icon on the right to upgrade to the new version.

    k8s integration upgrade

  4. Provide a name to identify this integration (especially useful if you have multiple clusters).

  5. Enter a Send-Your-Data API key or click Create a New Key to generate a new dedicated API key.
  6. Enter your Kubernetes cluster name in the Cluster Name field.
  7. Enter your Kubernetes namespace in the Namespace field. If left empty, the namespace from your current kubectl context will be used.
  8. Select the operating system and environment that your Kubernetes workloads are deployed on.
  9. Click Next.

    k8s integration setup

Enable Profiling

  1. Navigate to Observability features > APM & Tracing (default: on).
  2. Toggle Profiling on (default: off) and configure Samples per second (default: 20) to control how often data is sampled.

  3. Click Save.

Review and deploy

This step in the integration UI provides all required commands. Use the UI directly and note these options for working with the generated values.yaml:

  • Copy/Download – Copy the generated configuration to your clipboard or download the values.yaml/Kubernetes manifest as a file for version control and reuse.
  • Deployment code – View and copy the full helm upgrade command with your values.yaml embedded.

When finished, return to the UI and click Complete setup.

Download values.yaml

Next steps

To produce meaningful profiling insights for compiled languages like Go, Rust, C, C++, or Haskell, Coralogix Continuous Profiling requires access to debug symbols—also referred to as debuginfos. Find out more about uploading symbols here.