Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Grafana Dashboard outdated for InfluxDB 0.9.x #648

Closed
cazzoo opened this issue Aug 13, 2015 · 10 comments
Closed

Grafana Dashboard outdated for InfluxDB 0.9.x #648

cazzoo opened this issue Aug 13, 2015 · 10 comments
Labels
Milestone

Comments

@cazzoo
Copy link

cazzoo commented Aug 13, 2015

Hello!

I just installed Glances, InfluxDB 0.9.x and Grafana and tried to add the dashboard to Grafana. Unfortunately, all the queries are not working as all set to default.

I used the file providen there : github file
I double checked to import the correct json file but after many tries I looked for dashboard queries..

I'm completely new to InfluxDB queries so I'm not able to adapt queries to get them work in Grafana, otherwise, I'm able to test it out.

Anyway, cheers for Glances that progress really a lot since last time I checked it (maybe 1+ year)

@nicolargo
Copy link
Owner

What is your Glances version ?

Glances 2.4 is not compliant with InfluxDB 0.9.X.
You should use the develop branch (Glances 2.5 beta).

Can you give a try with the DEVELOP branch ?

@rk4an
Copy link

rk4an commented Sep 30, 2015

Hi

Just test 2.5RC1 with InfluxDB 0.9 and I have this error:

Traceback (most recent call last):
  File "C:\Python34\Scripts\glances-script.py", line 9, in <module>
    load_entry_point('Glances==2.5', 'console_scripts', 'glances')()
  File "C:\Python34\lib\site-packages\glances-2.5-py3.4.egg\glances\__init__.py", line 122, in main
    args=core.get_args())
  File "C:\Python34\lib\site-packages\glances-2.5-py3.4.egg\glances\core\glances_standalone.py", line 79, in __init__
    self.screen = GlancesCursesStandalone(args=args)
  File "C:\Python34\lib\site-packages\glances-2.5-py3.4.egg\glances\outputs\glances_curses.py", line 175, in __init__
    'PASSWORD': curses.A_PROTECT
AttributeError: 'WCurseLight' object has no attribute 'A_PROTECT'

@asergi
Copy link
Collaborator

asergi commented Oct 12, 2015

@rk4an this should have been fixed in version 2.5.1.

@rafantastico
Copy link

Hi all!

First of all thank you for glances software, it's a great tool!

I'm trying to use it with influxDB and Grafana.

What I have done
1.- Installation of version 2.5.1 of glances from the develop branch
2.- Installation of InfluxDB 0.9.4.2
3.- Installation of Grafana 2.5.0
4.- New database in influx called glances
5.- Launch glances with the command

glances -C ~/glances/glancesConfig --export-influxdb

The config file contains the following lines (as you suggested):

[influxdb]
host=localhost
port=8086
user=root
password=root
db=glances

6.- Start Grafana web with admin user and add a new data source setting as default with the following parameters:

Name: glances
Type: InfluxDB 0.9.X
URL: http://localhost:8086
Database: glances
user: root
pass: root

7.- Import the dashboard indicated here

The problem
All the rows present the error:

Timeseries data request error

Solutions applied
1.-Trying to find the problem I've realized that if in Grafana you edit the configuration of a measurement and switch to editor mode all the representation of it (for instance the three representations of "load") the error disappears and appears a new one!

load

switch

2.- The new error says:

InfluxDB Error Response: error parsing query: found ASC, expected BY at line 1, char 92

This error is deleted if you include in glances-grafana.json in every "order asc" the word "by" getting "order by asc"

Now almost all the figures can be seen.

But still there are some problems...
The figures related to CPU present a request similar to:

select mean(user) from "cpu" where $timeFilter group by time($interval) fill(null) order asc

This request return the error:

"error": "error parsing query: found USER, expected identifier, string, number, bool at line 1, char 13"

This last error I don't know how to fix it.

Additionally, I think that the file glances-grafana.json must be conveniently updated and I guess the error must came from a change in Grafana framework.

Thank you very much and enjoy the day!

@nicolargo
Copy link
Owner

Hi @rafantastico

First of all thanks for this useful and documented comment.

InfluxDB and Grafana are "under development". The InfluxDB API and the Grafana framework change.
I just merge your patch concerning the "order by asc" command in the DEVELOP branch.

For the last problem, i will have a look as soon as possible. If you find the solution, please tell me ;)

@nicolargo nicolargo added bug and removed invalid labels Oct 29, 2015
@nicolargo nicolargo added this to the Version 2.6 milestone Oct 29, 2015
@nicolargo
Copy link
Owner

Re-hi @rafantastico

I just commit a new version of the Grafana dashboard.
It should correct your issue.

Tell me if it is ok for you.

Nicolas

@rafantastico
Copy link

Hi @nicolargo

It works like a charm!

Thank you for your fast and accurate answer 👍

Cheers!

@bhayden53
Copy link

Hello,

I have attempted to use the develop branch, because I had the same issue as the original post. However, now the dashboard shows "no datapoints" for every field. Is there any combination of releases where this is known to work?

@nicolargo
Copy link
Owner

@drhay53 yes it works on my side with: the current DEVELOP branch, InfluxDB 0.9.5, Grafana 2.5.0 and the default section on the Glances configuration file (chck the configuration file path in the /tmp/glances.log file):

[influxdb]
# Configuration file for the --export-influxdb option
# https://influxdb.com/
host=localhost
port=8086
user=root
password=root
db=glances
prefix=localhost
#tags=foo:bar,spam:eggs

Do not forget to configure the InfluxDB data source in Grafana:

selection_428

@bhayden53
Copy link

It appears that I was missing the 'prefix=localhost' part of the config. I took my config directly from somewhere in the Docs or the github, but perhaps I missed that part. Thanks for the quick help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

6 participants