mirror of
https://github.com/grafana/grafana.git
synced 2024-11-25 18:30:41 -06:00
Docs: Add documentation about log levels (#28975)
* Add documentation about log level * Update * Update * Update * Add unknow to table * Update docs/sources/explore/index.md Co-authored-by: achatterjee-grafana <70489351+achatterjee-grafana@users.noreply.github.com> * Update docs/sources/panels/visualizations/logs-panel.md Co-authored-by: achatterjee-grafana <70489351+achatterjee-grafana@users.noreply.github.com> Co-authored-by: achatterjee-grafana <70489351+achatterjee-grafana@users.noreply.github.com>
This commit is contained in:
parent
6d40206431
commit
e834ad0093
@ -155,6 +155,33 @@ Along with metrics, Explore allows you to investigate your logs with the followi
|
||||
|
||||
Results of log queries are shown as histograms in the graph and individual logs are displayed below. If the data source does not send histogram data for the requested time range, the logs model computes a time series based on the log row counts bucketed by an automatically calculated time interval and the start of the histogram is then anchored by the first log row's timestamp from the result. The end of the time series is anchored to the time picker's **To** range.
|
||||
|
||||
#### Log level
|
||||
|
||||
For logs where a **level** label is specified, we use the value of the label to determine the log level and update color accordingly. If the log doesn't have a level label specified, we parse the log to find out if its content matches any of the supported expressions (see below for more information). The log level is always determined by the first match. In case Grafana is not able to determine a log level, it will be visualized with **unknown** log level.
|
||||
|
||||
**Supported log levels and mapping of log level abbreviation and expressions:**
|
||||
|
||||
|
||||
| Supported expressions | Log level | Color |
|
||||
| --------------------------- |:-------------:| -----------:|
|
||||
| emerg | critical | purple |
|
||||
| fatal | critical | purple |
|
||||
| alert | critical | purple |
|
||||
| crit | critical | purple |
|
||||
| critical | critical | purple |
|
||||
| err | error | red |
|
||||
| eror | error | red |
|
||||
| error | error | red |
|
||||
| warn | warning | yellow |
|
||||
| warning | warning | yellow |
|
||||
| info | info | green |
|
||||
| information | info | green |
|
||||
| notice | info | green |
|
||||
| dbug | debug | blue |
|
||||
| debug | debug | blue |
|
||||
| trace | trace | light blue |
|
||||
| * | unknown | grey |
|
||||
|
||||
### Visualization options
|
||||
|
||||
You can customize how logs are displayed and select which columns are shown.
|
||||
|
@ -17,6 +17,10 @@ The logs panel shows the result of queries that were entered in the Query tab. T
|
||||
|
||||
To limit the number of lines rendered, you can use the **Max data points** setting in the **Query options**. If it is not set, then the data source will usually enforce a default limit.
|
||||
|
||||
## Log level
|
||||
|
||||
For logs where a **level** label is specified, we use the value of the label to determine the log level and update color accordingly. If the log doesn't have a level label specified, we parse the log to find out if its content matches any of the supported expressions (see below for more information). The log level is always determined by the first match. In case Grafana is not able to determine a log level, it will be visualized with **unknown** log level. See [supported log levels and mappings of log level abbreviation and expressions](../explore/#log-level/).
|
||||
|
||||
### Display options
|
||||
|
||||
Use these settings to refine your visualization:
|
||||
|
Loading…
Reference in New Issue
Block a user