ElasticSearch 5.6 cannot start on Mac OS

前端 未结 3 1547
栀梦
栀梦 2021-02-09 03:32

I can\'t start ElasticSearch 5.6 server on Mac after installing it with Brew. Get this error:

$ /usr/local/opt/elasticsearch@5.6/bin/elasticsearch
Exception in t         


        
相关标签:
3条回答
  • 2021-02-09 04:16

    The provided answer is correct, however I would just like to add that you can just (re)start elasticsearch after removing the keyfile. It will detect that the file is absent and attempt to generate a new .keystore file automatically. No need to run the elasticsearch-keystore create command seperately.

    0 讨论(0)
  • 2021-02-09 04:28

    I just had the same issue, and regenerating the keystore fixed the problem for me. Here are the steps I took:

    Backup the existing keystore:

    cd /usr/local/etc/elasticsearch/
    mv elasticsearch.keystore elasticsearch.keystore.old
    

    Generate the new keystore:

    cd /usr/local/Cellar/elasticsearch@5.6/5.6.15/libexec/bin/
    elasticsearch-keystore create
    
    0 讨论(0)
  • 2021-02-09 04:37

    The server is most probably attempting to read a newer index (org.apache.lucene.index.IndexFormatTooNewException).

    Most probably the only way is to get rid of it completely with:

    sudo rm -rf  /usr/local/var/lib/elasticsearch
    

    Please double check the index and make sure you don't need the old 6.* index anymore, because you're obviously going to lose it.

    0 讨论(0)
提交回复
热议问题