ik设置远程词库remote_ext_dict无效
匿名 | 发布于2020年08月06日 | 阅读数:4872
版本:elasticseach7.3.0、ik7.3.0
------------------------
curl远程词库结果
root@Ubuntu16:~# curl http://192.168.0.193/api/ik_dict -i -XGET
HTTP/1.1 200 OK
Server: nginx
Date: Thu, 06 Aug 2020 08:59:00 GMT
Content-Type: text/plain;charset=utf-8
Transfer-Encoding: chunked
Connection: keep-alive
Vary: Accept-Encoding
Last-Modified: 2020-08-06 16:59:00
Etag: v1.0.0
放号
新入网
----------------------------------------
es加载日志
[2020-08-06T17:06:54,356][INFO ][o.w.a.d.Monitor ] [node-1] 重新加载词典...
[2020-08-06T17:06:54,357][INFO ][o.w.a.d.Monitor ] [node-1] try load config from /data/elasticsearch/config/analysis-ik/IKAnalyzer.cfg.xml
[2020-08-06T17:06:54,474][INFO ][o.w.a.d.Monitor ] [node-1] [Dict Loading] http://192.168.0.193/api/ik_dict
[2020-08-06T17:06:54,479][INFO ][o.w.a.d.Monitor ] [node-1] 重新加载词典完毕...
---------------------------------------
分词结果:
{
"tokens" : [
{
"token" : "新",
"start_offset" : 0,
"end_offset" : 1,
"type" : "CN_CHAR",
"position" : 0
},
{
"token" : "入网",
"start_offset" : 1,
"end_offset" : 3,
"type" : "CN_WORD",
"position" : 1
},
{
"token" : "放",
"start_offset" : 3,
"end_offset" : 4,
"type" : "CN_CHAR",
"position" : 2
},
{
"token" : "号",
"start_offset" : 4,
"end_offset" : 5,
"type" : "CN_CHAR",
"position" : 3
}
]
}
-------------------------------------
求教是哪里出了问题吗?
------------------------
curl远程词库结果
root@Ubuntu16:~# curl http://192.168.0.193/api/ik_dict -i -XGET
HTTP/1.1 200 OK
Server: nginx
Date: Thu, 06 Aug 2020 08:59:00 GMT
Content-Type: text/plain;charset=utf-8
Transfer-Encoding: chunked
Connection: keep-alive
Vary: Accept-Encoding
Last-Modified: 2020-08-06 16:59:00
Etag: v1.0.0
放号
新入网
----------------------------------------
es加载日志
[2020-08-06T17:06:54,356][INFO ][o.w.a.d.Monitor ] [node-1] 重新加载词典...
[2020-08-06T17:06:54,357][INFO ][o.w.a.d.Monitor ] [node-1] try load config from /data/elasticsearch/config/analysis-ik/IKAnalyzer.cfg.xml
[2020-08-06T17:06:54,474][INFO ][o.w.a.d.Monitor ] [node-1] [Dict Loading] http://192.168.0.193/api/ik_dict
[2020-08-06T17:06:54,479][INFO ][o.w.a.d.Monitor ] [node-1] 重新加载词典完毕...
---------------------------------------
分词结果:
{
"tokens" : [
{
"token" : "新",
"start_offset" : 0,
"end_offset" : 1,
"type" : "CN_CHAR",
"position" : 0
},
{
"token" : "入网",
"start_offset" : 1,
"end_offset" : 3,
"type" : "CN_WORD",
"position" : 1
},
{
"token" : "放",
"start_offset" : 3,
"end_offset" : 4,
"type" : "CN_CHAR",
"position" : 2
},
{
"token" : "号",
"start_offset" : 4,
"end_offset" : 5,
"type" : "CN_CHAR",
"position" : 3
}
]
}
-------------------------------------
求教是哪里出了问题吗?
6 个回复
f_on
赞同来自:
f_on
赞同来自:
正常出来是这样的
rockybean - Elastic Certified Engineer, ElasticStack Fans,公众号:ElasticTalk
赞同来自:
https://github.com/medcl/elast ... %2595
aw - 實習生
赞同来自:
fengzhiya
赞同来自:
Tenaxy
赞同来自: