gpt4 book ai didi

elasticsearch - 这些设置如何使 Elasticsearch 在开发模式下运行?

转载 作者:行者123 更新时间:2023-12-04 07:37:26 26 4
gpt4 key购买 nike

我一直在使用 Elasticsearch docker 用于测试目的的容器。我发现从我的生产服务器导入一个小数据集并将其用作测试数据更容易、更易于维护和更可靠,而不是通过其他含义来模拟响应。
我最近遇到了一个问题,我无法访问主机系统的配置设置来提升 vm.max_map_count 262144 . ES 不会启动。
因此,经过一番努力寻找替代方案后,我意识到我可以通过设置以下内容将 ES 设置为在开发模式下运行:

http.host=0.0.0.0

transport.host=127.0.0.1


通过阅读文档,我对这些参数的含义有所了解。
但仍然不清楚为什么它让 ES 运行在开发模式下。什么是限制。
有人会知道为什么吗?
提前致谢。
引用:
  • https://www.elastic.co/guide/en/elasticsearch/reference/current/docker.html
  • https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-http.html
  • 最佳答案

    此处描述:https://www.elastic.co/guide/en/elasticsearch/reference/master/system-config.html

    Development mode vs production modeBy default, Elasticsearch assumes that you are working in development mode. If any of the above settings are not configured correctly, a warning will be written to the log file, but you will be able to start and run your Elasticsearch node.

    As soon as you configure a network setting like network.host, Elasticsearch assumes that you are moving to production and will upgrade the above warnings to exceptions. These exceptions will prevent your Elasticsearch node from starting. This is an important safety measure to ensure that you will not lose data because of a malconfigured server.


    默认安装不允许集群网络(传输绑定(bind)到本地主机):

    By default, Elasticsearch binds to localhost for HTTP and transport (internal) communication. This is fine for downloading and playing with Elasticsearch, and everyday development but it’s useless for production systems. To form a cluster, Elasticsearch instances must be reachable via transport communication so they must bind transport to an external interface. Thus, we consider an Elasticsearch instance to be in development mode if it does not bind transport to an external interface (the default), and is otherwise in production mode if it does bind transport to an external interface. Note that HTTP can be configured independently of transport

    关于elasticsearch - 这些设置如何使 Elasticsearch 在开发模式下运行?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43905917/

    26 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com