安全设置

有些设置十分的敏感, 以来文件系统的权限来保护数据是完全不够的. 为了应对这种情况, Elasticsearch提供了密钥库, 还有elasticsearch-keystore工具来管理密钥库里的设置.

所用运行这些命令的用户要和运行Elasticsearch的用户相同.

只有一部分设置设计为从keystore里读取. 查看文档获取更多信息.

所有的修改必须重启Elasticsearch才会生效

Elasticsearch keystore目前只支持混淆, 以后会加入密码保护功能

创建keystore

bin/elasticsearch-keystore create

elasticsearch.keystore 文件会在elasticsearch.yml的旁边被创建

列出keystore里的设置

bin/elasticsearch-keystore list

添加字符串设置

bin/elasticsearch-keystore add the.setting.name.to.set

命令号会提示你输入, 如果要通过stdin来跳过输入, 可以使用--stdin:

cat /file/containing/setting/value | bin/elasticsearch-keystore add --stdin the.setting.name.to.set

移除设置

cat /file/containing/setting/value | bin/elasticsearch-keystore add --stdin the.setting.name.to.set

results matching ""

    No results matching ""