Skip to content

Commit ad0f69c

Browse files
Merge pull request #266865 from gracewehner/main
[Managed Prometheus] Add warning for debug mode and fix port number
2 parents c65ed52 + 4d15f4b commit ad0f69c

File tree

2 files changed

+11
-4
lines changed

2 files changed

+11
-4
lines changed

articles/azure-monitor/containers/prometheus-metrics-scrape-configuration.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,10 @@ The new label also shows up in the cluster parameter dropdown in the Grafana das
114114
> Only alphanumeric characters are allowed. Any other characters are replaced with `_`. This change is to ensure that different components that consume this label adhere to the basic alphanumeric convention.
115115
116116
### Debug mode
117+
118+
> [!WARNING]
119+
> This mode can affect performance and should only be enabled for a short time for debugging purposes.
120+
117121
To view every metric that's being scraped for debugging purposes, the metrics add-on agent can be configured to run in debug mode by updating the setting `enabled` to `true` under the `debug-mode` setting in the [configmap](https://aka.ms/azureprometheus-addon-settings-configmap) `ama-metrics-settings-configmap`. You can either create this configmap or edit an existing one. For more information, see the [Debug mode section in Troubleshoot collection of Prometheus metrics](prometheus-metrics-troubleshoot.md#debug-mode).
118122
119123
### Scrape interval settings

articles/azure-monitor/containers/prometheus-metrics-troubleshoot.md

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -116,15 +116,18 @@ If there are no issues and the intended targets are being scraped, you can view
116116
117117
## Debug mode
118118
119-
The metrics addon can be configured to run in debug mode by changing the configmap setting `enabled` under `debug-mode` to `true` by following the instructions [here](prometheus-metrics-scrape-configuration.md#debug-mode). This mode can affect performance and should only be enabled for a short time for debugging purposes.
119+
> [!WARNING]
120+
> This mode can affect performance and should only be enabled for a short time for debugging purposes.
120121
121-
When enabled, all Prometheus metrics that are scraped are hosted at port 9090. Run the following command:
122+
The metrics addon can be configured to run in debug mode by changing the configmap setting `enabled` under `debug-mode` to `true` by following the instructions [here](prometheus-metrics-scrape-configuration.md#debug-mode).
123+
124+
When enabled, all Prometheus metrics that are scraped are hosted at port 9091. Run the following command:
122125
123126
```
124-
kubectl port-forward <ama-metrics pod name> -n kube-system 9090
127+
kubectl port-forward <ama-metrics pod name> -n kube-system 9091
125128
```
126129
127-
Go to `127.0.0.1:9090/metrics` in a browser to see if the metrics were scraped by the OpenTelemetry Collector. This user interface can be accessed for every `ama-metrics-*` pod. If metrics aren't there, there could be an issue with the metric or label name lengths or the number of labels. Also check for exceeding the ingestion quota for Prometheus metrics as specified in this article.
130+
Go to `127.0.0.1:9091/metrics` in a browser to see if the metrics were scraped by the OpenTelemetry Collector. This user interface can be accessed for every `ama-metrics-*` pod. If metrics aren't there, there could be an issue with the metric or label name lengths or the number of labels. Also check for exceeding the ingestion quota for Prometheus metrics as specified in this article.
128131
129132
## Metric names, label names & label values
130133

0 commit comments

Comments
 (0)