Grafana Raw Document metric not working for ElasticSearch v6

Hello, I’m currently using Grafana v4.1.2 with ElasticSearch v6.1.1 and I’m running into a Request Error using the Raw Document metric type:

The Response has this error:

{
  "error": {
    "root_cause": [
      {
        "type": "parsing_exception",
        "reason": "Unknown key for a START_ARRAY in [fielddata_fields].",
        "line": 1,
        "col": 294
      }
    ],
    "type": "parsing_exception",
    "reason": "Unknown key for a START_ARRAY in [fielddata_fields].",
    "line": 1,
    "col": 294
  },
  "status": 400
}

I’m able to run a similar table panel for an ElasticSearch v5.5.2 datasource, so I’m not really sure if I’m doing something wrong or if this is a compatibility issue. Everything else using the v6 datasource has been working fine. Can someone help me troubleshoot?

EDIT: also I tried running the generated ElasticSearch query manually, and it gave the same error as from the Response. That is what made me think it could be related to compatibility.

1 Like

I’m in a similar case. I’m using Grafana 4.2.0 and Elasticsearch in 6.3.2 and getting the exact same error. Actually I can only use the count and Unique Count Metrics.

not sure if it would be similar for your case, but we’re no longer getting this error as of upgrading to Grafana v5.1.3, so I think there may be a compatibility issue somewhere with Grafana v4.x and ElasticSearch v6.x

Yes definitively a compability issue, I updated to grafana 5.2.2 and it work’s.