grafana-telegraf-dashboard-generator icon indicating copy to clipboard operation
grafana-telegraf-dashboard-generator copied to clipboard

Problems with default setup

Open thomask77 opened this issue 8 years ago • 2 comments

Hi!

I'm running a fresh install of Grafana 3.0.4, InfluxDB 0.13.0 and Telegraf 0.13.1 on a Debian Jessie server. All packages are left in their default configuration. In Grafana, I've set up a Datasource named "telegraf" with an InfluxDB connection to localhost:8086.

Generating and importing works:

# ./generator.py -v
INFO:urllib3.connectionpool:Starting new HTTP connection (1): localhost
DEBUG:urllib3.connectionpool:"GET /query?q=SHOW+DATABASES HTTP/1.1" 200 133
DEBUG:root:InfluxDB database telegraf :
INFO:urllib3.connectionpool:Resetting dropped connection: localhost
DEBUG:urllib3.connectionpool:"GET /query?q=SHOW+MEASUREMENTS&db=telegraf HTTP/1.1" 200 129

# ls dashboards
telegraf.json

# curl "http://admin:[email protected]:3000/api/dashboards/db" -X POST -H 'Content-Type: application/json;charset=UTF-8' --data-binary @dashboards/telegraf.json
{"slug":"telegraf","status":"success","version":1}#                                                                                

Problem: When i select the dashboard in Grafana, it doesn't work. The title of the first row is "NETFLOW - $PROJET", the Uptime has "$server" as title. All panels have red exclamation marks. Inspector shows following error:

{
  "error": "error parsing query: found $, expected identifier, string, number, bool at line 1, char 100",
  "message": "error parsing query: found $, expected identifier, string, number, bool at line 1, char 100"
}

How do i get this to work?

best regards, Thomas

thomask77 avatar Jun 13 '16 08:06 thomask77

Hi @thomask77, I'm not sure you need netflow. You might as well comment it in the script. The $server thing is a templating that you don't have in your dashboard. You would need to add one with the name server and a value that is the hostname of your machine. Once you've done that you can add a file in the templates folder so it is included in the dashboard when generated.

corentingi avatar Jun 13 '16 09:06 corentingi

Hi,

Just in case, you can now grab the full dashboard from grafana.net

Regards.

descrepes avatar Jun 28 '16 10:06 descrepes