当前位置: 首页 > 知识库问答 >
问题:

更改Path.Data后的弹性搜索,无法访问“Default.Path.Data”

左丘宜然
2023-03-14

我跟着怎么移动elasticsearch数据目录?并重新启动elasticsearch时,出现错误。

我的elasticsearch版本是ElasticSearch-5.6.1。下面是我的登录/var/log/elasticsearch

java.lang.IllegalStateException:无法在org.ellasticsearch.bootstrap.security.addPath(security.java:444)~[ellasticsearch-5.6.1.jar:5.6.1]在org.ellasticsearch.bootstrap.security.addPath(security.java:322)~[ellasticsearch-5.6.1.jar:5.6.1]在org.ellasty.java:240)~[ellasticsearch-5.6.1.jar:5.6.1]在configure(Security.java:118)~[ElasticSearch-5.6.1.jar:5.6.1]在org.ellasticSearch.bootstrap.bootstrap.setup(Bootstrap.java:228)~[ElasticSearch-5.6.1.jar:5.6.1]在org.ellasticSearch.bootstrap.bootstrap.init(Bootstrap.java:342)[ElasticSearch-5.6.1.jar:5.6.1]在org.ellasticSearch.bootstrap.bootstrap.init 1]在org.elasticsearch.bootstrap.elasticsearch.execute(elasticsearch.java:123)[elasticsearch-5.6.1.jar:5.6.1]在org.elasticsearch.cli.environmentawareCommand.execute(EnvironmentAwareCommand.java:67)[ElasticSearch-5.6.1.jar:5.6.1]在org.ellasticSearch.cli.command.mainwithoutherrorhandl(command.java:134)[ElasticSearch-5.6.1.jar:5.6.1]在org.ellasticSearch.cli.command.java:90)[ElasticSearch-5.6.1.jar:5.6.1]在org.ellasticSearch.bootstrap.ellasticSearch.main(ellasticSearch.java:91)[ElasticSearch-5.6.1]在-5.6.1.jar:5.6.1]由:java.nio.file.accessDeniedException://var/lib/ellasticSearch在sun.nio.fs.unixException.translatetoIoException(unixException.java:84)~[?:1.8.0_131]在sun.nio.fs.unixException.java:102)~[?:1.8.0_131]在sun.nio.fs.unixException.java:107)~[?:1.8.0_131]在384)~[?:1.8.0_131]位于java.nio.file.files.createDirectory(files.java:674)~[?:1.8.0_131]

经过深入研究,我找到了https://github.com/elastic/elasticsearch/issues/25265。

我想知道有没有解决这个问题的方法?还是我需要等待6.0.0版本?

共有1个答案

朱欣荣
2023-03-14

经过深究,我找到了答案。

从启动命令中删除了“-edefault.path.data=${DATA_DIR}”参数,一切又正常了。

我的环境是Ubuntu16.04,从rpm/deb安装ES。

sudo chown -R elasticsearch:elasticsearch /your/data/path
 类似资料:
  • 我不能改变本地ES索引位置-不能修改path.data。 在JournalCTL-XE中: 不幸的是,这些建议并没有帮助: 如何移动elasticsearch数据目录?;

  • 这是我的结果源看起来的样子。 {“script”:{“inline”:“ctx._source.name='Where's My Crown”“,”lang“:”painless“},”query“:{”match“:{”movie_id“:69}}} 但我有一个错误: {“type”:“illegal_argument_exception”,“reason”:“意外标记['s']应为[{,‘;’

  • 我试图使用docker容器创建一个弹性搜索安装。我只使用Elastic.io提供者的映像。 我不知道为什么,但logstash告诉我,他无法连接到带有此错误消息的ElasticSearch实例: 如果logstash真的得到了我的设置,有人能告诉我为什么他使用了一个坏的主机事件吗?

  • 我在使用Python弹性搜索访问数据时遇到了一个问题。我正在得到 尝试使用时出错 我的弹性搜索版本6.5。4,python版本3.7。2.

  • 我有以下格式的弹性搜索文档 } } 我的要求是,当我搜索特定字符串(string.string)时,我只想获得该字符串的FileOffSet(string.FileOffSet)。我该怎么做? 谢谢

  • 基数聚合计算不同值的近似计数。但是,为什么即使对于存储在单个碎片中的索引,它也显示不正确的值呢?