elasticsearch - 使用 Metricbeat Keystore 但它不起作用(Metricbeat v6.6.0)?
问题描述
我正在尝试在我的 metricbeatbeat 配置中使用密钥库值,但我似乎无法让它工作......
我创建了 initContainer,因为我只是在创建密钥库并在 ES_PWD 中添加我的弹性搜索密码!
metricbeat --path.config=/usr/share/metricbeat/keystore -c /etc/metricbeat.yml keystore create
echo 'my-ES-clear-text-pwd' | metricbeat --path.config=/usr/share/metricbeat/keystore -c /etc/metricbeat.yml keystore add ES_PWD --stdin --force
metricbeat --path.config=/usr/share/metricbeat/keystore -c /etc/metricbeat.yml keystore list
[在 initContainer 和实际容器之间共享卷!]
在实际的 metricbeat 容器中尝试运行 metricbeat 服务但它没有启动。(./metricbeat --path.config=/usr/share/metricbeat/keystore -c /etc/metricbeat.yml -e)
但是 pod 正在运行,但 metricbeat 服务没有在其中启动!
如果我执行到 pod 并手动复制 metricbeat.keystore 并且如果我尝试手动运行 metricbeat 服务,那么它正在运行。
我发现了一个类似的问题:https ://discuss.elastic.co/t/using-keystores-not-working-v6-6-0/167301
但是,我无法每次都手动执行此操作,因为我的 metricbeat pod 部署为 daemonset 并部署在我的 K8s 集群中。
提前致谢。
解决方案
推荐阅读
- freeze - 使用 bcp 的存储过程挂起,但在作为脚本运行时有效
- javascript - heroku 和 nodejs 错误(Web 进程在启动后 60 秒内无法绑定到 $PORT)
- google-apps-script - 从 Google 表格的活动单元格中选择一个动态范围并隐藏
- php - 整个站点恢复后网站停止工作,PHP警告:session_start():读取会话数据失败
- html - XPath:跟随兄弟姐妹之后获取下一个
- java - Gradle:Java包名称中不允许使用关键字`cvs`
- git - 如何在 git commit 的最大更改之前插入字符串
- go - 如何以内存安全的方式获取前台应用程序的 pid?
- python - PyDrive“已超过未经身份验证使用的每日限制。继续使用需要注册”尽管已登录并已通过身份验证
- flutter - 找不到小部件键颤动测试