You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/nginx-one/agent/metrics/configure-otel-metrics.md
+12-13Lines changed: 12 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -42,21 +42,21 @@ You can validate that metrics are successfully exported by using the methods bel
42
42
43
43
### Custom OTel Configuration
44
44
45
-
NGINX Agent generates a default OpenTelemetry config to send metrics to your management plane located at `/etc/nginx-agent/opentelemetry-collector-agent.yaml`. An option is provided to
46
-
bring your own OpenTelemetry configs which will be merged with the NGINX Agent default config.
45
+
NGINX Agent generates a default OpenTelemetry config (located at `/etc/nginx-agent/opentelemetry-collector-agent.yaml`) to send metrics to your management plane. An option is provided to
46
+
bring your own [OpenTelemetry configs](https://opentelemetry.io/docs/collector/configuration/) which will be merged with the NGINX Agent default config.
47
47
48
-
OpenTelemetry will merge your [OpenTelemetry Config](https://opentelemetry.io/docs/collector/configuration/). The **order of the OpenTelemetry config files matters**, the last config in the list will take priority over others listed if they have the same value configured.
48
+
The **order of the OpenTelemetry config files matters**: the last config in the list will take priority over others listed, if they have the same value configured.
49
49
50
50
To have NGINX Agent use your own OpenTelemetry config:
51
51
52
-
1. Edit the configuration file `sudo vim /etc/nginx-agent/nginx-agent.conf`
52
+
1. Edit the configuration file as root `vim /etc/nginx-agent/nginx-agent.conf`
53
53
2. Add the collector property
54
54
3. Save and restart the NGINX agent service `sudo systemctl restart nginx-agent`
55
55
56
56
```yaml
57
57
collector:
58
58
additional_config_paths:
59
-
- "/my_config.yaml"
59
+
- "/etc/nginx-agent/my_config.yaml"
60
60
```
61
61
62
62
#### Example usage
@@ -74,6 +74,7 @@ exporters:
74
74
endpoint: "127.0.0.1:5643"
75
75
resource_to_telemetry_conversion:
76
76
enabled: true
77
+
namespace: test-space
77
78
78
79
service:
79
80
pipelines:
@@ -95,6 +96,7 @@ exporters:
95
96
endpoint: "127.0.0.1:5643"
96
97
resource_to_telemetry_conversion:
97
98
enabled: true
99
+
namespace: test-space
98
100
99
101
service:
100
102
pipelines:
@@ -222,13 +224,10 @@ service:
222
224
223
225
### Troubleshooting
224
226
225
-
To view the merged OpenTelemetry configuration set the Agent log level to debug in `/etc/nginx-agent/nginx-agent.conf` and restart NGINX Agent
227
+
To view the merged OpenTelemetry configuration set the NGINX Agent log level to "debug" in `/etc/nginx-agent/nginx-agent.conf`, and restart NGINX Agent:
226
228
227
229
1. Edit the configuration file `sudo vim /etc/nginx-agent/nginx-agent.conf`
0 commit comments