2016-05-11 31 views
0

我試圖在ES 2.3,Ubuntu 16.4上安裝Hunspell。Hunspell for Elasticsearch

http://download.services.openoffice.org/contrib/dictionaries/下載的壓縮,解壓縮到ES根/etc/elasticsearch。詞典位置/etc/elasticsearch/config/hunspell/cs_CZ/cs_CZ.(dic|aff)

添加新行indices.analysis.hunspell.dictionary.location: /etc/elasticsearch/etc/elasticsearch/elasticsearch.yml,但 後elasticsearch重啓還是錯誤:

Guice Exception: java.lang.IllegalArgumentException: please, put your hunspell dictionaries under config/hunspell !

回答

0

你必須把你的hunspell詞典下配置/的hunspell在elasticsearch.yml爲錯誤意味着

1

我相信你想通了現在,但這裏是安裝中的hunspell另一種方式

  1. 如果您在使用壓縮版本(不dockerized),只是下降的hunspell文件夾下的config /並重新啓動服務

  2. 如果您使用的是dockerized容器,並且您沒有更改config文件夾的默認位置(/ etc/elasticsearch),那麼只需將Hunspell刪除到/ etc/elasticsearch。如果您以某用戶身份運行(UID/GID),則不要忘記擁有該文件夾。像這樣在下面Dockerfile:

    COPY配置的/ etc/elasticsearch/

    RUN設置-ex \ & &爲路徑中\ 的/ etc/elasticsearch/\ ; \ mkdir -p「$ path」; \ chown -R elasticsearch:elasticsearch「$ path」; \ 做

相關問題