docs: updates to support prometheus data source learning journey (#100363)

* updates to support prometheus data source learning journey

* makes prettier
This commit is contained in:
Christopher Moyer 2025-02-11 10:20:47 -06:00 committed by GitHub
parent c15c9f8af6
commit 53ae85ca57
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -48,6 +48,8 @@ Grafana ships with built-in support for Prometheus. If you are new to Prometheus
## Configure the data source
{{< shared id="add-prom-data-source" >}}
To add the Prometheus data source, complete the following steps:
1. Click **Connections** in the left-side menu.
@ -55,6 +57,9 @@ To add the Prometheus data source, complete the following steps:
1. Enter `Prometheus` in the search bar.
1. Select **Prometheus**.
1. Click **Add new data source** in the upper right.
1. Enter a name for the data source.
{{< /shared >}}
You will be taken to the **Settings** tab where you will set up your Prometheus configuration.
@ -70,7 +75,8 @@ The first option to configure is the name of your connection:
### Connection section
- **Prometheus server URL** - The URL of your Prometheus server. If your Prometheus server is local, use `http://localhost:9090`. If it is on a server within a network, this is the URL with port where you are running Prometheus. Example: `http://prometheus.example.orgname:9090`.
- **Prometheus server URL** - The URL of your Prometheus server. {{< shared id="prom-data-source-url" >}}
If your Prometheus server is local, use `http://localhost:9090`. If it's on a server within a network, this is the URL with the port where you are running Prometheus. Example: `http://prometheus.example.orgname:9090`.
{{< admonition type="note" >}}
@ -80,6 +86,8 @@ You should use the IP address of the Prometheus container, or the hostname if yo
{{< /admonition >}}
{{< /shared >}}
### Authentication section
There are several authentication methods you can choose in the Authentication section.
@ -171,3 +179,15 @@ Support for exemplars is available only for the Prometheus data source. If this
- **Label name** - The name of the field in the `labels` object used to obtain the traceID property.
- **Remove exemplar link** - Click to remove existing links.
### Troubleshooting
Refer to the following troubleshooting information, as required.
#### Data doesn't appear in Explore metrics
If metric data doesn't appear in Explore after you've successfully tested a connection to a Prometheus data source, ensure that you've selected the correct data source in the **Data source** drop-down menu.
The following image shows the **Data source** field in Explore metrics.
![Image that shows Prometheus metrics in Explore](/media/docs/grafana/data-sources/prometheus/troubleshoot-connection-1.png)