Elasticsearch time series data value discrepancy when visualizing in Grafana


I’m trying to graph time series data from Elasticsearch in Grafana. I could not help but notice that the values are way off.

Doing visualization in Kibana yields the correct values. Values in Grafana are off by varying factors up to 1/400 (values in Grafana being 400 times smaller than in Elasticsearch).
To me it looks like it might relate to the issue described in this post: Grafana showing huge difference in values from Kibana

Backend is ElasticSearch 6.0+, Grafana is 6.1.0.
Below you can find a screenshot of the graph configuration.


Is this to be expected? If you need any more info I will be happy to provide.

Please include more information that shows the differences between Kibana and Grafana, both queries used and visualizations.

In below screenshots you can see an example of a data point in Grafana vs. Kibana. I cannot grasp how the values can be that different, especially seeing that the factor is not even a whole number.

Grafana: 707986728
Kibana: 3330577376

Grafana Dashboard Configuration:

Kibana Dashboard Configuration:

Grafana data source config:

You’re using a bucket script aggregation in Kibana but in Grafana only a sum with a script which is not the same thing. Grafana has support for bucket script aggregation since version 6.0 so would recommend you to upgrade. But one important thing to make sure when comparing Kibana and Grafana is that you’re using the same time interval. I can see that you’re using auto in Grafana and don’t know what the interval is in Kibana. To be able to compare make sure you’re using the same interval by specifying for example 1 minute in both Grafana and Kibana.