您当前的位置: 首页 > 

qq_34412985

暂无认证

  • 0浏览

    0关注

    1061博文

    0收益

  • 0浏览

    0点赞

    0打赏

    0留言

私信
关注
热门博文

"reason":"Fielddata is disabled on text fields by default. Set fielddata=true on [dataFlag] in order

qq_34412985 发布时间:2019-12-14 19:02:17 ,浏览量:0

{"error":{"root_cause":[{"type":"illegal_argument_exception","reason":"Fielddata is disabled on text fields by default. Set fielddata=true on [dataFlag] in order to load fielddata in memory by uninverting the inverted index. Note that this can however use significant memory. Alternatively use a keyword field instead."},{"type":"query_shard_exception","reason":"No mapping found for [dataFlag] in order to sort on","index_uuid":"21KE44G_Qhaybnjiga6Inw","index":"standard"},{"type":"query_shard_exception","reason":"No mapping found for [dataFlag] in order to sort on","index_uuid":"pybKDZDoRw2fWY4XDE-1Eg","index":"standard_data_item"}],"type":"search_phase_execution_exception","reason":"all shards failed","phase":"query","grouped":true,"failed_shards":[{"shard":0,"index":"checkrule","node":"MPMk7JLeSD6RpR2mfQj3Ew","reason":{"type":"illegal_argument_exception","reason":"Fielddata is disabled on text fields by default. Set fielddata=true on [dataFlag] in order to load fielddata in memory by uninverting the inverted index. Note that this can however use significant memory. Alternatively use a keyword field instead."}},{"shard":0,"index":"standard","node":"MPMk7JLeSD6RpR2mfQj3Ew","reason":{"type":"query_shard_exception","reason":"No mapping found for [dataFlag] in order to sort on","index_uuid":"21KE44G_Qhaybnjiga6Inw","index":"standard"}},{"shard":0,"index":"standard_data_item","node":"MPMk7JLeSD6RpR2mfQj3Ew","reason":{"type":"query_shard_exception","reason":"No mapping found for [dataFlag] in order to sort on","index_uuid":"pybKDZDoRw2fWY4XDE-1Eg","index":"standard_data_item"}}]},"status":400}

上述错误是说standard和中没有dataFlag的映射关系导致,先看有哪些索引,然后再看索引的映射关系

http://192.168.1.100:9210/_cat/indices

http://192.168.1.100:9210/standard/_mapping

然后发现索引中没有此字段,当然也就没有对应的映射关系,将无字段的索引删除还是报错,使用fieldName.keyword解决

关注
打赏
1653291990
查看更多评论
立即登录/注册

微信扫码登录

0.1083s