grafana / grafana-zabbix

Zabbix plugin for Grafana dashboard
http://play.grafana-zabbix.org
Apache License 2.0
2.06k stars 458 forks source link

Sort metrics by value #96

Open DaemonGit opened 8 years ago

DaemonGit commented 8 years ago

Hello, is it possible to have more than one Zabbix Server in the Datasource? I tried it with a second plugintype in the plugin.json file but when I restart the grafana server it doesn't show up. Do I have to set up a second plugin.json file or even a whole plugin folder?

alexanderzobnin commented 8 years ago

@DaemonGit Hi! If you use last version of plugin (2.1) and Grafana (2.1.3) you don't need to configure datasource via plugin.json file. You can fully configure datasource at configuration page (when add new datasource). You can also add two ore more zabbix datasources with different parameters:

screenshot 2015-10-13 16 16 20 screenshot 2015-10-13 16 16 37

DaemonGit commented 8 years ago

Thanks that very cool! At the moment I'm trying to get some data of my Zabbix Datasource1 and then I want to add an Query with Data from Datasource2:

unbenannt

But when I do that it deletes the first one isn't it possible to get Data from 2 Datasources in to one Graph?

alexanderzobnin commented 8 years ago

@DaemonGit I understand what you want. Mixed datasources in one panel are available in Grafana 2.5 builds. And also you must use fix-query_editor_in_2.5 branch of grafana-zabbix plugin.

DaemonGit commented 8 years ago

Okay I'll try this out today.

DaemonGit commented 8 years ago

@alexanderzobnin Is there a filter which can filter everything under 50% out or everything over 80%?
Something like:

Filter: hosts < 20

Or just sort the legend by percent because now the legend of All Series is sorted by the alphabet but wouldn't it be better to sort it by size?

Because now the legend is looking like that:

unbenannt

But wouldn't it be usefull if you could select sorty by numbers or alphabet etc. Or maybe this is already possible and I am doing something wrong?

I mean something like that:

    "id": 1,
    "leftYAxisLabel": "Disk root used",
    "legend": {
    "avg": true,
    "sortyby": "numbers", <- this
    "current": false,
    "max": false,
    "min": false,
    "show": false,
    "total": false,
    "values": true,
    "rightSide": false,
    "alignAsTable": true
alexanderzobnin commented 8 years ago

@DaemonGit It's good ideas about sorting and filtering by value. I've tried to remove all empty series from graph. But your idea with filtering by value is more general and covers my case.

alexanderzobnin commented 8 years ago

@DaemonGit This features are not implemented yet.

DaemonGit commented 8 years ago

@alexanderzobnin Okay, it would be cool to see them in the future, I think alot of people could use them. So far many thanks to you!

DaemonGit commented 8 years ago

@alexanderzobnin Is this feature in work?

EDIT: Okay doesn't seem so, I'll try to do it on my own in the plugin.

volter commented 8 years ago

You'll definitely have to do all the filtering on the client side. The API does not offer it. https://support.zabbix.com/browse/ZBXNEXT-1810 is somewhat related.

gealtrag commented 7 years ago

Filtering by value is the most needed feature for me. Any progress there?

7abbix commented 5 years ago

Any updates on this? We need to build a kiosk dashboard, which should show only Top-10 volumes by space usage. This is very needed feature

ironbishop commented 3 years ago

for anyone eventually stumbling on this... you are supposed to sort using Calculation

top(20, sum) + "Total" = sorted ok

image

top(20, sum) + "Last (not null)" = no sort

image

github-actions[bot] commented 1 month ago

This issue has been automatically marked as stale because it has not had activity in the last 2 years. It will be closed in 60 days if no further activity occurs. Please feel free to leave a comment if you believe the issue is still relevant. Thank you for your contributions!