Overview
The F5 NGINX Agent v3 now includes an embedded OpenTelemetry (OTel) Collector, streamlining observability and metric collection for NGINX instances. With this feature, you can collect:
- Metrics from NGINX Plus and NGINX OSS
- Host metrics (CPU, memory, disk, and network activity) from VMs or Containers
This guide walks you through enabling and configuring the embedded OpenTelemetry Collector for metric export.
Key Benefits
- Seamless Integration: No need to deploy an external OpenTelemetry Collector. All components are embedded within the Agent for streamlined observability.
- Standardized Protocol: Support for OpenTelemetry standards ensures interoperability with a wide range of observability backends, including Jaeger, Prometheus, Splunk, and more.
Configuration
How to send data to an OTel Collector - VM
Before you begin
- NGINX One Console Getting Started
- NGINX OSS installed on a Virtual Machine
- NGINX Agent v3 is installed
Setting Up the OTel Collector to Export Metrics to NGINX One Console
-
Enable NGINX Stub Status API to collect NGINX metrics in NGINX OSS. A sample Stub Status API configuration is shown below:
server { listen 127.0.0.1:8080; location /api { stub_status; allow 127.0.0.1; deny all; } }
-
Edit the
/etc/nginx-agent/nginx-agent.conf
and add the following.Make sure to replace your-data-plane-key-here with the real data plane key that you are using for your application or service.
collector: receivers: host_metrics: collection_interval: 1m0s initial_delay: 1s scrapers: cpu: {} memory: {} disk: {} network: {} filesystem: {} processors: batch: {} exporters: otlp_exporters: - server: host: <saas-host> port: 443 authenticator: headers_setter tls: skip_verify: false extensions: headers_setter: headers: - action: insert key: "authorization" value: "your-data-plane-key-here"
-
Restart the NGINX Agent service
sudo systemctl restart nginx-agent
Troubleshooting
-
Verify the OTel Collector is up and running
curl http://127.0.0.1:1337 | jq
The response should look like:
{
"status": "Server available",
"upSince": "2025-02-19T17:51:25.195637946Z",
"uptime": "5.601839172s"
}
- Check the OpenTelemetry collector agent log
sudo tail -n 100 /var/log/nginx-agent/opentelemetry-collector-agent.log
- Change the log level to debug