Docs: added Getting Started tutorial.
This commit is contained in:
@@ -1,3 +1,55 @@
|
||||
# Getting Started with Grafana-Zabbix
|
||||
After you [installed and configured](../installation/index.md) Grafana-Zabbix data source let's
|
||||
create a simple dashboard.
|
||||
|
||||
## Simple Graph
|
||||
Add new Graph panel to dashboard.
|
||||
Select metrics from dropdown or start to type to filter results
|
||||
|
||||

|
||||
|
||||
Let's create _15 min avg processor load_ graph. Select Host Group, Host, Application (optional - you can leave it blank) and Item.
|
||||
|
||||

|
||||
|
||||
## Multiple Items On One Graph
|
||||
You can build graphs with lots of items using Regular Expressions inside metric field. Grafana uses JavaScript regex implementation. For example, if you need to show CPU time (user, system, iowait, etc) you may create graph using this regex in Item field:
|
||||
```js
|
||||
/CPU (?!idle).* time/
|
||||
```
|
||||
|
||||

|
||||
|
||||
Another case to use regex is comparing the same metrics for different hosts. Use `/.*/` regex for showing all metrics or write your own filter. For example, I want to show _CPU system time_ for all hosts which name started with _backend_ from all host groups. I use `/.*/` for Group, `/^backend/` for Host and `CPU system time` for Item.
|
||||
|
||||

|
||||
|
||||
## Bar Chart
|
||||
Let's create a graph wich show queries stats for MySQL database. Select Group, Host, Application (_MySQL_ in my case) and Items. I use `/MySQL .* operations/` regex for filtering different types of operations.
|
||||
|
||||

|
||||
|
||||
To show graph as Bar Chart, go to the **Display** tab, uncheck **Lines** and set **Bars**. Also, enable **Stack** checkbox for showing stacked bars.
|
||||
|
||||

|
||||
|
||||
But this graph doesn't look good because it contains too many bars. We can fix it by using **Max data points** parameter. Go to the **Metrics** tab and set **Max data points** to 50 for example.
|
||||
|
||||

|
||||
|
||||
Ok, looks pretty!
|
||||
|
||||
## Singlestat and Gauges
|
||||
Sometimes you may need to show just a big single value for particular metric. Use Grafana's **Singlestat** panel in this case. Let's create panel which shows _CPU user time_ metric.
|
||||
|
||||

|
||||
|
||||
Suppose that you want to set units as percents and show **Gauge** for this value. Go to the **Options** tab and set units to _percent (0-100)_. Then enable _Show_ option for _Gauge_ and set Min and Max values for your metric (0-100 in our case). Set thresholds if you want to see it on Gauge (`50,80` for example).
|
||||
|
||||

|
||||
|
||||
Great, looks cool. Read more about Singlestat panel in [Grafana docs](http://docs.grafana.org/reference/singlestat/).
|
||||
|
||||
And all together:
|
||||
|
||||

|
||||
|
||||
3
docs/sources/img/getstarting-dashboard_1.png
Normal file
3
docs/sources/img/getstarting-dashboard_1.png
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:79be2fa54813ede0dcdd79e6dd7cda7c188ca9ab0b3a9022a803a1d28886e866
|
||||
size 609785
|
||||
3
docs/sources/img/getstarting-metrics_filtering.png
Normal file
3
docs/sources/img/getstarting-metrics_filtering.png
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:6fa80eb71d927eabac75361dceba746ec94d58cb85dd2bd90b88ec009c7ebee5
|
||||
size 414913
|
||||
3
docs/sources/img/getstarting-mysql_operations_1.png
Normal file
3
docs/sources/img/getstarting-mysql_operations_1.png
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:8ad7e510b8e169154daabdac06403106497b2e7d06623e4db58597d488f7e81d
|
||||
size 491086
|
||||
3
docs/sources/img/getstarting-mysql_operations_2.png
Normal file
3
docs/sources/img/getstarting-mysql_operations_2.png
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:b05d4ef4f6c176ac6e9b0ed63f75cc1fefe8f96fee3144970276e986e75f786a
|
||||
size 548292
|
||||
3
docs/sources/img/getstarting-mysql_operations_3.png
Normal file
3
docs/sources/img/getstarting-mysql_operations_3.png
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:5c293947309f2691d9e37486986f4847035d97cfb16fc21f9c387584e061966e
|
||||
size 453540
|
||||
3
docs/sources/img/getstarting-processor_load.png
Normal file
3
docs/sources/img/getstarting-processor_load.png
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:97c137b26035d4eaa0f52f74e5e5dfd104e0be548e1291b0d596e4214a9a1095
|
||||
size 451059
|
||||
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:241edf664703352a3248805e37e9dc191470874b7269e5b2b080ddbf8d72a1a0
|
||||
size 721542
|
||||
3
docs/sources/img/getstarting-regex_cpu_time.png
Normal file
3
docs/sources/img/getstarting-regex_cpu_time.png
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:bacbe565f88ccb8b2bbf8318db3622cfa99c3452a3521e0a4f4f97139e4e1772
|
||||
size 469812
|
||||
3
docs/sources/img/getstarting-singlestat_1.png
Normal file
3
docs/sources/img/getstarting-singlestat_1.png
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:cb08dff893b4795fbee5d922bb3c34688f3673a90b828a1cb87d6f54ab233ca0
|
||||
size 386197
|
||||
3
docs/sources/img/getstarting-singlestat_2.png
Normal file
3
docs/sources/img/getstarting-singlestat_2.png
Normal file
@@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:41299e93dd4bccead469b79d565915dd99eee7b2f78f62b6347f278b81d85fff
|
||||
size 542458
|
||||
Reference in New Issue
Block a user