【问题标题】:"mapper [geo.coordinates] of different type, current_type [geo_point], merged_type [ObjectMapper]“不同类型的映射器 [geo.coordinates],current_type [geo_point],merged_type [ObjectMapper]
【发布时间】:2019-07-12 02:52:56
【问题描述】:

尝试使用教程从 Kibana 加载示例数据:https://www.elastic.co/guide/en/kibana/current/tutorial-load-dataset.html 但面临“错误”错误:{ “类型”:“非法参数异常”, "reason" : "不同类型的mapper [geo.coordinates],current_type [geo_point],merged_type [ObjectMapper]"

curl -H "Content-Type: application/x-ndjson" -XPOST "https://Kibana_username:Kibana_password@cd90859873ee41f2ba44736569855ac6.us-central1.gcp.cloud.es.io:9243/_bulk?pretty" --data-binary @logs.jsonl

{ “指数” : { "_index" : "logstash-2015.05.20", “_type”:“日志”, "_id" : "VLO5SWsB2ropsYqSYd-A", “状态”:400, “错误” : { “类型”:“非法参数异常”, “原因”:“不同类型的映射器 [geo.coordinates],current_type [geo_point],merged_type [ObjectMapper]” } } } ] }

【问题讨论】:

    标签: kibana


    【解决方案1】:

    您收到的错误是因为在您的 logs.json 版本中,内容如下所示:{"index":{"_index":"logstash-2015.05.18","_type":"log"}} 但如果您阅读了文档:

    在 Elasticsearch 6.0.0 或更高版本中创建的索引只能包含一个映射类型。在 5.x 中创建的具有多种映射类型的索引将继续像以前一样在 Elasticsearch 6.x 中发挥作用。类型将在 Elasticsearch 7.0.0 的 API 中弃用,并在 8.0.0 中完全删除。

    因此,如果您像这样更改文件内容:{"index":{"_index":"logstash-2015.05.18"}},它将正常工作。 但是在这个源文件的最新更新中,这个错误是固定的。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2016-09-09
      • 1970-01-01
      • 2019-04-17
      • 2021-04-24
      • 1970-01-01
      相关资源
      最近更新 更多