Enabling eBPF

The eBPF can be enabled during a fresh installation or via helm upgrade.

A. Enabling eBPF During Installation

If you are installing the Kubernetes 2.0 agent for the first time, follow these steps:

Step 1: Enable eBPF from OpsRamp UI

  1. Go to Setup → Account → Integrations → Kubernetes 2.0.
  2. Enable the eBPF checkbox.
  3. Select your container engine:
    • containerd
    • cri-o
    • docker

Event Management
4. (Optional) Provide a custom runtime socket:
--set containerSockFile.containerd=/path/custom/containerd.sock --set containerSockFile.cri-o=/path/custom/crio.sock

Step 2: Download the values.yaml File

After enabling the eBPF checkbox, go to the Instructions page and download or copy the YAML file for the Helm installation

Event Management

Step 3: Install the OpsRamp Agent on Your Cluster Using Helm

Run the Helm install command.

helm install opsramp oci://us-docker.pkg.dev/opsramp-registry/agent-helm-charts/agent -n opsramp-agent --create-namespace --values <download-file-path-or-copied-file-path>.yaml --set ebpf.enabled=true --set ebpf.logEndpoint="int.opsramp.net:443" --set containerSockFile.docker=/run/k3s/cri-dockerd/cri-dockerd.sock"

After installation:

  • ebpf.enabled is set to true.
  • The selected container runtime appears under containerRuntime in the values.yaml file.
Event Management

Refer to the Kubernetes 2.0 Agent Installation document for detailed steps.

B. Enabling eBPF on an Existing Installation

If the Kubernetes 2.0 Agent is already installed, you can enable eBPF using either method below.

Option 1: Helm Upgrade

Run the following command:

helm upgrade <release-name> <chart> --set ebpf.enabled=true

Option 2: Update Config + Upgrade

  1. Download latest values.yaml.
  2. Update the yaml file:
    • ebpf.enabled=true
    • Select runtime under containerRuntime
  3. Run Helm upgrade.
  4. A new eworker pod is deployed automatically.

CRD Configuration

By default, eBPF monitors all pods and nodes. Use the CRD to include/exclude specific workloads.

Step 1: Edit the CRD

Run the following command:

kubectl edit netobs networkobservabilityconfig

Sample CRD

apiVersion: network.agent.opsramp.com/v1
kind: NetworkObservability
metadata:
name: <resource-name>
namespace: <namespace>
spec:
targetCgroupSelectors:
- action: include | exclude
namespaces:
- <namespace1>
- <namespace2>
nodeNames:
- <node1>
- "*"

Key Field Definitions

FieldDescription
targetCgroupSelectorsList of selection rules for monitoring
actionInclude / exclude workloads
namespacesTarget namespaces (* allowed)
nodeNamesTarget nodes (* allowed)
matchLabelsFilter workloads by pod labels
matchAnnotationsFilter workloads by annotations

Step 2: Apply Changes

After updating the CRD file, run the following command to apply the changes.

kubectl apply -f crdconfig.yaml

Step 3: Verify

kubectl get netobs

Step 4: Describe for Details

kubectl describe netobs network-observability-config