Closed druchoo closed 8 years ago
Hi, By collector I mean collectd. InfluxDB I consider to be a storage. Getdash has hardcoded queries in influxdb SQL so it is not storage independent.
However, what getdash does is really straightforward. It gets all series from the sotrage and parses them according to plugins 'graph' configuration. Afterwards it generates Grafana dashboard JSON and returns it.
Here is how series from influxdb looks on the input:
$ curl -sG 'http://localhost:8086/query?pretty=true' --data-urlencode "db=collectd" --data-urlencode "q=SHOW SERIE WHERE host = 'vagrant-ubuntu-precise-64';" | grep disk
"disk_read,host=vagrant-ubuntu-precise-64,instance=sda,type=disk_merged"
"disk_read,host=vagrant-ubuntu-precise-64,instance=sda,type=disk_octets"
"disk_read,host=vagrant-ubuntu-precise-64,instance=sda,type=disk_ops"
"disk_read,host=vagrant-ubuntu-precise-64,instance=sda,type=disk_time"
"disk_read,host=vagrant-ubuntu-precise-64,instance=sda1,type=disk_merged"
"disk_read,host=vagrant-ubuntu-precise-64,instance=sda1,type=disk_octets"
"disk_read,host=vagrant-ubuntu-precise-64,instance=sda1,type=disk_ops"
"disk_read,host=vagrant-ubuntu-precise-64,instance=sda1,type=disk_time"
"disk_write,host=vagrant-ubuntu-precise-64,instance=sda,type=disk_merged"
"disk_write,host=vagrant-ubuntu-precise-64,instance=sda,type=disk_octets"
"disk_write,host=vagrant-ubuntu-precise-64,instance=sda,type=disk_ops"
"disk_write,host=vagrant-ubuntu-precise-64,instance=sda,type=disk_time"
"disk_write,host=vagrant-ubuntu-precise-64,instance=sda1,type=disk_merged"
"disk_write,host=vagrant-ubuntu-precise-64,instance=sda1,type=disk_octets"
"disk_write,host=vagrant-ubuntu-precise-64,instance=sda1,type=disk_ops"
"disk_write,host=vagrant-ubuntu-precise-64,instance=sda1,type=disk_time"
So if graphite storage can return similar series format it shouldn't be very complicated to adapt existing code for graphite. Because of differences in query language which is tied in with plugin configuration parameters, plugin configs will probably be a bit different...
Unfortunately I'm not familiar with graphite and would have to spend some time investigating it to have a more concrete answer :). This all is just my thought flow in writing...
Short answer is no, it will not work with graphite storage as a series backend.
Are you referring to collectd or InfluxDB as the collector? Running Graphite/Grafana and curious if this this work..