mirror of https://github.com/grafana/grafana
Docs: refactors config panels and visualizations, corrects relrefs (#55940)
* refactors config panels and visualizations, corrects relrefs * adds an alias * Remove some old content * moves visualizations topic to the root * moves out panels and visualization topics to the root * adds move and resize panel to add/organize panel; creates a create dashboard topic under build dashboards; adjusts context of add a panel to be from within an existing dashboard * updates aliases * creates search at root, moves dashboard preview to search, creates standalone search dashboard topic * moves Set dashboard time range to use-dashboards, creates modify dashboard settings and adds moves Modify dashboard time settings to that topic * moves existing query-options topic from working with panels to configure-panel-visualizations, moves panel time overrides and timeshift content to query options * Moving things to better category, fixing links, improving ordering * Move panel inspector to main panel topic * completes partial fix of relrefs * relref fixes con't * restructures remaining panels topics * more relref fixes * Minor fix * Minor tweak * finishes fixing relrefs Co-authored-by: Torkel Ödegaard <torkel@grafana.com> Co-authored-by: Jack Baldry <jack.baldry@grafana.com>pull/56754/head
parent
f4a3400a9c
commit
414d536186
@ -1,136 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/working-with-panels/navigate-panel-editor/ |
||||
- /docs/grafana/latest/panels/working-with-panels/navigate-inspector-panel/ |
||||
- /docs/grafana/latest/dashboards/dashboard-create/ |
||||
- /docs/grafana/latest/features/dashboard/dashboards/ |
||||
- /docs/grafana/latest/panels/working-with-panels/add-panel/ |
||||
- /docs/grafana/latest/dashboards/add-organize-panels/ |
||||
- /docs/grafana/latest/panels/add-panels-dynamically/about-repeating-panels-rows/ |
||||
- /docs/grafana/latest/panels/add-panels-dynamically/configure-repeating-rows/ |
||||
- /docs/grafana/latest/panels/add-panels-dynamically/configure-repeating-panels/ |
||||
- /docs/grafana/next/dashboards/build-dashboards/add-organize-panels/ |
||||
title: Add and organize panels |
||||
menuTitle: Add and organize panels |
||||
weight: 200 |
||||
keywords: |
||||
- panel |
||||
- dashboard |
||||
- dynamic |
||||
- rows |
||||
- add |
||||
--- |
||||
|
||||
# Add and organize panels |
||||
|
||||
This section describes the areas of the Grafana panel editor. |
||||
|
||||
1. Panel header: The header section lists the dashboard in which the panel appears and the following controls: |
||||
|
||||
- **Dashboard settings (gear) icon:** Click to access the dashboard settings. |
||||
- **Discard:** Discards changes you have made to the panel since you last saved the dashboard. |
||||
- **Save:** Saves changes you made to the panel. |
||||
- **Apply:** Applies changes you made and closes the panel editor, returning you to the dashboard. You will have to save the dashboard to persist the applied changes. |
||||
|
||||
1. Visualization preview: The visualization preview section contains the following options: |
||||
|
||||
- **Table view:** Convert any visualization to a table so that you can see the data. Table views are useful for troubleshooting. |
||||
- **Fill:** The visualization preview fills the available space. If you change the width of the side pane or height of the bottom pane the visualization changes to fill the available space. |
||||
- **Actual:** The visualization preview will have the exact size as the size on the dashboard. If not enough space is available, the visualization will scale down preserving the aspect ratio. |
||||
- **Time range controls:** For more information, refer to [Time range controls]({{< relref "../../manage-dashboards/#configure-dashboard-time-range-controls" >}}). |
||||
|
||||
1. Data section: The data section contains tabs where you enter queries, transform your data, and create alert rules (if applicable). |
||||
|
||||
- **Query tab:** Select your data source and enter queries here. For more information, refer to [Add a query]({{< relref "../../../panels/query-a-data-source/add-a-query/" >}}). |
||||
- **Transform tab:** Apply data transformations. For more information, refer to [Transform data]({{< relref "../../../panels/transform-data/" >}}). |
||||
- **Alert tab:** Write alert rules. For more information, refer to [Overview of Grafana 8 alerting]({{< relref "../../../alerting/" >}}). |
||||
|
||||
1. Panel display options: The display options section contains tabs where you configure almost every aspect of your data visualization. |
||||
|
||||
> Not all options are available for each visualization. |
||||
|
||||
{{< figure src="/static/img/docs/panel-editor/panel-editor-8-0.png" class="docs-image--no-shadow" max-width="1500px" >}} |
||||
|
||||
## Open the panel inspect drawer |
||||
|
||||
The inspect drawer helps you understand and troubleshoot your panels. You can view the raw data for any panel, export that data to a comma-separated values (CSV) file, view query requests, and export panel and data JSON. |
||||
|
||||
> **Note:** Not all panel types include all tabs. For example, dashboard list panels do not have raw data to inspect, so they do not display the Stats, Data, or Query tabs. |
||||
|
||||
The panel inspector consists of the following options: |
||||
|
||||
1. The panel inspect drawer displays opens a drawer on the right side. Click the arrow in the upper right corner to expand or reduce the drawer pane. |
||||
|
||||
1. **Data tab -** Shows the raw data returned by the query with transformations applied. Field options such as overrides and value mappings are not applied by default. |
||||
|
||||
1. **Stats tab -** Shows how long your query takes and how much it returns. |
||||
|
||||
1. **JSON tab -** Allows you to view and copy the panel JSON, panel data JSON, and data frame structure JSON. This is useful if you are provisioning or administering Grafana. |
||||
|
||||
1. **Query tab -** Shows you the requests to the server sent when Grafana queries the data source. |
||||
|
||||
1. **Error tab -** Shows the error. Only visible when query returns error. |
||||
|
||||
## Create a dashboard and add a panel |
||||
|
||||
Dashboards and panels allow you to show your data in visual form. Each panel needs at least one query to display a visualization. |
||||
|
||||
**Before you begin:** |
||||
|
||||
- Ensure that you have the proper permissions. For more information about permissions, refer to [About users and permissions]({{< relref "../../../administration/roles-and-permissions/" >}}). |
||||
- Identify the dashboard to which you want to add the panel. |
||||
- Understand the query language of the target data source. |
||||
- Ensure that data source for which you are writing a query has been added. For more information about adding a data source, refer to [Add a data source]({{< relref "../../../datasources/add-a-data-source/" >}}) if you need instructions. |
||||
|
||||
**To create a dashboard and add a panel**: |
||||
|
||||
1. Sign in to Grafana, hover your cursor over **Dashboard**, and click **+ New Dashboard**. |
||||
1. Click **Add a new panel**. |
||||
1. In the first line of the **Query** tab, click the drop-down list and select a data source. |
||||
1. Write or construct a query in the query language of your data source. |
||||
|
||||
For more information about data sources, refer to [Data sources]({{< relref "../../../datasources/" >}}) for specific guidelines. |
||||
|
||||
1. In the Visualization list, select a visualization type. |
||||
|
||||
Grafana displays a preview of your query results with the visualization applied. |
||||
|
||||
 |
||||
|
||||
For more information about individual visualizations, refer to [Visualizations options]({{< relref "../../../visualizations/" >}}). |
||||
|
||||
1. Refer to the following documentation for ways you can adjust panel settings. |
||||
|
||||
While not required, most visualizations need some adjustment before they properly display the information that you need. |
||||
|
||||
- [Configure value mappings]({{< relref "../../../panels/configure-value-mappings" >}}) |
||||
- [Visualization-specific options]({{< relref "../../../visualizations/" >}}) |
||||
- [Override field values]({{< relref "../../../panels/configure-overrides/" >}}) |
||||
- [Configure thresholds]({{< relref "../../../panels/configure-thresholds/" >}}) |
||||
- [Configure standard options]({{< relref "../../../panels/configure-standard-options/" >}}) |
||||
|
||||
1. Add a note to describe the visualization (or describe your changes) and then click **Save** in the upper-right corner of the page. |
||||
|
||||
Notes can be helpful if you need to revert the dashboard to a previous version. |
||||
|
||||
## Configure repeating rows |
||||
|
||||
You can configure Grafana to dynamically add panels or rows to a dashboard based on the value of a variable. Variables dynamically change your queries across all rows in a dashboard. For more information about repeating panels, refer to [Configure repeating panels](../../panels/configure-panel-options/#configure-repeating-panels). |
||||
|
||||
To see an example of repeating rows, refer to [Dashboard with repeating rows](https://play.grafana.org/d/000000153/repeat-rows). The example shows that you can also repeat rows if you have variables set with `Multi-value` or `Include all values` selected. |
||||
|
||||
**Before you begin:** |
||||
|
||||
- Ensure that the query includes a multi-value variable. |
||||
|
||||
**To configure repeating rows:** |
||||
|
||||
1. On the dashboard home page, click **Add panel**. |
||||
|
||||
1. On the **Add a panel** dialog box, click **Add a new row**. |
||||
|
||||
1. Hover over the row title and click the cog icon. |
||||
|
||||
1. On the **Row Options** dialog box, add a title and select the variable for which you want to add repeating rows. |
||||
|
||||
> **Note:** To provide context to dashboard users, add the variable to the row title. |
@ -0,0 +1,92 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/dashboards/build-dashboards/create-dashboard/ |
||||
- /docs/grafana/latest/dashboards/build-dashboards/add-organize-panels/ |
||||
title: Create a dashboard |
||||
menuTitle: Create a dashboard |
||||
weight: 1 |
||||
keywords: |
||||
- panel |
||||
- dashboard |
||||
- create |
||||
--- |
||||
|
||||
## Create a dashboard |
||||
|
||||
Dashboards and panels allow you to show your data in visual form. Each panel needs at least one query to display a visualization. |
||||
|
||||
**Before you begin:** |
||||
|
||||
- Ensure that you have the proper permissions. For more information about permissions, refer to [About users and permissions]({{< relref "../../../administration/roles-and-permissions/" >}}). |
||||
- Identify the dashboard to which you want to add the panel. |
||||
- Understand the query language of the target data source. |
||||
- Ensure that data source for which you are writing a query has been added. For more information about adding a data source, refer to [Add a data source]({{< relref "../../../datasources/add-a-data-source/" >}}) if you need instructions. |
||||
|
||||
**To create a dashboard**: |
||||
|
||||
1. Sign in to Grafana, hover your cursor over **Dashboard**, and click **+ New Dashboard**. |
||||
1. Click **Add a new panel**. |
||||
1. In the first line of the **Query** tab, click the drop-down list and select a data source. |
||||
1. Write or construct a query in the query language of your data source. |
||||
|
||||
For more information about data sources, refer to [Data sources]({{< relref "../../../datasources/" >}}) for specific guidelines. |
||||
|
||||
1. In the Visualization list, select a visualization type. |
||||
|
||||
Grafana displays a preview of your query results with the visualization applied. |
||||
|
||||
 |
||||
|
||||
For more information about individual visualizations, refer to [Visualizations options]({{< relref "../../../panels-visualizations/visualizations/" >}}). |
||||
|
||||
1. Refer to the following documentation for ways you can adjust panel settings. |
||||
|
||||
While not required, most visualizations need some adjustment before they properly display the information that you need. |
||||
|
||||
- [Configure value mappings]({{< relref "../../../panels-visualizations/configure-value-mappings" >}}) |
||||
- [Visualization-specific options]({{< relref "../../../panels-visualizations/visualizations/" >}}) |
||||
- [Override field values]({{< relref "../../../panels-visualizations/configure-overrides/" >}}) |
||||
- [Configure thresholds]({{< relref "../../../panels-visualizations/configure-thresholds/" >}}) |
||||
- [Configure standard options]({{< relref "../../../panels-visualizations/configure-standard-options/" >}}) |
||||
|
||||
1. Add a note to describe the visualization (or describe your changes) and then click **Save** in the upper-right corner of the page. |
||||
|
||||
Notes can be helpful if you need to revert the dashboard to a previous version. |
||||
|
||||
## Configure repeating rows |
||||
|
||||
You can configure Grafana to dynamically add panels or rows to a dashboard based on the value of a variable. Variables dynamically change your queries across all rows in a dashboard. For more information about repeating panels, refer to [Configure repeating panels](../../panels/configure-panel-options/#configure-repeating-panels). |
||||
|
||||
To see an example of repeating rows, refer to [Dashboard with repeating rows](https://play.grafana.org/d/000000153/repeat-rows). The example shows that you can also repeat rows if you have variables set with `Multi-value` or `Include all values` selected. |
||||
|
||||
**Before you begin:** |
||||
|
||||
- Ensure that the query includes a multi-value variable. |
||||
|
||||
**To configure repeating rows:** |
||||
|
||||
1. On the dashboard home page, click **Add panel**. |
||||
|
||||
1. On the **Add a panel** dialog box, click **Add a new row**. |
||||
|
||||
1. Hover over the row title and click the cog icon. |
||||
|
||||
1. On the **Row Options** dialog box, add a title and select the variable for which you want to add repeating rows. |
||||
|
||||
> **Note:** To provide context to dashboard users, add the variable to the row title. |
||||
|
||||
## Move a panel |
||||
|
||||
You can place a panel on a dashboard in any location. |
||||
|
||||
1. Open the dashboard. |
||||
|
||||
1. Click the panel title and drag the panel to the new location. |
||||
|
||||
## Resize a panel |
||||
|
||||
You can size a dashboard panel to suits your needs. |
||||
|
||||
1. Open the dashboard. |
||||
|
||||
1. To adjust the size of the panel, click and drag the lower-right corner of the panel. |
@ -0,0 +1,29 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/dashboards/build-dashboards/modify-dashboard-settings/ |
||||
title: Modify dashboard settings |
||||
menuTitle: Dashboard settings |
||||
weight: 8 |
||||
keywords: |
||||
- xxx |
||||
--- |
||||
|
||||
# Modify dashboard settings |
||||
|
||||
xxxxx. |
||||
|
||||
## Modify dashboard time settings |
||||
|
||||
Time settings are saved on a per-dashboard basis. |
||||
|
||||
You can change the **Timezone** and **fiscal year** settings from the time range controls by clicking the **Change time settings** button. |
||||
|
||||
For more advanced time settings, click the **Dashboard settings** (gear) icon at the top of the page. Then navigate to the **Time Options** section of the **General** tab. |
||||
|
||||
- **Timezone:** Specify the local time zone of the service or system that you are monitoring. This can be helpful when monitoring a system or service that operates across several time zones. |
||||
- **Default:** The default selected time zone for the user profile, team, or organization is used. If no time zone is specified for the user profile, a team the user is a member of, or the organization, then Grafana uses local browser time. |
||||
- **Local browser time:** The time zone configured for the viewing user browser is used. This is usually the same time zone as set on the computer. |
||||
- Standard [ISO 8601 time zones](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones), including UTC. |
||||
- **Auto-refresh:** Customize the options displayed for relative time and the auto-refresh options. Entries are comma separated and accept any valid time unit. |
||||
- **Now delay:** Override the `now` time by entering a time delay. Use this option to accommodate known delays in data aggregation to avoid null values. |
||||
- **Hide time picker:** Select this option if you do not want Grafana to display the time picker. |
@ -1,148 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/dashboards/dashboard-ui/ |
||||
- /docs/grafana/latest/dashboards/dashboard-ui/dashboard-header/ |
||||
- /docs/grafana/latest/features/dashboard/dashboards/ |
||||
- /docs/grafana/latest/dashboards/dashboard-ui/dashboard-row/ |
||||
- /docs/grafana/latest/features/dashboard/dashboards/ |
||||
- /docs/grafana/latest/dashboards/shortcuts/ |
||||
- /docs/grafana/latest/dashboards/search/ |
||||
- /docs/grafana/latest/reference/search/ |
||||
title: 'Use dashboards' |
||||
menuTitle: Use dashboards |
||||
weight: 1 |
||||
keywords: |
||||
- dashboard |
||||
- search |
||||
- shortcuts |
||||
--- |
||||
|
||||
# Use dashboards |
||||
|
||||
This topic provides an overview of dashboard features and shortcuts, and describes how to use dashboard search. |
||||
|
||||
## Dashboard feature overview |
||||
|
||||
The dashboard user interface provides a number of features that you can use to customize the presentation of your data. |
||||
|
||||
The following image and descriptions highlights all dashboards features. |
||||
|
||||
{{< figure src="/static/img/docs/v91/dashboard-features/dashboard-features.png" width="700px" >}} |
||||
|
||||
- **Grafana home** (1): Click the Grafana home icon to be redirected to the home page configured in the Grafana instance. |
||||
- **Dashboard title** (2): When you click the dashboard title you can search for dashboard contained in the current folder. |
||||
- **Share dashboard** (3): Use this option to share the current dashboard by link or snapshot. You can also export the dashboard definition from the share modal. |
||||
- **Add panel** (4): Use this option to add a panel, dashboard row, or library panel to the current dashboard. |
||||
- **Dashboard settings** (5): Use this option to change dashboard name, folder, and tags and manage variables and annotation queries. |
||||
- **Time picker dropdown** (6): Click to select relative time range options and set custom absolute time ranges. |
||||
- **Zoom out time range** (7): Click to zoom out the time range. For more information about how to use time range controls, refer to [Common time range controls](../time-range-controls/#common-time-range-controls). |
||||
- **Refresh dashboard** (8): Click to immediately trigger queries and refresh dashboard data. |
||||
- **Refresh dashboard time interval** (9): Click to select a dashboard auto refresh time interval. |
||||
- **View mode** (10): Click to display the dashboard on a large screen such as a TV or a kiosk. View mode hides irrelevant information such as navigation menus. For more information about view mode, refer to [How to Create Kiosks to Display Dashboards on a TV](https://grafana.com/blog/2019/05/02/grafana-tutorial-how-to-create-kiosks-to-display-dashboards-on-a-tv/). |
||||
- **Dashboard panel** (11): The primary building block of a dashboard is the panel. To add a new panel, dashboard row, or library panel, click **Add panel**. |
||||
- Library panels can be shared among many dashboards. |
||||
- To move a panel, drag the panel header to another location. |
||||
- To resize a panel, click and drag the lower right corner of the panel. |
||||
- **Graph legend** (12): Change series colors, y-axis and series visibility directly from the legend. |
||||
- **Search** (13): Click **Search** to search for dashboards by name or panel title. |
||||
- **Dashboard row** (14): A dashboard row is a logical divider within a dashboard that groups panels together. |
||||
- Rows can be collapsed or expanded allowing you to hide parts of the dashboard. |
||||
- Panels inside a collapsed row do not issue queries. |
||||
- Use the [repeating rows]({{< relref "../panels/configure-panel-options/#configure-repeating-rows" >}}) to dynamically create rows based on a template variable. |
||||
|
||||
## Keyboard shortcuts |
||||
|
||||
Grafana has a number of keyboard shortcuts available. Press `?` or `h` on your keyboard to display all keyboard shortcuts available in your version of Grafana. |
||||
|
||||
- `Ctrl+S`: Saves the current dashboard. |
||||
- `f`: Opens the dashboard finder / search. |
||||
- `d+k`: Toggle kiosk mode (hides the menu). |
||||
- `d+e`: Expand all rows. |
||||
- `d+s`: Dashboard settings. |
||||
- `Ctrl+K`: Opens the command palette. |
||||
- `Esc`: Exits panel when in fullscreen view or edit mode. Also returns you to the dashboard from dashboard settings. |
||||
|
||||
**Focused panel** |
||||
|
||||
By hovering over a panel with the mouse you can use some shortcuts that will target that panel. |
||||
|
||||
- `e`: Toggle panel edit view |
||||
- `v`: Toggle panel fullscreen view |
||||
- `ps`: Open Panel Share Modal |
||||
- `pd`: Duplicate Panel |
||||
- `pr`: Remove Panel |
||||
- `pl`: Toggle panel legend |
||||
|
||||
## Dashboard search |
||||
|
||||
You can search for dashboards by dashboard name and by panel title. When you search for dashboards, the system returns all dashboards available within the Grafana instance, even if you do not have permission to view the contents of the dashboard. |
||||
|
||||
### Search dashboards using dashboard name |
||||
|
||||
Begin typing any part of the dashboard name in the search bar. The search returns results for any partial string match in real-time, as you type. |
||||
|
||||
Dashboard search is: |
||||
|
||||
- Real-time |
||||
- _Not_ case sensitive |
||||
- Functional across stored _and_ file based dashboards. |
||||
|
||||
> \*\*Note: You can use your keyboard arrow keys to navigate the results and press `Enter` to open the selected dashboard. |
||||
|
||||
The following image shows the search results when you search using dashboard name. |
||||
|
||||
{{< figure src="/static/img/docs/v91/dashboard-features/search-by-dashboard-name.png" width="700px" >}} |
||||
|
||||
### Search dashboards using panel title |
||||
|
||||
You can search for a dashboard by the title of a panel that appears in a dashboard. |
||||
If a panel's title matches your search query, the dashboard appears in the search results. |
||||
|
||||
This feature is available by default in Grafana Cloud and in Grafana OSS v9.1 and higher, you access this feature by enabling the `panelTitleSearch` feature toggle. |
||||
For more information about enabling panel title search, refer to [Enable the panelTitleSearch feature toggle.](#enable-panelTitleSearch-feature-toggle) |
||||
|
||||
The following image shows the search results when you search using panel title. |
||||
|
||||
{{< figure src="/static/img/docs/v91/dashboard-features/search-by-panel-title.png" width="700px" >}} |
||||
|
||||
#### Enable the panelTitleSearch feature toggle |
||||
|
||||
Complete the following steps to enable the `panelTitleSearch` feature toggle. |
||||
|
||||
**Before you begin:** |
||||
|
||||
- If you are running Grafana Enterprise with RBAC, enable [service accounts]({{< relref "../administration/service-accounts/" >}}). |
||||
|
||||
**To enable the panelTitleSearch feature toggle:** |
||||
|
||||
1. Open the Grafana [configuration file]({{< relref "../setup-grafana/configure-grafana/#configuration-file-location" >}}). |
||||
|
||||
1. Locate the [feature_toggles]({{< relref "../setup-grafana/configure-grafana/#feature_toggles" >}}) section. |
||||
|
||||
1. Add the following parameter to the `feature_toggles` section: |
||||
|
||||
``` |
||||
[feature_toggles] |
||||
# enable features, separated by spaces |
||||
enable = dashboardPreviews |
||||
``` |
||||
|
||||
1. Save your changes and restart the Grafana server. |
||||
|
||||
### Filter dashboard search results by tag(s) |
||||
|
||||
Tags are a great way to organize your dashboards, especially as the number of dashboards grow. You can add and manage tags in dashboard `Settings`. |
||||
|
||||
When you select multiple tags, Grafana shows dashboards that include all selected tags. |
||||
|
||||
To filter dashboard search result by a tag, complete one of the following steps: |
||||
|
||||
- To filter dashboard search results by tag, click a tag that appears in the right column of the search results. |
||||
|
||||
You can continue filtering by clicking additional tags. |
||||
|
||||
- To see a list of all available tags, click the **Filter by tags** dropdown menu and select a tag. |
||||
|
||||
All tags will be shown, and when you select a tag, the dashboard search will be instantly filtered. |
||||
|
||||
> **Note:** When using only a keyboard, press the `tab` key and navigate to the **Filter by tag** drop-down menu, press the down arrow key `▼` to activate the menu and locate a tag, and press `Enter` to select the tag. |
@ -0,0 +1,177 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/dashboards/dashboard-ui/ |
||||
- /docs/grafana/latest/dashboards/dashboard-ui/dashboard-header/ |
||||
- /docs/grafana/latest/features/dashboard/dashboards/ |
||||
- /docs/grafana/latest/dashboards/dashboard-ui/dashboard-row/ |
||||
- /docs/grafana/latest/features/dashboard/dashboards/ |
||||
- /docs/grafana/latest/dashboards/shortcuts/ |
||||
- /docs/grafana/latest/dashboards/search/ |
||||
- /docs/grafana/latest/reference/search/ |
||||
- /docs/grafana/latest/dashboards/use-dashboards/ |
||||
title: Use dashboards |
||||
menuTitle: Use dashboards |
||||
weight: 1 |
||||
keywords: |
||||
- dashboard |
||||
- search |
||||
- shortcuts |
||||
--- |
||||
|
||||
# Use dashboards |
||||
|
||||
This topic provides an overview of dashboard features and shortcuts, and describes how to use dashboard search. |
||||
|
||||
## Dashboard feature overview |
||||
|
||||
The dashboard user interface provides a number of features that you can use to customize the presentation of your data. |
||||
|
||||
The following image and descriptions highlights all dashboards features. |
||||
|
||||
{{< figure src="/static/img/docs/v91/dashboard-features/dashboard-features.png" width="700px" >}} |
||||
|
||||
- **Grafana home** (1): Click the Grafana home icon to be redirected to the home page configured in the Grafana instance. |
||||
- **Dashboard title** (2): When you click the dashboard title you can search for dashboard contained in the current folder. |
||||
- **Share dashboard** (3): Use this option to share the current dashboard by link or snapshot. You can also export the dashboard definition from the share modal. |
||||
- **Add panel** (4): Use this option to add a panel, dashboard row, or library panel to the current dashboard. |
||||
- **Dashboard settings** (5): Use this option to change dashboard name, folder, and tags and manage variables and annotation queries. |
||||
- **Time picker dropdown** (6): Click to select relative time range options and set custom absolute time ranges. |
||||
- **Zoom out time range** (7): Click to zoom out the time range. For more information about how to use time range controls, refer to [Common time range controls](../time-range-controls/#common-time-range-controls). |
||||
- **Refresh dashboard** (8): Click to immediately trigger queries and refresh dashboard data. |
||||
- **Refresh dashboard time interval** (9): Click to select a dashboard auto refresh time interval. |
||||
- **View mode** (10): Click to display the dashboard on a large screen such as a TV or a kiosk. View mode hides irrelevant information such as navigation menus. For more information about view mode, refer to [How to Create Kiosks to Display Dashboards on a TV](https://grafana.com/blog/2019/05/02/grafana-tutorial-how-to-create-kiosks-to-display-dashboards-on-a-tv/). |
||||
- **Dashboard panel** (11): The primary building block of a dashboard is the panel. To add a new panel, dashboard row, or library panel, click **Add panel**. |
||||
- Library panels can be shared among many dashboards. |
||||
- To move a panel, drag the panel header to another location. |
||||
- To resize a panel, click and drag the lower right corner of the panel. |
||||
- **Graph legend** (12): Change series colors, y-axis and series visibility directly from the legend. |
||||
- **Search** (13): Click **Search** to search for dashboards by name or panel title. |
||||
- **Dashboard row** (14): A dashboard row is a logical divider within a dashboard that groups panels together. |
||||
- Rows can be collapsed or expanded allowing you to hide parts of the dashboard. |
||||
- Panels inside a collapsed row do not issue queries. |
||||
- Use [repeating rows]({{< relref "../build-dashboards/create-dashboard/#configure-repeating-rows" >}}) to dynamically create rows based on a template variable. |
||||
|
||||
## Keyboard shortcuts |
||||
|
||||
Grafana has a number of keyboard shortcuts available. Press `?` or `h` on your keyboard to display all keyboard shortcuts available in your version of Grafana. |
||||
|
||||
- `Ctrl+S`: Saves the current dashboard. |
||||
- `f`: Opens the dashboard finder / search. |
||||
- `d+k`: Toggle kiosk mode (hides the menu). |
||||
- `d+e`: Expand all rows. |
||||
- `d+s`: Dashboard settings. |
||||
- `Ctrl+K`: Opens the command palette. |
||||
- `Esc`: Exits panel when in fullscreen view or edit mode. Also returns you to the dashboard from dashboard settings. |
||||
|
||||
**Focused panel** |
||||
|
||||
By hovering over a panel with the mouse you can use some shortcuts that will target that panel. |
||||
|
||||
- `e`: Toggle panel edit view |
||||
- `v`: Toggle panel fullscreen view |
||||
- `ps`: Open Panel Share Modal |
||||
- `pd`: Duplicate Panel |
||||
- `pr`: Remove Panel |
||||
- `pl`: Toggle panel legend |
||||
|
||||
## Set dashboard time range |
||||
|
||||
Grafana provides several ways to manage the time ranges of the data being visualized, for dashboard, panels and also for alerting. |
||||
|
||||
This section describes supported time units and relative ranges, the common time controls, dashboard-wide time settings, and panel-specific time settings. |
||||
|
||||
### Time units and relative ranges |
||||
|
||||
Grafana supports the following time units: `s (seconds)`, `m (minutes)`, `h (hours)`, `d (days)`, `w (weeks)`, `M (months)`, `Q (quarters)` and `y (years)`. |
||||
|
||||
The minus operator enables you to step back in time, relative to now. If you want to display the full period of the unit (day, week, month, etc...), append `/<time unit>` to the end. To view fiscal periods, use `fQ (fiscal quarter)` and `fy (fiscal year)` time units. |
||||
|
||||
The plus operator enables you to step forward in time, relative to now. For example, you can use this feature to look at predicted data in the future. |
||||
|
||||
The following table provides example relative ranges: |
||||
|
||||
| Example relative range | From: | To: | |
||||
| ---------------------- | ----------- | ----------- | |
||||
| Last 5 minutes | `now-5m` | `now` | |
||||
| The day so far | `now/d` | `now` | |
||||
| This week | `now/w` | `now/w` | |
||||
| This week so far | `now/w` | `now` | |
||||
| This month | `now/M` | `now/M` | |
||||
| This month so far | `now/M` | `now` | |
||||
| Previous Month | `now-1M/M` | `now-1M/M` | |
||||
| This year so far | `now/Y` | `now` | |
||||
| This Year | `now/Y` | `now/Y` | |
||||
| Previous fiscal year | `now-1y/fy` | `now-1y/fy` | |
||||
|
||||
#### Note about Grafana Alerting |
||||
|
||||
For Grafana Alerting, we do not support the following syntaxes at this time. |
||||
|
||||
- now+n for future timestamps. |
||||
- now-1n/n for "start of n until end of n" because this is an absolute timestamp. |
||||
|
||||
### Common time range controls |
||||
|
||||
The dashboard and panel time controls have a common UI. |
||||
|
||||
<img class="no-shadow" src="/static/img/docs/time-range-controls/common-time-controls-7-0.png" max-width="700px"> |
||||
|
||||
The following sections define common time range controls. |
||||
|
||||
#### Current time range |
||||
|
||||
The current time range, also called the _time picker_, shows the time range currently displayed in the dashboard or panel you are viewing. |
||||
|
||||
Hover your cursor over the field to see the exact time stamps in the range and their source (such as the local browser). |
||||
|
||||
<img class="no-shadow" src="/static/img/docs/time-range-controls/time-picker-7-0.png" max-width="300px"> |
||||
|
||||
Click the current time range to change it. You can change the current time using a _relative time range_, such as the last 15 minutes, or an _absolute time range_, such as `2020-05-14 00:00:00 to 2020-05-15 23:59:59`. |
||||
|
||||
<img class="no-shadow" src="/static/img/docs/time-range-controls/change-current-time-range-7-0.png" max-width="900px"> |
||||
|
||||
#### Relative time range |
||||
|
||||
Select the relative time range from the **Relative time ranges** list. You can filter the list using the input field at the top. Some examples of time ranges include: |
||||
|
||||
- Last 30 minutes |
||||
- Last 12 hours |
||||
- Last 7 days |
||||
- Last 2 years |
||||
- Yesterday |
||||
- Day before yesterday |
||||
- This day last week |
||||
- Today so far |
||||
- This week so far |
||||
- This month so far |
||||
|
||||
#### Absolute time range |
||||
|
||||
You can set an absolute time range in the following ways: |
||||
|
||||
- Type values into the **From** and **To** fields. You can type exact time values or relative values, such as `now-24h`, and then click **Apply time range**. |
||||
- Click in the **From** or **To** field. Grafana displays a calendar. Click the day or days you want to use as the current time range and then click **Apply time range**. |
||||
|
||||
This section also displays recently used absolute ranges. |
||||
|
||||
#### Zoom out (Cmd+Z or Ctrl+Z) |
||||
|
||||
Click the **Zoom out** icon to view a larger time range in the dashboard or panel visualization. |
||||
|
||||
#### Zoom in (only applicable to graph visualizations) |
||||
|
||||
Click and drag to select the time range in the visualization that you want to view. |
||||
|
||||
#### Refresh dashboard |
||||
|
||||
Click the **Refresh dashboard** icon to immediately run every query on the dashboard and refresh the visualizations. Grafana cancels any pending requests when you trigger a refresh. |
||||
|
||||
By default, Grafana does not automatically refresh the dashboard. Queries run on their own schedule according to the panel settings. However, if you want to regularly refresh the dashboard, then click the down arrow next to the **Refresh dashboard** icon and then select a refresh interval. |
||||
|
||||
### Control the time range using a URL |
||||
|
||||
You can control the time range of a dashboard by providing the following query parameters in the dashboard URL: |
||||
|
||||
- `from`: Defines the lower limit of the time range, specified in `ms`, `epoch`, or [relative time]({{< relref "#relative-time-range" >}}) |
||||
- `to`: Defines the upper limit of the time range, specified in `ms`, `epoch`, or [relative time]({{< relref "#relative-time-range" >}}) |
||||
- `time` and `time.window`: Defines a time range from `time-time.window/2` to `time+time.window/2`. Both parameters should be specified in `ms`. For example `?time=1500000000000&time.window=10000` results in 10s time range from 1499999995000 to 1500000005000 |
@ -0,0 +1,71 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/working-with-panels/navigate-panel-editor/ |
||||
- /docs/grafana/latest/panels/working-with-panels/navigate-inspector-panel/ |
||||
- /docs/grafana/latest/dashboards/dashboard-create/ |
||||
- /docs/grafana/latest/features/dashboard/dashboards/ |
||||
- /docs/grafana/latest/panels/working-with-panels/add-panel/ |
||||
- /docs/grafana/latest/dashboards/add-organize-panels/ |
||||
- /docs/grafana/latest/panels/add-panels-dynamically/about-repeating-panels-rows/ |
||||
- /docs/grafana/latest/panels/add-panels-dynamically/configure-repeating-rows/ |
||||
- /docs/grafana/latest/panels/add-panels-dynamically/configure-repeating-panels/ |
||||
- /docs/grafana/next/dashboards/build-dashboards/add-organize-panels/ |
||||
- /docs/grafana/latest/panels-visualizations/add-organize-panels/ |
||||
title: Panel editor overview |
||||
menuTitle: Panel editor overview |
||||
weight: 1 |
||||
keywords: |
||||
- panel |
||||
- dashboard |
||||
- dynamic |
||||
- rows |
||||
- add |
||||
--- |
||||
|
||||
# Panel editor overview |
||||
|
||||
{{< figure src="/static/img/docs/panel-editor/panel-editor-8-0.png" class="docs-image--no-shadow" max-width="1500px" >}} |
||||
|
||||
This section describes the areas of the Grafana panel editor. |
||||
|
||||
1. Panel header: The header section lists the dashboard in which the panel appears and the following controls: |
||||
|
||||
- **Dashboard settings (gear) icon:** Click to access the dashboard settings. |
||||
- **Discard:** Discards changes you have made to the panel since you last saved the dashboard. |
||||
- **Save:** Saves changes you made to the panel. |
||||
- **Apply:** Applies changes you made and closes the panel editor, returning you to the dashboard. You will have to save the dashboard to persist the applied changes. |
||||
|
||||
1. Visualization preview: The visualization preview section contains the following options: |
||||
|
||||
- **Table view:** Convert any visualization to a table so that you can see the data. Table views are useful for troubleshooting. |
||||
- **Fill:** The visualization preview fills the available space. If you change the width of the side pane or height of the bottom pane the visualization changes to fill the available space. |
||||
- **Actual:** The visualization preview will have the exact size as the size on the dashboard. If not enough space is available, the visualization will scale down preserving the aspect ratio. |
||||
- **Time range controls:** For more information, refer to [Time range controls]({{< relref "../../dashboards/manage-dashboards/#configure-dashboard-time-range-controls" >}}). |
||||
|
||||
1. Data section: The data section contains tabs where you enter queries, transform your data, and create alert rules (if applicable). |
||||
|
||||
- **Query tab:** Select your data source and enter queries here. For more information, refer to [Add a query]({{< relref "../query-transform-data/#add-a-query" >}}). |
||||
- **Transform tab:** Apply data transformations. For more information, refer to [Transform data]({{< relref "../query-transform-data/transform-data/" >}}). |
||||
- **Alert tab:** Write alert rules. For more information, refer to [Overview of Grafana 8 alerting]({{< relref "../../alerting/" >}}). |
||||
|
||||
1. Panel display options: The display options section contains tabs where you configure almost every aspect of your data visualization. |
||||
|
||||
## Open the panel inspect drawer |
||||
|
||||
The inspect drawer helps you understand and troubleshoot your panels. You can view the raw data for any panel, export that data to a comma-separated values (CSV) file, view query requests, and export panel and data JSON. |
||||
|
||||
> **Note:** Not all panel types include all tabs. For example, dashboard list panels do not have raw data to inspect, so they do not display the Stats, Data, or Query tabs. |
||||
|
||||
The panel inspector consists of the following options: |
||||
|
||||
1. The panel inspect drawer displays opens a drawer on the right side. Click the arrow in the upper right corner to expand or reduce the drawer pane. |
||||
|
||||
1. **Data tab -** Shows the raw data returned by the query with transformations applied. Field options such as overrides and value mappings are not applied by default. |
||||
|
||||
1. **Stats tab -** Shows how long your query takes and how much it returns. |
||||
|
||||
1. **JSON tab -** Allows you to view and copy the panel JSON, panel data JSON, and data frame structure JSON. This is useful if you are provisioning or administering Grafana. |
||||
|
||||
1. **Query tab -** Shows you the requests to the server sent when Grafana queries the data source. |
||||
|
||||
1. **Error tab -** Shows the error. Only visible when query returns error. |
@ -0,0 +1,71 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/working-with-panels/navigate-inspector-panel/ |
||||
- /docs/grafana/latest/panels-visualizations/panel-inspector/ |
||||
- /docs/grafana/latest/panels/query-a-data-source/download-raw-query-results/ |
||||
- /docs/grafana/latest/panels/query-a-data-source/inspect-query-performance/ |
||||
- /docs/grafana/latest/panels/query-a-data-source/inspect-request-and-response-data/ |
||||
title: The panel inspect view |
||||
weight: 1200 |
||||
--- |
||||
|
||||
# The panel inspect view |
||||
|
||||
The panel inspect view, which you can open via the panel menu, helps you understand and troubleshoot your panels. You can inspect the raw data for any Grafana panel, export that data to a comma-separated values (CSV) file, view query requests, and export panel and data JSON. |
||||
|
||||
> **Note:** Not all panel types include all tabs. For example, dashboard list panels do not have raw data to inspect, so they do not display the Stats, Data, or Query tabs. |
||||
|
||||
The panel inspector consists of the following options: |
||||
|
||||
1. The panel inspector displays Inspect: <NameOfPanelBeingInspected> at the top of the pane. Click the arrow in the upper right corner to expand or reduce the pane. |
||||
|
||||
2. **Data tab -** Shows the raw data returned by the query with transformations applied. Field options such as overrides and value mappings are not applied by default. |
||||
|
||||
3. **Stats tab -** Shows how long your query takes and how much it returns. |
||||
|
||||
4. **JSON tab -** Allows you to view and copy the panel JSON, panel data JSON, and data frame structure JSON. This is useful if you are provisioning or administering Grafana. |
||||
|
||||
5. **Query tab -** Shows you the requests to the server sent when Grafana queries the data source. |
||||
|
||||
6. **Error tab -** Shows the error. Only visible when query returns error. |
||||
|
||||
## Download raw query results |
||||
|
||||
Grafana generates a CSV file that contains your data, including any transformations to that data. You can choose to view the data before or after the panel applies field options or field option overrides. |
||||
|
||||
1. Edit the panel that contains the query data you want to download. |
||||
1. In the query editor, click **Query Inspector**. |
||||
1. Click **Data**. |
||||
|
||||
If your panel contains multiple queries or queries multiple nodes, then you have additional options. |
||||
|
||||
- **Select result**: Choose which result set data you want to view. |
||||
- **Transform data** |
||||
- **Join by time**: View raw data from all your queries at once, one result set per column. Click a column heading to reorder the data. |
||||
|
||||
1. To see data before the system applies field overrides, click the **Formatted data** toggle. |
||||
1. To download a CSV file specifically formatted for Excel, click the **Download for Excel** toggle . |
||||
1. Click **Download CSV**. |
||||
|
||||
## Inspect query performance |
||||
|
||||
The **Stats** tab displays statistics that tell you how long your query takes, how many queries you send, and the number of rows returned. This information can help you troubleshoot your queries, especially if any of the numbers are unexpectedly high or low. |
||||
|
||||
1. Edit the panel that contains the query with performance you want to inspect. |
||||
1. In the query editor, click **Query Inspector**. |
||||
1. Click **Stats**. |
||||
|
||||
Statistics are displayed in read-only format. |
||||
|
||||
## Inspect query request and response data |
||||
|
||||
Inspect query request and response data when you want to troubleshoot a query that returns unexpected results, or fails to return expected results. |
||||
|
||||
1. Edit the panel that contains the query you want to export. |
||||
1. In the query editor, click **Query Inspector**. |
||||
1. Click **Refresh**. |
||||
|
||||
The panel populates with response data. |
||||
|
||||
1. Make adjustments, as necessary and re-run the query. |
||||
1. To download the query request and response data, click the **Copy to clipboard** icon and paste the results into another application. |
@ -0,0 +1,177 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/expressions/ |
||||
- /docs/grafana/latest/panels/inspect-panel/ |
||||
- /docs/grafana/latest/panels/queries/ |
||||
- /docs/grafana/latest/panels/query-a-data-source/ |
||||
- /docs/grafana/latest/panels/share-query-results/ |
||||
- /docs/grafana/latest/panels/query-a-data-source/about-queries/ |
||||
- /docs/grafana/latest/panels/query-a-data-source/navigate-query-tab/ |
||||
- /docs/grafana/latest/panels/query-a-data-source/add-a-query/ |
||||
- /docs/grafana/latest/panels/query-a-data-source/manage-queries/ |
||||
- /docs/grafana/latest/panels-visualizations/manage-queries/ |
||||
- /docs/grafana/latest/panels/query-options/ |
||||
- /docs/grafana/latest/panels/reference-query-options/ |
||||
- /docs/grafana/latest/panels-visualizations/query-options/ |
||||
|
||||
title: Query and transform data |
||||
weight: 200 |
||||
--- |
||||
|
||||
# Query and transform data |
||||
|
||||
Data source queries return data that can then be transformed via transformations and then visualized by different types of visualizations. The query language and query builder UI depends on the data source type. Grafana supports many different types of data sources. |
||||
|
||||
## About queries |
||||
|
||||
_Queries_ are how Grafana panels communicate with data sources to get data for the visualization. A query is a question written in the query language used by the data source. How often the query is sent to the data source and how many data points are collected can be adjusted in the panel data source options. |
||||
|
||||
Use you a query editor to write a query. Each data source has its own query editor that we have customized to include the features and capabilities of the data source. Grafana supports up to 26 queries per panel. |
||||
|
||||
> Important! You must be familiar with the query language of the data source. For more information about data sources, refer to [Data sources](../../../datasources/). |
||||
|
||||
### Query editors |
||||
|
||||
Depending on your data source, the query editor might provide auto-completion, metric names, or variable suggestions. |
||||
|
||||
Because of the difference between query languages, data sources have query editors that look different. Here are two examples of query editors. |
||||
|
||||
**InfluxDB query editor** |
||||
|
||||
{{< figure src="/static/img/docs/queries/influxdb-query-editor-7-2.png" class="docs-image--no-shadow" max-width="1000px" >}} |
||||
|
||||
**Prometheus (PromQL) query editor** |
||||
|
||||
{{< figure src="/static/img/docs/queries/prometheus-query-editor-7-4.png" class="docs-image--no-shadow" max-width="1000px" >}} |
||||
|
||||
### Query syntax |
||||
|
||||
Data sources use different query languages to return data. Here are two query examples: |
||||
|
||||
**PostgreSQL** |
||||
|
||||
``` |
||||
SELECT hostname FROM host WHERE region IN($region) |
||||
``` |
||||
|
||||
**PromQL** |
||||
|
||||
``` |
||||
query_result(max_over_time(<metric>[${__range_s}s]) != <state>) |
||||
``` |
||||
|
||||
### Data sources used in queries |
||||
|
||||
In addition to the data sources that you have configured in Grafana, there are three special data sources available: |
||||
|
||||
- **Grafana -** A built-in data source that generates random walk data, which can be useful for testing visualizations and running experiments. |
||||
- **Mixed -** Select this option to query multiple data sources in the same panel. When you select this data source, Grafana enables you to select a data source for every new query that you add. |
||||
- The first query uses the data source that was selected before you selected **Mixed**. |
||||
- You cannot change an existing query to use the Mixed Data Source. |
||||
- **Dashboard -** Select this option to use a result set from another panel in the same dashboard. |
||||
|
||||
You can combine data from multiple data sources onto a single dashboard, but each panel is tied to a specific data source that belongs to a particular Organization. |
||||
|
||||
## Navigate the query tab |
||||
|
||||
The Query tab consists of the following elements: |
||||
|
||||
- Data source selector: Use the data source selector to select the source of the data you want to query. For more information about data sources, refer to [Data sources](../../../datasources/). |
||||
- Query options: Enables you to set maximum data retrieved parameters and query execution time intervals. |
||||
- Query inspector button: Open the query inspector panel where you can view and optimize your query. |
||||
- Query editor list: Lists the queries you have written. |
||||
- Expressions: Use the expression builder to create alert expressions. For more information about expressions, refer to [Use expressions to manipulate data](../use-expressions-to-manipulate-data/). |
||||
|
||||
{{< figure src="/static/img/docs/queries/query-editor-7-2.png" class="docs-image--no-shadow" max-width="1000px" >}} |
||||
|
||||
## Add a query |
||||
|
||||
A query returns data that Grafana visualizes in dashboards. When you create a panel, Grafana automatically selects the default data source. |
||||
|
||||
**To add a query**: |
||||
|
||||
1. Edit the panel to which you are adding a query. |
||||
1. Click the **Query** tab. |
||||
1. Click the **Data source** drop-down menu and select a data source. |
||||
1. Click **Query options** to configure the maximum number of data points you need. |
||||
For more information about query options, refer to [Query options]({{< relref "#query-options" >}}). |
||||
1. Write the query using the query editor. |
||||
1. Click **Apply**. |
||||
|
||||
The system queries the data source and presents the data in the visualization. |
||||
|
||||
## Manage queries |
||||
|
||||
Queries are organized in collapsible query rows. Each query row contains a query editor and is identified with a letter (A, B, C, and so on). |
||||
|
||||
You can: |
||||
|
||||
| Icon | Description | |
||||
| :-----------------------------------------------------------------------------------------------------------------------------------------: | :--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | |
||||
| {{< figure src="/static/img/docs/queries/query-editor-help-7-4.png" class="docs-image--no-shadow" max-width="30px" max-height="30px" >}} | Toggle query editor help. If supported by the data source, click this icon to display information on how to use the query editor or provide quick access to common queries. | |
||||
| {{< figure src="/static/img/docs/queries/duplicate-query-icon-7-0.png" class="docs-image--no-shadow" max-width="30px" max-height="30px" >}} | Copy a query. Duplicating queries is useful when working with multiple complex queries that are similar and you want to either experiment with different variants or do minor alterations. | |
||||
| {{< figure src="/static/img/docs/queries/hide-query-icon-7-0.png" class="docs-image--no-shadow" max-width="30px" max-height="30px" >}} | Hide a query. Grafana does not send hidden queries to the data source. | |
||||
| {{< figure src="/static/img/docs/queries/remove-query-icon-7-0.png" class="docs-image--no-shadow" max-width="30px" max-height="30px" >}} | Remove a query. Removing a query permanently deletes it, but sometimes you can recover deleted queries by reverting to previously saved versions of the panel. | |
||||
| {{< figure src="/static/img/docs/queries/query-drag-icon-7-2.png" class="docs-image--no-shadow" max-width="30px" max-height="30px" >}} | Reorder queries. Change the order of queries by clicking and holding the drag icon, then drag queries where desired. The order of results reflects the order of the queries, so you can often adjust your visual results based on query order. | |
||||
|
||||
## Query options |
||||
|
||||
Click **Query options** next to the data source selector to see settings for your selected data source. Changes you make here affect only queries made in this panel. |
||||
|
||||
{{< figure src="/static/img/docs/queries/data-source-options-7-0.png" class="docs-image--no-shadow" max-width="1000px" >}} |
||||
|
||||
Grafana sets defaults that are shown in dark gray text. Changes are displayed in white text. To return a field to the default setting, delete the white text from the field. |
||||
|
||||
Panel data source query options: |
||||
|
||||
- **Max data points -** If the data source supports it, sets the maximum numbers of data points for each series returned. If the query returns more data points than the max data points setting, then the data source consolidates them (reduces the number of points returned by aggregating them together by average or max or other function). |
||||
|
||||
There are two main reasons for limiting the number of points, performance and smoothing the line. The default value is the width (or number of pixels) of the graph as there is no point in having more data points than the graph panel can display. |
||||
|
||||
With streaming data, the max data points value is used for the rolling buffer. (Streaming is a continuous flow of data and buffering is a way of dividing the stream into chunks). Loki streams data in the live tailing mode. |
||||
|
||||
- **Min interval -** Sets a minimum limit for the automatically calculated interval, typically the minimum scrape interval. If a data point is saved every 15 seconds, then there's no point in having an interval lower than that. Another use case is to set it to a higher minimum than the scrape interval to get more coarse-grained, well-functioning queries. |
||||
|
||||
- **Interval -** The interval is a time span that you can use when aggregating or grouping data points by time. |
||||
|
||||
Grafana automatically calculates an appropriate interval and it can be used as a variable in templated queries. The variable is either in seconds: `$__interval` or in milliseconds: `$__interval_ms`. It is typically used in aggregation functions like sum or average. For example, a Prometheus query using the interval variable: `rate(http_requests_total[$__interval])`. |
||||
|
||||
This automatic interval is calculated based on the width of the graph. If the user zooms out a lot then the interval becomes greater, resulting in a more coarse grained aggregation whereas if the user zooms in then the interval decreases resulting in a more fine grained aggregation. |
||||
|
||||
For more information, refer to [Global variables]({{< relref "../../dashboards/variables/add-template-variables/#global-variables" >}}). |
||||
|
||||
- **Relative time -** You can override the relative time range for individual panels, causing them to be different than what is selected in the dashboard time picker in the top right corner of the dashboard. This allows you to show metrics from different time periods or days on the same dashboard. |
||||
|
||||
- **Time shift -** The time shift function is another way to override the time range for individual panels. It only works with relative time ranges and allows you to adjust the time range. |
||||
|
||||
For example, you could shift the time range for the panel to be two hours earlier than the dashboard time picker. For more information, refer to [Time range controls]({{< relref "../../dashboards/manage-dashboards/#configure-dashboard-time-range-controls" >}}). |
||||
|
||||
- **Cache timeout -** (This field is only visible if available in your data source.) If your time series store has a query cache, then this option can override the default cache timeout. Specified as a numeric value in seconds. |
||||
|
||||
### Examples |
||||
|
||||
- **Relative time:** |
||||
|
||||
| Example | Relative time field | |
||||
| ---------------- | ------------------- | |
||||
| Last 5 minutes | `now-5m` | |
||||
| The day so far | `now/d` | |
||||
| Last 5 days | `now-5d/d` | |
||||
| This week so far | `now/w` | |
||||
| Last 2 years | `now-2y/y` | |
||||
|
||||
- **Time shift:** |
||||
|
||||
| Example | Time shift field | |
||||
| -------------------- | ---------------- | |
||||
| Last entire week | `1w/w` | |
||||
| Two entire weeks ago | `2w/w` | |
||||
| Last entire month | `1M/M` | |
||||
| This entire year | `1d/y` | |
||||
| Last entire year | `1y/y` | |
||||
|
||||
### Panel time overrides and timeshift |
||||
|
||||
In [Query options]({{< relref "#query-options" >}}), you can override the relative time range for individual panels, which causes them to be different than what is selected in the dashboard time picker located in the upper right. This enables you to show metrics from different time periods or days at the same time. |
||||
|
||||
> **Note:** Panel time overrides have no effect when the time range for the dashboard is absolute. |
@ -0,0 +1,435 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/features/panels/geomap/ |
||||
- /docs/grafana/latest/panels/visualizations/geomap/ |
||||
- /docs/grafana/latest/visualizations/geomap/ |
||||
- /docs/grafana/latest/features/panels/geomap/arcgis/ |
||||
- /docs/grafana/latest/panels/visualizations/geomap/arcgis/ |
||||
- /docs/grafana/latest/features/panels/geomap/carto/ |
||||
- /docs/grafana/latest/panels/visualizations/geomap/carto/ |
||||
- /docs/grafana/latest/features/panels/geomap/controls/ |
||||
- /docs/grafana/latest/panels/visualizations/geomap/controls/ |
||||
- /docs/grafana/latest/features/panels/geomap/daynight/ |
||||
- /docs/grafana/latest/panels/visualizations/geomap/daynight/ |
||||
- /docs/grafana/latest/features/panels/geomap/geojson/ |
||||
- /docs/grafana/latest/panels/visualizations/geomap/geojson/ |
||||
- /docs/grafana/latest/features/panels/geomap/heatmap/ |
||||
- /docs/grafana/latest/panels/visualizations/geomap/heatmap/ |
||||
- /docs/grafana/latest/features/panels/geomap/markers/ |
||||
- /docs/grafana/latest/panels/visualizations/geomap/markers/ |
||||
- /docs/grafana/latest/features/panels/geomap/osm/ |
||||
- /docs/grafana/latest/panels/visualizations/geomap/osm/ |
||||
- /docs/grafana/latest/features/panels/geomap/zyx/ |
||||
- /docs/grafana/latest/panels/visualizations/geomap/zyx/ |
||||
- /docs/grafana/latest/panels-visualizations/visualizations/geomap/ |
||||
description: Geomap visualization documentation |
||||
keywords: |
||||
- grafana |
||||
- Geomap |
||||
- panel |
||||
- documentation |
||||
title: Geomap |
||||
weight: 600 |
||||
--- |
||||
|
||||
# Geomap |
||||
|
||||
The Geomap panel visualization allows you to view and customize the world map using geospatial data. You can configure various overlay styles and map view settings to easily focus on the important location-based characteristics of the data. |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-example-8-1-0.png" max-width="1200px" caption="Geomap panel" >}} |
||||
|
||||
## Map View |
||||
|
||||
The map view controls the initial view of the map when the dashboard loads. |
||||
|
||||
### Initial View |
||||
|
||||
The initial view configures how the GeoMap panel renders when the panel is first loaded. |
||||
|
||||
- **View** sets the center for the map when the panel first loads. |
||||
- **Fit to data** fits the map view based on the data extents of Map layers and updates when data changes. |
||||
- **Data** option allows selection of extent based on data from "All layers", a single "Layer", or the "Last value" from a selected layer. |
||||
- **Layer** can be selected if fitting data from a single "Layer" or the "Last value" of a layer. |
||||
- **Padding** sets padding in relative percent beyond data extent (not available when looking at "Last value" only). |
||||
- **Max Zoom** sets the maximum zoom level when fitting data. |
||||
- **Coordinates** sets the map view based on: |
||||
- **Latitude** |
||||
- **Longitude** |
||||
- Default Views are also available including: |
||||
- **(0°, 0°)** |
||||
- **North America** |
||||
- **South America** |
||||
- **Europe** |
||||
- **Africa** |
||||
- **West Asia** |
||||
- **South Asia** |
||||
- **South-East Asia** |
||||
- **East Asia** |
||||
- **Australia** |
||||
- **Oceania** |
||||
- **Zoom** sets the initial zoom level. |
||||
|
||||
## Map layers |
||||
|
||||
The Geomap visualization supports showing multiple layers. Each layer determines how you visualize geospatial data on top of the base map. |
||||
|
||||
### Types |
||||
|
||||
There are three map layer types to choose from in the Geomap visualization. |
||||
|
||||
- [Markers]({{< relref "#markers-layer" >}}) renders a marker at each data point. |
||||
- [Heatmap]({{< relref "#heatmap-layer" >}}) visualizes a heatmap of the data. |
||||
- [GeoJSON]({{< relref "#geojson-layer" >}}) renders static data from a GeoJSON file. |
||||
|
||||
There are also four alpha layer types. |
||||
|
||||
- [Night / Day (alpha)]({{< relref "#night--day-layer-alpha" >}}) renders a night / day region. |
||||
- **Icon at last point (alpha)** renders an icon at the last data point. |
||||
- **Dynamic GeoJSON (alpha)** styles a GeoJSON file based on query results. |
||||
- **Route (alpha)** render data points as a route. |
||||
|
||||
> **Note:** [Basemap layer types]({{< relref "#types-1" >}}) can also be added as layers. You can specify an opacity. |
||||
|
||||
### Layer Controls |
||||
|
||||
The layer controls allow you to create layers, change their name, reorder and delete layers. |
||||
|
||||
- **Add layer** creates an additional, configurable data layer for the Geomap visualization. When you add a layer, you are prompted to select a layer type. You can change the layer type at any point during panel configuration. See the **Layer Types** section above for details on each layer type. |
||||
- The layer controls allow you to rename, delete, and reorder the layers of the panel. |
||||
- **Edit layer name (pencil icon)** renames the layer. |
||||
- **Trash Bin** deletes the layer. |
||||
- **Reorder (six dots/grab handle)** allows you to change the layer order. Data on higher layers will appear above data on lower layers. The panel will update the layer order as you drag and drop to help simplify choosing a layer order. |
||||
|
||||
You can add multiple layers of data to a single Geomap panel in order to create rich, detailed visualizations. |
||||
|
||||
### Location |
||||
|
||||
The Geomap panel needs a source of geographical data. This data comes from a database query, and there are four mapping options for your data. |
||||
|
||||
- **Auto** automatically searches for location data. Use this option when your query is based on one of the following names for data fields. |
||||
- geohash: “geohash” |
||||
- latitude: “latitude”, “lat” |
||||
- longitude: “longitude”, “lng”, “lon” |
||||
- lookup: “lookup” |
||||
- **Coords** specifies that your query holds coordinate data. You will get prompted to select numeric data fields for latitude and longitude from your database query. |
||||
- **Geohash** specifies that your query holds geohash data. You will be prompted to select a string data field for the geohash from your database query. |
||||
- **Lookup** specifies that your query holds location name data that needs to be mapped to a value. You will be prompted to select the lookup field from your database query and a gazetteer. The gazetteer is the directory that is used to map your queried data to a geographical point. |
||||
|
||||
## Basemap layer |
||||
|
||||
A basemap layer provides the visual foundation for a mapping application. It typically contains data with global coverage. Several base layer options |
||||
are available each with specific configuration options to style the base map. |
||||
|
||||
### Types |
||||
|
||||
There are four basemap layer types to choose from in the Geomap visualization. |
||||
|
||||
- [Open Street Map]({{< relref "#open-street-map-layer" >}}) adds a map from a collaborative free geographic world database. |
||||
- [CARTO]({{< relref "#carto-layer" >}}) adds a layer from CARTO Raster basemaps. |
||||
- [ArcGIS]({{< relref "#arcgis-layer" >}}) adds a layer from an ESRI ArcGIS MapServer. |
||||
- [XYZ]({{< relref "#xyz-tile-layer" >}}) adds a map from a generic tile layer. |
||||
|
||||
### Default |
||||
|
||||
The default base layer uses the [CARTO]({{< relref "#carto-layer" >}}) map. You can define custom default base layers in the `.ini` configuration file. |
||||
|
||||
 |
||||
|
||||
#### Configure the default base layer with provisioning |
||||
|
||||
You can configure the default base map using config files with Grafana’s provisioning system. For more information on all the settings, refer to the [provisioning docs page]({{< relref "../../../administration/provisioning/" >}}). |
||||
|
||||
Use the JSON configuration option `default_baselayer_config` to define the default base map. There are currently four base map options to choose from: `carto`, `esri-xyz`, `osm-standard`, `xyz`. Here are some provisioning examples for each base map option. |
||||
|
||||
- **carto** loads the CartoDB tile server. You can choose from `auto`, `dark`, and `light` theme for the base map and can be set as shown below. The `showLabels` tag determines whether or not Grafana shows the Country details on top of the map. Here is an example: |
||||
|
||||
```ini |
||||
geomap_default_baselayer = `{ |
||||
"type": "carto", |
||||
"config": { |
||||
"theme": "auto", |
||||
"showLabels": true |
||||
} |
||||
}` |
||||
``` |
||||
|
||||
- **esri-xyz** loads the ESRI tile server. There are already multiple server instances implemented to show the various map styles: `world-imagery`, `world-physical`, `topo`, `usa-topo`, and `ocean`. The `custom` server option allows you to configure your own ArcGIS map server. Here are some examples: |
||||
|
||||
```ini |
||||
geomap_default_baselayer = `{ |
||||
"type": "esri-xyz", |
||||
"config": { |
||||
"server": "world-imagery" |
||||
} |
||||
}` |
||||
``` |
||||
|
||||
```ini |
||||
geomap_default_baselayer = `{ |
||||
"type": "esri-xyz", |
||||
"config": { |
||||
"server": "custom", |
||||
"url": "[tile server url]", |
||||
"attribution": "[tile server attribution]" |
||||
} |
||||
}` |
||||
``` |
||||
|
||||
- **osm-standard** loads the OpenStreetMap tile server. There are no additional configurations needed and the `config` fields can be left blank. Here is an example: |
||||
|
||||
```ini |
||||
default_baselayer_config = `{ |
||||
"type": "osm-standard", |
||||
"config": {} |
||||
}` |
||||
``` |
||||
|
||||
- **xyz** loads a custom tile server defined by the user. Set a valid tile server `url`, with {z}/{x}/{y} for this option in order to properly load a default base map. Here is an example: |
||||
|
||||
```ini |
||||
default_baselayer_config = `{ |
||||
"type": "xyz", |
||||
"config": { |
||||
"attribution": "Open street map", |
||||
"url": "https://tile.openstreetmap.org/{z}/{x}/{y}.png" |
||||
} |
||||
}` |
||||
``` |
||||
|
||||
`enable_custom_baselayers` allows you to enable or disable custom open source base maps that are already implemented. The default is `true`. |
||||
|
||||
## Markers layer |
||||
|
||||
The markers layer allows you to display data points as different marker shapes such as circles, squares, triangles, stars, and more. |
||||
|
||||
 |
||||
|
||||
 |
||||
|
||||
- **Marker Color** configures the color of the marker. The default `Single color` keeps all points a single color. There is an alternate option to have multiple colors depending on the data point values and the threshold set at the `Thresholds` section. |
||||
- **Marker Size** configures the size of the marker. The default is `Fixed size`, which makes all marker sizes the same regardless of the data points. However, there is also an option to scale the circles to the corresponding data points. `Min` and `Max` marker size has to be set such that the Marker layer can scale within this range. |
||||
- **Marker Shape** allows you to choose the shape, icon, or graphic to aid in providing additional visual context to your data. Choose from assets that are included with Grafana such as simple shapes or the Unicon library. You can also specify a URL containing an image asset. The image must be a scalable vector graphic (SVG). |
||||
- **Fill opacity** configures the transparency of each marker. |
||||
|
||||
## Heatmap layer |
||||
|
||||
The heatmap layer clusters various data points to visualize locations with different densities. |
||||
To add a heatmap layer: |
||||
|
||||
Click on the drop-down menu under Data Layer and choose `Heatmap`. |
||||
|
||||
Similar to `Markers`, you are prompted with various options to determine which data points to visualize and how you want to visualize them. |
||||
|
||||
 |
||||
|
||||
 |
||||
|
||||
- **Weight values** configure the intensity of the heatmap clusters. `Fixed value` keeps a constant weight value throughout all data points. This value should be in the range of 0~1. Similar to Markers, there is an alternate option in the drop-down to automatically scale the weight values depending on data values. |
||||
- **Radius** configures the size of the heatmap clusters. |
||||
- **Blur** configures the amount of blur on each cluster. |
||||
|
||||
## GeoJSON layer |
||||
|
||||
The GeoJSON layer allows you to select and load a static GeoJSON file from the filesystem. |
||||
|
||||
- **GeoJSON URL** provides a choice of GeoJSON files that ship with Grafana. |
||||
- **Default Style** controls which styles to apply when no rules above match. |
||||
- **Color** configures the color of the default style |
||||
- **Opacity** configures the default opacity |
||||
- **Style Rules** apply styles based on feature properties |
||||
- **Rule** allows you to select a _feature_, _condition_, and _value_ from the GeoJSON file in order to define a rule. The trash bin icon can be used to delete the current rule. |
||||
- **Color** configures the color of the style for the current rule |
||||
- **Opacity** configures the transparency level for the current rule |
||||
- **Add style rule** creates additional style rules. |
||||
|
||||
## CARTO layer |
||||
|
||||
A CARTO layer is from CARTO Raster basemaps. |
||||
|
||||
### Options |
||||
|
||||
- **Theme** |
||||
- Auto |
||||
- Light |
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-carto-light-9-1-0.png" max-width="1200px" caption="Geomap panel CARTO light example" >}} |
||||
- Dark |
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-carto-dark-9-1-0.png" max-width="1200px" caption="Geomap panel CARTO dark example" >}} |
||||
- **Show labels** shows the Country details on top of the map. |
||||
- **Opacity** from 0 (transparent) to 1 (opaque) |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-carto-options-9-1-0.png" max-width="1200px" caption="Geomap panel CARTO options" >}} |
||||
|
||||
### More Information |
||||
|
||||
- [**About CARTO**](https://carto.com/about-us/) |
||||
|
||||
## XYZ tile layer |
||||
|
||||
The XYZ tile layer is a map from a generic tile layer. |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-xyz-9-1-0.png" max-width="1200px" caption="Geomap panel xyz example" >}} |
||||
|
||||
### Options |
||||
|
||||
- **URL template** |
||||
|
||||
> **Note:** Set a valid tile server url, with {z}/{x}/{y} for example: https://tile.openstreetmap.org/{z}/{x}/{y}.png |
||||
|
||||
- **Attribution** sets the reference string for the layer if displayed in [map controls]({{< relref "#show-attribution" >}}) |
||||
- **Opacity** from 0 (transparent) to 1 (opaque) |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-xyz-options-9-1-0.png" max-width="1200px" caption="Geomap panel xyz options" >}} |
||||
|
||||
### More information |
||||
|
||||
- [**Tiled Web Map Wikipedia**](https://en.wikipedia.org/wiki/Tiled_web_map) |
||||
- [**List of Open Street Map Tile Servers**](https://wiki.openstreetmap.org/wiki/Tile_servers) |
||||
|
||||
## Open Street Map layer |
||||
|
||||
A map from a collaborative free geographic world database. |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-osm-9-1-0.png" max-width="1200px" caption="Geomap panel Open Street Map" >}} |
||||
|
||||
### Options |
||||
|
||||
- **Opacity** from 0 (transparent) to 1 (opaque) |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-osm-options-9-1-0.png" max-width="1200px" caption="Geomap panel Open Street Map options" >}} |
||||
|
||||
### More Information |
||||
|
||||
- [**About Open Street Map**](https://www.openstreetmap.org/about)\ |
||||
|
||||
## ArcGIS layer |
||||
|
||||
An ArcGIS layer is a layer from an ESRI ArcGIS MapServer. |
||||
|
||||
### Options |
||||
|
||||
- **Server Instance** to select the map type. |
||||
- World Street Map |
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-arcgis-wsm-9-1-0.png" max-width="1200px" caption="Geomap panel ArcGIS World Street Map" >}} |
||||
- World Imagery |
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-arcgis-wi-9-1-0.png" max-width="1200px" caption="Geomap panel ArcGIS World Imagery" >}} |
||||
- World Physical |
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-arcgis-wp-9-1-0.png" max-width="1200px" caption="Geomap panel ArcGIS World Physical" >}} |
||||
- Topographic |
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-arcgis-topographic-9-1-0.png" max-width="1200px" caption="Geomap panel ArcGIS Topographic" >}} |
||||
- USA Topographic |
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-arcgis-usa-topographic-9-1-0.png" max-width="1200px" caption="Geomap panel ArcGIS USA Topographic" >}} |
||||
- World Ocean |
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-arcgis-ocean-9-1-0.png" max-width="1200px" caption="Geomap panel ArcGIS World Ocean" >}} |
||||
- Custom MapServer (see [XYZ]({{< relref "#xyz-tile-layer" >}}) for formatting) |
||||
- URL template |
||||
- Attribution |
||||
- **Opacity** from 0 (transparent) to 1 (opaque) |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-arcgis-options-9-1-0.png" max-width="1200px" caption="Geomap panel ArcGIS options" >}} |
||||
|
||||
### More Information |
||||
|
||||
- [**ArcGIS Services**](https://services.arcgisonline.com/arcgis/rest/services) |
||||
- [**About ESRI**](https://www.esri.com/en-us/about/about-esri/overview) |
||||
|
||||
## Night / Day layer (Alpha) |
||||
|
||||
The Night / Day layer displays night and day regions based on the current time range. |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-day-night-9-1-0.png" max-width="1200px" caption="Geomap panel Night / Day" >}} |
||||
|
||||
### Options |
||||
|
||||
- **Show** toggles time source from panel time range |
||||
- **Night region color** picks color for night region |
||||
- **Display sun** toggles sun icon |
||||
- **Opacity** from 0 (transparent) to 1 (opaque) |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-day-night-options-9-1-0.png" max-width="1200px" caption="Geomap panel Night / Day options" >}} |
||||
|
||||
### More information |
||||
|
||||
- [**Extensions for OpenLayers - DayNight**](https://viglino.github.io/ol-ext/examples/layer/map.daynight.html) |
||||
|
||||
## Map Controls |
||||
|
||||
The map controls section contains various options for map information and tool overlays. |
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-map-controls-9-1-0.png" max-width="1200px" caption="Geomap panel map controls" >}} |
||||
|
||||
### Zoom |
||||
|
||||
This section describes each of the zoom controls. |
||||
|
||||
#### Show zoom control |
||||
|
||||
Displays zoom controls in the upper left corner. This control can be useful when using systems that don't have a mouse. |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-map-controls-zoom-9-1-0.png" max-width="1200px" caption="Geomap panel zoom" >}} |
||||
|
||||
#### Mouse wheel zoom |
||||
|
||||
Enables the mouse wheel to be used for zooming in or out. |
||||
|
||||
### Show attribution |
||||
|
||||
Displays attribution for basemap layers. |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-map-controls-attribution-9-1-0.png" max-width="1200px" caption="Geomap panel attribution" >}} |
||||
|
||||
### Show scale |
||||
|
||||
Displays scale information in the bottom left corner. |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-map-controls-scale-9-1-0.png" max-width="1200px" caption="Geomap panel scale" >}} |
||||
|
||||
> **Note:** Currently only displays units in [m]/[km]. |
||||
|
||||
### Show measure tools |
||||
|
||||
Displays measure tools in the upper right corner. Measurements appear only when this control is open. |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-map-controls-measure-9-1-0.png" max-width="1200px" caption="Geomap panel measure" >}} |
||||
|
||||
- **Click** to start measuring |
||||
- **Continue clicking** to continue measurement |
||||
- **Double-click** to end measurement |
||||
|
||||
> **Note:** <br /> - When you change measurement type or units, the previous measurement is removed from the map. <br /> - If the control is closed and then re-opened, the most recent measurement is displayed. <br /> - A measurement can be modified by clicking and dragging on it. |
||||
|
||||
#### Length |
||||
|
||||
Get the spherical length of a geometry. This length is the sum of the great circle distances between coordinates. For multi-part geometries, the length is the sum of the length of each part. Geometries are assumed to be in 'EPSG:3857'. |
||||
|
||||
- **Metric (m/km)** |
||||
- **Feet (ft)** |
||||
- **Miles (mi)** |
||||
- **Nautical miles (nmi)** |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-map-controls-measure-length-9-1-0.png" max-width="1200px" caption="Geomap panel measure length" >}} |
||||
|
||||
#### Area |
||||
|
||||
Get the spherical area of a geometry. This area is calculated assuming that polygon edges are segments of great circles on a sphere. Geometries are assumed to be in 'EPSG:3857'. |
||||
|
||||
- **Square Meters (m²)** |
||||
- **Square Kilometers (km²)** |
||||
- **Square Feet (ft²)** |
||||
- **Square Miles (mi²)** |
||||
- **Acres (acre)** |
||||
- **Hectare (ha)** |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-map-controls-measure-area-9-1-0.png" max-width="1200px" caption="Geomap panel measure area" >}} |
||||
|
||||
### Show debug |
||||
|
||||
Displays debug information in the upper right corner. This can be useful for debugging or validating a data source. |
||||
|
||||
- **Zoom** displays current zoom level of the map. |
||||
- **Center** displays the current **longitude**, **latitude** of the map center. |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-map-controls-debug-9-1-0.png" max-width="1200px" caption="Geomap panel debug" >}} |
||||
|
||||
### Tooltip |
||||
|
||||
- **None** displays tooltips only when a data point is clicked. |
||||
- **Details** displays tooltips when a mouse pointer hovers over a data point. |
@ -1,17 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/expressions/ |
||||
- /docs/grafana/latest/panels/inspect-panel/ |
||||
- /docs/grafana/latest/panels/queries/ |
||||
- /docs/grafana/latest/panels/query-a-data-source/ |
||||
- /docs/grafana/latest/panels/share-query-results/ |
||||
- /docs/sources/panels/query-a-data-source/_index/ |
||||
title: Query a data source |
||||
weight: 200 |
||||
--- |
||||
|
||||
# Query a data source |
||||
|
||||
Data source queries return data that appear in visualizations. The query language in which you write depends on the data source you query. Grafana supports connections with many types of data sources. |
||||
|
||||
{{< section >}} |
@ -1,57 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/query-a-data-source/about-queries/ |
||||
- /docs/sources/panels/query-a-data-source/about-queries/ |
||||
title: About queries |
||||
weight: 10 |
||||
--- |
||||
|
||||
# About queries |
||||
|
||||
_Queries_ are how Grafana panels communicate with data sources to get data for the visualization. A query is a question written in the query language used by the data source. How often the query is sent to the data source and how many data points are collected can be adjusted in the panel data source options. |
||||
|
||||
Use you a query editor to write a query. Each data source has its own query editor that we have customized to include the features and capabilities of the data source. Grafana supports up to 26 queries per panel. |
||||
|
||||
> Important! You must be familiar with the query language of the data source. For more information about data sources, refer to [Data sources](../../../datasources/). |
||||
|
||||
## Query editors |
||||
|
||||
Depending on your data source, the query editor might provide auto-completion, metric names, or variable suggestions. |
||||
|
||||
Because of the difference between query languages, data sources have query editors that look different. Here are two examples of query editors. |
||||
|
||||
**InfluxDB query editor** |
||||
|
||||
{{< figure src="/static/img/docs/queries/influxdb-query-editor-7-2.png" class="docs-image--no-shadow" max-width="1000px" >}} |
||||
|
||||
**Prometheus (PromQL) query editor** |
||||
|
||||
{{< figure src="/static/img/docs/queries/prometheus-query-editor-7-4.png" class="docs-image--no-shadow" max-width="1000px" >}} |
||||
|
||||
## Query syntax |
||||
|
||||
Data sources use different query languages to return data. Here are two query examples: |
||||
|
||||
**PostgreSQL** |
||||
|
||||
``` |
||||
SELECT hostname FROM host WHERE region IN($region) |
||||
``` |
||||
|
||||
**PromQL** |
||||
|
||||
``` |
||||
query_result(max_over_time(<metric>[${__range_s}s]) != <state>) |
||||
``` |
||||
|
||||
## Data sources used in queries |
||||
|
||||
In addition to the data sources that you have configured in Grafana, there are three special data sources available: |
||||
|
||||
- **Grafana -** A built-in data source that generates random walk data, which can be useful for testing visualizations and running experiments. |
||||
- **Mixed -** Select this option to query multiple data sources in the same panel. When you select this data source, Grafana enables you to select a data source for every new query that you add. |
||||
- The first query uses the data source that was selected before you selected **Mixed**. |
||||
- You cannot change an existing query to use the Mixed Data Source. |
||||
- **Dashboard -** Select this option to use a result set from another panel in the same dashboard. |
||||
|
||||
You can combine data from multiple data sources onto a single dashboard, but each panel is tied to a specific data source that belongs to a particular Organization. |
@ -1,30 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/query-a-data-source/add-a-query/ |
||||
- /docs/sources/panels/query-a-data-source/add-a-query/ |
||||
title: Add a query |
||||
weight: 30 |
||||
--- |
||||
|
||||
# Add a query |
||||
|
||||
A query returns data that Grafana visualizes in dashboards. When you create a panel, Grafana automatically selects the default data source. |
||||
|
||||
## Before you begin |
||||
|
||||
- [Add a data source](../../../datasources/add-a-data-source). |
||||
- Ensure that you know the query language of the data source. |
||||
|
||||
**To add a query**: |
||||
|
||||
1. Edit the panel to which you are adding a query. |
||||
1. Click the **Query** tab. |
||||
1. Click the **Data source** drop-down menu and select a data source. |
||||
1. Click **Query options** to configure the maximum number of data points returned by the query and how frequently you want the query to request data from the data source. |
||||
|
||||
For more information about query options, refer to [Query options]({{< relref "../query-options/" >}}). |
||||
|
||||
1. Write the query. |
||||
1. Click **Apply**. |
||||
|
||||
The system queries the data source and presents the data in the visualization. |
@ -1,25 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/query-a-data-source/download-raw-query-results/ |
||||
- /docs/sources/panels/query-a-data-source/download-raw-query-results/ |
||||
title: Download raw query results |
||||
weight: 70 |
||||
--- |
||||
|
||||
# Download raw query results |
||||
|
||||
Grafana generates a CSV file that contains your data, including any transformations to that data. You can choose to view the data before or after the panel applies field options or field option overrides. |
||||
|
||||
1. Edit the panel that contains the query data you want to download. |
||||
1. In the query editor, click **Query Inspector**. |
||||
1. Click **Data**. |
||||
|
||||
If your panel contains multiple queries or queries multiple nodes, then you have additional options. |
||||
|
||||
- **Select result**: Choose which result set data you want to view. |
||||
- **Transform data** |
||||
- **Join by time**: View raw data from all your queries at once, one result set per column. Click a column heading to reorder the data. |
||||
|
||||
1. To see data before the system applies field overrides, click the **Formatted data** toggle. |
||||
1. To download a CSV file specifically formatted for Excel, click the **Download for Excel** toggle . |
||||
1. Click **Download CSV**. |
@ -1,17 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/query-a-data-source/inspect-query-performance/ |
||||
- /docs/sources/panels/query-a-data-source/inspect-query-performance/ |
||||
title: Inspect query performance |
||||
weight: 80 |
||||
--- |
||||
|
||||
# Inspect query performance |
||||
|
||||
The **Stats** tab displays statistics that tell you how long your query takes, how many queries you send, and the number of rows returned. This information can help you troubleshoot your queries, especially if any of the numbers are unexpectedly high or low. |
||||
|
||||
1. Edit the panel that contains the query with performance you want to inspect. |
||||
1. In the query editor, click **Query Inspector**. |
||||
1. Click **Stats**. |
||||
|
||||
Statistics are displayed in read-only format. |
@ -1,20 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/query-a-data-source/inspect-request-and-response-data/ |
||||
- /docs/sources/panels/query-a-data-source/inspect-request-and-response-data/ |
||||
title: Inspect query request and response data |
||||
weight: 90 |
||||
--- |
||||
|
||||
# Inspect query request and response data |
||||
|
||||
Inspect query request and response data when you want to troubleshoot a query that returns unexpected results, or fails to return expected results. |
||||
|
||||
1. Edit the panel that contains the query you want to export. |
||||
1. In the query editor, click **Query Inspector**. |
||||
1. Click **Refresh**. |
||||
|
||||
The panel populates with response data. |
||||
|
||||
1. Make adjustments, as necessary and re-run the query. |
||||
1. To download the query request and response data, click the **Copy to clipboard** icon and paste the results into another application. |
@ -1,21 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/query-a-data-source/manage-queries/ |
||||
- /docs/sources/panels/query-a-data-source/manage-queries/ |
||||
title: Manage queries |
||||
weight: 50 |
||||
--- |
||||
|
||||
# Manage queries |
||||
|
||||
Queries are organized in collapsible query rows. Each query row contains a query editor and is identified with a letter (A, B, C, and so on). |
||||
|
||||
You can: |
||||
|
||||
| Icon | Description | |
||||
| :-----------------------------------------------------------------------------------------------------------------------------------------: | :--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | |
||||
| {{< figure src="/static/img/docs/queries/query-editor-help-7-4.png" class="docs-image--no-shadow" max-width="30px" max-height="30px" >}} | Toggle query editor help. If supported by the data source, click this icon to display information on how to use the query editor or provide quick access to common queries. | |
||||
| {{< figure src="/static/img/docs/queries/duplicate-query-icon-7-0.png" class="docs-image--no-shadow" max-width="30px" max-height="30px" >}} | Copy a query. Duplicating queries is useful when working with multiple complex queries that are similar and you want to either experiment with different variants or do minor alterations. | |
||||
| {{< figure src="/static/img/docs/queries/hide-query-icon-7-0.png" class="docs-image--no-shadow" max-width="30px" max-height="30px" >}} | Hide a query. Grafana does not send hidden queries to the data source. | |
||||
| {{< figure src="/static/img/docs/queries/remove-query-icon-7-0.png" class="docs-image--no-shadow" max-width="30px" max-height="30px" >}} | Remove a query. Removing a query permanently deletes it, but sometimes you can recover deleted queries by reverting to previously saved versions of the panel. | |
||||
| {{< figure src="/static/img/docs/queries/query-drag-icon-7-2.png" class="docs-image--no-shadow" max-width="30px" max-height="30px" >}} | Reorder queries. Change the order of queries by clicking and holding the drag icon, then drag queries where desired. The order of results reflects the order of the queries, so you can often adjust your visual results based on query order. | |
@ -1,19 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/query-a-data-source/navigate-query-tab/ |
||||
- /docs/sources/panels/query-a-data-source/navigate-query-tab/ |
||||
title: Navigate the query tab |
||||
weight: 20 |
||||
--- |
||||
|
||||
# Navigate the query tab |
||||
|
||||
The Query tab consists of the following elements: |
||||
|
||||
- Data source selector: Use the data source selector to select the source of the data you want to query. For more information about data sources, refer to [Data sources](../../../datasources/). |
||||
- Query options: Enables you to set maximum data retrieved parameters and query execution time intervals. |
||||
- Query inspector button: Open the query inspector panel where you can view and optimize your query. |
||||
- Query editor list: Lists the queries you have written. |
||||
- Expressions: Use the expression builder to create alert expressions. For more information about expressions, refer to [Use expressions to manipulate data](../use-expressions-to-manipulate-data/). |
||||
|
||||
{{< figure src="/static/img/docs/queries/query-editor-7-2.png" class="docs-image--no-shadow" max-width="1000px" >}} |
@ -1,13 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/query-a-data-source/use-expressions-to-manipulate-data/ |
||||
- /docs/sources/panels/query-a-data-source/use-expressions-to-manipulate-data/ |
||||
title: Use expressions to manipulate data |
||||
weight: 40 |
||||
--- |
||||
|
||||
# Use expressions to manipulate data |
||||
|
||||
Server-side expressions enable you to manipulate data returned from queries with math and other operations. Expressions create new data and do not manipulate the data returned by data sources. |
||||
|
||||
{{< section >}} |
@ -1,22 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/query-a-data-source/use-expressions-to-manipulate-data/write-an-expression/ |
||||
- /docs/sources/panels/query-a-data-source/use-expressions-to-manipulate-data/write-an-expression/ |
||||
title: Write an expression |
||||
weight: 20 |
||||
--- |
||||
|
||||
# Write an expression |
||||
|
||||
If your data source supports them, then Grafana displays the **Expression** button and shows any existing expressions in the query editor list. |
||||
|
||||
For more information about expressions, refer to [About expressions]({{< relref "about-expressions/" >}}). |
||||
|
||||
1. Open the panel. |
||||
1. Below the query, click **Expression**. |
||||
1. In the **Operation** field, select the type of expression you want to write. |
||||
|
||||
For more information about expression operations, refer to [About expressions]({{< relref "about-expressions/" >}}). |
||||
|
||||
1. Write the expression. |
||||
1. Click **Apply**. |
@ -1,64 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/query-options/ |
||||
- /docs/grafana/latest/panels/reference-query-options/ |
||||
- /docs/sources/panels/reference-query-options/ |
||||
title: Query options |
||||
weight: 900 |
||||
--- |
||||
|
||||
# Reference: Query options |
||||
|
||||
Click **Query options** next to the data source selector to see settings for your selected data source. Changes you make here affect only queries made in this panel. |
||||
|
||||
{{< figure src="/static/img/docs/queries/data-source-options-7-0.png" class="docs-image--no-shadow" max-width="1000px" >}} |
||||
|
||||
Grafana sets defaults that are shown in dark gray text. Changes are displayed in white text. To return a field to the default setting, delete the white text from the field. |
||||
|
||||
Panel data source query options: |
||||
|
||||
- **Max data points -** If the data source supports it, sets the maximum numbers of data points for each series returned. If the query returns more data points than the max data points setting, then the data source consolidates them (reduces the number of points returned by aggregating them together by average or max or other function). |
||||
|
||||
There are two main reasons for limiting the number of points, performance and smoothing the line. The default value is the width (or number of pixels) of the graph as there is no point in having more data points than the graph panel can display. |
||||
|
||||
With streaming data, the max data points value is used for the rolling buffer. (Streaming is a continuous flow of data and buffering is a way of dividing the stream into chunks). Loki streams data in the live tailing mode. |
||||
|
||||
- **Min interval -** Sets a minimum limit for the automatically calculated interval, typically the minimum scrape interval. If a data point is saved every 15 seconds, then there's no point in having an interval lower than that. Another use case is to set it to a higher minimum than the scrape interval to get more coarse-grained, well-functioning queries. |
||||
|
||||
- **Interval -** The interval is a time span that you can use when aggregating or grouping data points by time. |
||||
|
||||
Grafana automatically calculates an appropriate interval and it can be used as a variable in templated queries. The variable is either in seconds: `$__interval` or in milliseconds: `$__interval_ms`. It is typically used in aggregation functions like sum or average. For example, a Prometheus query using the interval variable: `rate(http_requests_total[$__interval])`. |
||||
|
||||
This automatic interval is calculated based on the width of the graph. If the user zooms out a lot then the interval becomes greater, resulting in a more coarse grained aggregation whereas if the user zooms in then the interval decreases resulting in a more fine grained aggregation. |
||||
|
||||
For more information, refer to [Global variables]({{< relref "../dashboards/variables/add-template-variables/#global-variables" >}}). |
||||
|
||||
- **Relative time -** You can override the relative time range for individual panels, causing them to be different than what is selected in the dashboard time picker in the top right corner of the dashboard. This allows you to show metrics from different time periods or days on the same dashboard. |
||||
|
||||
- **Time shift -** The time shift function is another way to override the time range for individual panels. It only works with relative time ranges and allows you to adjust the time range. |
||||
|
||||
For example, you could shift the time range for the panel to be two hours earlier than the dashboard time picker. For more information, refer to [Time range controls]({{< relref "../dashboards/manage-dashboards/#configure-dashboard-time-range-controls" >}}). |
||||
|
||||
- **Cache timeout -** (This field is only visible if available in your data source.) If your time series store has a query cache, then this option can override the default cache timeout. Specified as a numeric value in seconds. |
||||
|
||||
### Examples: |
||||
|
||||
- **Relative time:** |
||||
|
||||
| Example | Relative time field | |
||||
| ---------------- | ------------------- | |
||||
| Last 5 minutes | `now-5m` | |
||||
| The day so far | `now/d` | |
||||
| Last 5 days | `now-5d/d` | |
||||
| This week so far | `now/w` | |
||||
| Last 2 years | `now-2y/y` | |
||||
|
||||
- **Time shift:** |
||||
|
||||
| Example | Time shift field | |
||||
| -------------------- | ---------------- | |
||||
| Last entire week | `1w/w` | |
||||
| Two entire weeks ago | `2w/w` | |
||||
| Last entire month | `1M/M` | |
||||
| This entire year | `1d/y` | |
||||
| Last entire year | `1y/y` | |
@ -1,20 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/add-a-panel/ |
||||
- /docs/grafana/latest/panels/legend-options/ |
||||
- /docs/grafana/latest/panels/panel-editor/ |
||||
- /docs/grafana/latest/panels/panel-options/ |
||||
- /docs/grafana/latest/panels/standard-options/ |
||||
- /docs/grafana/latest/panels/working-with-panels/ |
||||
- /docs/sources/panels/working-with-panels/ |
||||
title: Working with Grafana panels |
||||
weight: 100 |
||||
--- |
||||
|
||||
# Working with Grafana panels |
||||
|
||||
A Grafana panel is the user interface you use to define a data source query, and transform and format data that appears in visualizations. |
||||
|
||||
A panel editor includes a query builder and a series of options that you can use to transform data and add information to your panels. |
||||
|
||||
{{< section >}} |
@ -1,23 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/working-with-panels/download-query-results/ |
||||
- /docs/sources/panels/working-with-panels/download-query-results/ |
||||
title: Download query results |
||||
weight: 110 |
||||
--- |
||||
|
||||
# Download query results |
||||
|
||||
Grafana generates a text (.txt) file that contains the results of a query, which you can download. |
||||
|
||||
## Before you begin |
||||
|
||||
- [Add a query]({{< relref "../query-a-data-source/add-a-query/" >}}). |
||||
|
||||
**To download query results**: |
||||
|
||||
1. Open the panel inspector. |
||||
|
||||
1. Inspect the query results. |
||||
|
||||
1. Click **Download**. |
@ -1,27 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/panels/working-with-panels/navigate-inspector-panel/ |
||||
- /docs/sources/panels/working-with-panels/navigate-inspector-panel/ |
||||
title: Navigate the Grafana Inspector panel |
||||
weight: 90 |
||||
--- |
||||
|
||||
# Navigate the Grafana Inspector panel |
||||
|
||||
The panel inspector helps you understand and troubleshoot your panels. You can inspect the raw data for any Grafana panel, export that data to a comma-separated values (CSV) file, view query requests, and export panel and data JSON. |
||||
|
||||
> **Note:** Not all panel types include all tabs. For example, dashboard list panels do not have raw data to inspect, so they do not display the Stats, Data, or Query tabs. |
||||
|
||||
The panel inspector consists of the following options: |
||||
|
||||
1. The panel inspector displays Inspect: <NameOfPanelBeingInspected> at the top of the pane. Click the arrow in the upper right corner to expand or reduce the pane. |
||||
|
||||
2. **Data tab -** Shows the raw data returned by the query with transformations applied. Field options such as overrides and value mappings are not applied by default. |
||||
|
||||
3. **Stats tab -** Shows how long your query takes and how much it returns. |
||||
|
||||
4. **JSON tab -** Allows you to view and copy the panel JSON, panel data JSON, and data frame structure JSON. This is useful if you are provisioning or administering Grafana. |
||||
|
||||
5. **Query tab -** Shows you the requests to the server sent when Grafana queries the data source. |
||||
|
||||
6. **Error tab -** Shows the error. Only visible when query returns error. |
@ -0,0 +1,85 @@ |
||||
--- |
||||
aliases: |
||||
- docs/grafana/latest/search/ |
||||
title: Search |
||||
menutitle: Search |
||||
description: Learn how to search for Grafana dashboards |
||||
weight: 80 |
||||
keywords: |
||||
- search |
||||
- dashboard |
||||
--- |
||||
|
||||
# Search dashboards |
||||
|
||||
You can search for dashboards by dashboard name and by panel title. When you search for dashboards, the system returns all dashboards available within the Grafana instance, even if you do not have permission to view the contents of the dashboard. |
||||
|
||||
## Search dashboards using dashboard name |
||||
|
||||
Begin typing any part of the dashboard name in the search bar. The search returns results for any partial string match in real-time, as you type. |
||||
|
||||
Dashboard search is: |
||||
|
||||
- Real-time |
||||
- _Not_ case sensitive |
||||
- Functional across stored _and_ file based dashboards. |
||||
|
||||
> **Note**: You can use your keyboard arrow keys to navigate the results and press `Enter` to open the selected dashboard. |
||||
|
||||
The following image shows the search results when you search using dashboard name. |
||||
|
||||
{{< figure src="/static/img/docs/v91/dashboard-features/search-by-dashboard-name.png" width="700px" >}} |
||||
|
||||
## Search dashboards using panel title |
||||
|
||||
You can search for a dashboard by the title of a panel that appears in a dashboard. |
||||
If a panel's title matches your search query, the dashboard appears in the search results. |
||||
|
||||
This feature is available by default in Grafana Cloud and in Grafana OSS v9.1 and higher, you access this feature by enabling the `panelTitleSearch` feature toggle. |
||||
For more information about enabling panel title search, refer to [Enable the panelTitleSearch feature toggle.](#enable-panelTitleSearch-feature-toggle) |
||||
|
||||
The following image shows the search results when you search using panel title. |
||||
|
||||
{{< figure src="/static/img/docs/v91/dashboard-features/search-by-panel-title.png" width="700px" >}} |
||||
|
||||
### Enable the panelTitleSearch feature toggle |
||||
|
||||
Complete the following steps to enable the `panelTitleSearch` feature toggle. |
||||
|
||||
**Before you begin:** |
||||
|
||||
- If you are running Grafana Enterprise with RBAC, enable [service accounts]({{< relref "../administration/service-accounts/" >}}). |
||||
|
||||
**To enable the panelTitleSearch feature toggle:** |
||||
|
||||
1. Open the Grafana [configuration file]({{< relref "../setup-grafana/configure-grafana/#configuration-file-location" >}}). |
||||
|
||||
1. Locate the [feature_toggles]({{< relref "../setup-grafana/configure-grafana/#feature_toggles" >}}) section. |
||||
|
||||
1. Add the following parameter to the `feature_toggles` section: |
||||
|
||||
``` |
||||
[feature_toggles] |
||||
# enable features, separated by spaces |
||||
enable = dashboardPreviews |
||||
``` |
||||
|
||||
1. Save your changes and restart the Grafana server. |
||||
|
||||
## Filter dashboard search results by tag(s) |
||||
|
||||
Tags are a great way to organize your dashboards, especially as the number of dashboards grow. You can add and manage tags in dashboard `Settings`. |
||||
|
||||
When you select multiple tags, Grafana shows dashboards that include all selected tags. |
||||
|
||||
To filter dashboard search result by a tag, complete one of the following steps: |
||||
|
||||
- To filter dashboard search results by tag, click a tag that appears in the right column of the search results. |
||||
|
||||
You can continue filtering by clicking additional tags. |
||||
|
||||
- To see a list of all available tags, click the **Filter by tags** dropdown menu and select a tag. |
||||
|
||||
All tags will be shown, and when you select a tag, the dashboard search will be instantly filtered. |
||||
|
||||
> **Note:** When using only a keyboard, press the `tab` key and navigate to the **Filter by tag** drop-down menu, press the down arrow key `▼` to activate the menu and locate a tag, and press `Enter` to select the tag. |
@ -1,180 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/features/panels/geomap/ |
||||
- /docs/grafana/latest/panels/visualizations/geomap/ |
||||
- /docs/grafana/latest/visualizations/geomap/ |
||||
description: Geomap visualization documentation |
||||
keywords: |
||||
- grafana |
||||
- Geomap |
||||
- panel |
||||
- documentation |
||||
title: Geomap |
||||
weight: 600 |
||||
--- |
||||
|
||||
# Geomap |
||||
|
||||
The Geomap panel visualization allows you to view and customize the world map using geospatial data. You can configure various overlay styles and map view settings to easily focus on the important location-based characteristics of the data. |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-example-8-1-0.png" max-width="1200px" caption="Geomap panel" >}} |
||||
|
||||
## Map View |
||||
|
||||
The map view controls the initial view of the map when the dashboard loads. |
||||
|
||||
### Initial View |
||||
|
||||
The initial view configures how the GeoMap panel renders when the panel is first loaded. |
||||
|
||||
- **View** sets the center for the map when the panel first loads. |
||||
- **Fit to data** fits the map view based on the data extents of Map layers and updates when data changes. |
||||
- **Data** option allows selection of extent based on data from "All layers", a single "Layer", or the "Last value" from a selected layer. |
||||
- **Layer** can be selected if fitting data from a single "Layer" or the "Last value" of a layer. |
||||
- **Padding** sets padding in relative percent beyond data extent (not available when looking at "Last value" only). |
||||
- **Max Zoom** sets the maximum zoom level when fitting data. |
||||
- **Coordinates** sets the map view based on: |
||||
- **Latitude** |
||||
- **Longitude** |
||||
- Default Views are also available including: |
||||
- **(0°, 0°)** |
||||
- **North America** |
||||
- **South America** |
||||
- **Europe** |
||||
- **Africa** |
||||
- **West Asia** |
||||
- **South Asia** |
||||
- **South-East Asia** |
||||
- **East Asia** |
||||
- **Australia** |
||||
- **Oceania** |
||||
- **Zoom** sets the initial zoom level. |
||||
|
||||
## Map layers |
||||
|
||||
The Geomap visualization supports showing multiple layers. Each layer determines how you visualize geospatial data on top of the base map. |
||||
|
||||
### Types |
||||
|
||||
There are three map layer types to choose from in the Geomap visualization. |
||||
|
||||
- [Markers]({{< relref "markers/" >}}) renders a marker at each data point. |
||||
- [Heatmap]({{< relref "heatmap/" >}}) visualizes a heatmap of the data. |
||||
- [GeoJSON]({{< relref "geojson/" >}}) renders static data from a GeoJSON file. |
||||
|
||||
There are also four alpha layer types. |
||||
|
||||
- [Night / Day (alpha)]({{< relref "daynight/" >}}) renders a night / day region. |
||||
- **Icon at last point (alpha)** renders an icon at the last data point. |
||||
- **Dynamic GeoJSON (alpha)** styles a GeoJSON file based on query results. |
||||
- **Route (alpha)** render data points as a route. |
||||
|
||||
> **Note:** [Basemap layer types]({{< relref "#types-1" >}}) can also be added as layers. You can specify an opacity. |
||||
|
||||
### Layer Controls |
||||
|
||||
The layer controls allow you to create layers, change their name, reorder and delete layers. |
||||
|
||||
- **Add layer** creates an additional, configurable data layer for the Geomap visualization. When you add a layer, you are prompted to select a layer type. You can change the layer type at any point during panel configuration. See the **Layer Types** section above for details on each layer type. |
||||
- The layer controls allow you to rename, delete, and reorder the layers of the panel. |
||||
- **Edit layer name (pencil icon)** renames the layer. |
||||
- **Trash Bin** deletes the layer. |
||||
- **Reorder (six dots/grab handle)** allows you to change the layer order. Data on higher layers will appear above data on lower layers. The panel will update the layer order as you drag and drop to help simplify choosing a layer order. |
||||
|
||||
You can add multiple layers of data to a single Geomap panel in order to create rich, detailed visualizations. |
||||
|
||||
### Location |
||||
|
||||
The Geomap panel needs a source of geographical data. This data comes from a database query, and there are four mapping options for your data. |
||||
|
||||
- **Auto** automatically searches for location data. Use this option when your query is based on one of the following names for data fields. |
||||
- geohash: “geohash” |
||||
- latitude: “latitude”, “lat” |
||||
- longitude: “longitude”, “lng”, “lon” |
||||
- lookup: “lookup” |
||||
- **Coords** specifies that your query holds coordinate data. You will get prompted to select numeric data fields for latitude and longitude from your database query. |
||||
- **Geohash** specifies that your query holds geohash data. You will be prompted to select a string data field for the geohash from your database query. |
||||
- **Lookup** specifies that your query holds location name data that needs to be mapped to a value. You will be prompted to select the lookup field from your database query and a gazetteer. The gazetteer is the directory that is used to map your queried data to a geographical point. |
||||
|
||||
## Basemap layer |
||||
|
||||
A basemap layer provides the visual foundation for a mapping application. It typically contains data with global coverage. Several base layer options |
||||
are available each with specific configuration options to style the base map. |
||||
|
||||
### Types |
||||
|
||||
There are four basemap layer types to choose from in the Geomap visualization. |
||||
|
||||
- [Open Street Map]({{< relref "osm/" >}}) adds a map from a collaborative free geographic world database. |
||||
- [CARTO]({{< relref "carto/" >}}) adds a layer from CARTO Raster basemaps. |
||||
- [ArcGIS]({{< relref "arcgis/" >}}) adds a layer from an ESRI ArcGIS MapServer. |
||||
- [XYZ]({{< relref "xyz/" >}}) adds a map from a generic tile layer. |
||||
|
||||
### Default |
||||
|
||||
The default base layer uses the [CARTO]({{< relref "carto/" >}}) map. You can define custom default base layers in the `.ini` configuration file. |
||||
|
||||
 |
||||
|
||||
#### Configure the default base layer with provisioning |
||||
|
||||
You can configure the default base map using config files with Grafana’s provisioning system. For more information on all the settings, refer to the [provisioning docs page]({{< relref "../../administration/provisioning/" >}}). |
||||
|
||||
Use the JSON configuration option `default_baselayer_config` to define the default base map. There are currently four base map options to choose from: `carto`, `esri-xyz`, `osm-standard`, `xyz`. Here are some provisioning examples for each base map option. |
||||
|
||||
- **carto** loads the CartoDB tile server. You can choose from `auto`, `dark`, and `light` theme for the base map and can be set as shown below. The `showLabels` tag determines whether or not Grafana shows the Country details on top of the map. Here is an example: |
||||
|
||||
```ini |
||||
geomap_default_baselayer = `{ |
||||
"type": "carto", |
||||
"config": { |
||||
"theme": "auto", |
||||
"showLabels": true |
||||
} |
||||
}` |
||||
``` |
||||
|
||||
- **esri-xyz** loads the ESRI tile server. There are already multiple server instances implemented to show the various map styles: `world-imagery`, `world-physical`, `topo`, `usa-topo`, and `ocean`. The `custom` server option allows you to configure your own ArcGIS map server. Here are some examples: |
||||
|
||||
```ini |
||||
geomap_default_baselayer = `{ |
||||
"type": "esri-xyz", |
||||
"config": { |
||||
"server": "world-imagery" |
||||
} |
||||
}` |
||||
``` |
||||
|
||||
```ini |
||||
geomap_default_baselayer = `{ |
||||
"type": "esri-xyz", |
||||
"config": { |
||||
"server": "custom", |
||||
"url": "[tile server url]", |
||||
"attribution": "[tile server attribution]" |
||||
} |
||||
}` |
||||
``` |
||||
|
||||
- **osm-standard** loads the OpenStreetMap tile server. There are no additional configurations needed and the `config` fields can be left blank. Here is an example: |
||||
|
||||
```ini |
||||
default_baselayer_config = `{ |
||||
"type": "osm-standard", |
||||
"config": {} |
||||
}` |
||||
``` |
||||
|
||||
- **xyz** loads a custom tile server defined by the user. Set a valid tile server `url`, with {z}/{x}/{y} for this option in order to properly load a default base map. Here is an example: |
||||
|
||||
```ini |
||||
default_baselayer_config = `{ |
||||
"type": "xyz", |
||||
"config": { |
||||
"attribution": "Open street map", |
||||
"url": "https://tile.openstreetmap.org/{z}/{x}/{y}.png" |
||||
} |
||||
}` |
||||
``` |
||||
|
||||
`enable_custom_baselayers` allows you to enable or disable custom open source base maps that are already implemented. The default is `true`. |
@ -1,44 +0,0 @@ |
||||
--- |
||||
aliases: |
||||
- /docs/grafana/latest/features/panels/geomap/arcgis/ |
||||
- /docs/grafana/latest/panels/visualizations/geomap/arcgis/ |
||||
description: ArcGIS layer |
||||
keywords: |
||||
- grafana |
||||
- Geomap |
||||
- panel |
||||
- documentation |
||||
title: ArcGIS layer |
||||
weight: 10 |
||||
--- |
||||
|
||||
# ArcGIS layer |
||||
|
||||
An ArcGIS layer is a layer from an ESRI ArcGIS MapServer. |
||||
|
||||
## Options |
||||
|
||||
- **Server Instance** to select the map type. |
||||
- World Street Map |
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-arcgis-wsm-9-1-0.png" max-width="1200px" caption="Geomap panel ArcGIS World Street Map" >}} |
||||
- World Imagery |
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-arcgis-wi-9-1-0.png" max-width="1200px" caption="Geomap panel ArcGIS World Imagery" >}} |
||||
- World Physical |
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-arcgis-wp-9-1-0.png" max-width="1200px" caption="Geomap panel ArcGIS World Physical" >}} |
||||
- Topographic |
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-arcgis-topographic-9-1-0.png" max-width="1200px" caption="Geomap panel ArcGIS Topographic" >}} |
||||
- USA Topographic |
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-arcgis-usa-topographic-9-1-0.png" max-width="1200px" caption="Geomap panel ArcGIS USA Topographic" >}} |
||||
- World Ocean |
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-arcgis-ocean-9-1-0.png" max-width="1200px" caption="Geomap panel ArcGIS World Ocean" >}} |
||||
- Custom MapServer (see [XYZ]({{< relref "xyz/" >}}) for formatting) |
||||
- URL template |
||||
- Attribution |
||||
- **Opacity** from 0 (transparent) to 1 (opaque) |
||||
|
||||
{{< figure src="/static/img/docs/geomap-panel/geomap-arcgis-options-9-1-0.png" max-width="1200px" caption="Geomap panel ArcGIS options" >}} |
||||
|
||||
## More Information |
||||
|
||||
- [**ArcGIS Services**](https://services.arcgisonline.com/arcgis/rest/services) |
||||
- [**About ESRI**](https://www.esri.com/en-us/about/about-esri/overview) |
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue