我遇到了一个不知道如何解决的问题。
我已经在本地安装了elasticsearch和kibana版本8.7.1,并且按照本指南创建了证书: https://quachtd.com/configure-https-for-elasticsearch/
https 与 elasticsearch 配合得很好。
这是我的elasticsearch.yaml 文件:
cluster.name: my-application
xpack.security.transport.ssl.enabled: true
xpack.security.transport.ssl.verification_mode: certificate
xpack.security.transport.ssl.client_authentication: required
xpack.security.transport.ssl.keystore.path: certs/elastic-certificates.p12
xpack.security.transport.ssl.truststore.path: certs/elastic-certificates.p12
xpack.security.http.ssl.enabled: true
xpack.security.http.ssl.keystore.path: http.p12
http.host: 0.0.0.0
这是我的 kibana.yaml 文件:
elasticsearch.username: "kibana_system"
elasticsearch.password: "3tWlx_uMNAemfyh5YUN="
elasticsearch.ssl.certificateAuthorities: ["C:\\kibana-8.7.1\\config\\elasticsearch-ca.pem"]
.pem 文件位于指定的配置文件夹中。但是,当我启动 kibana 并尝试导航到它时,我在控制台中收到此错误:
[2023-05-25T12:18:10.127+02:00][ERROR][elasticsearch-service] Unable to retrieve version information from Elasticsearch nodes. security_exception
Root causes:
security_exception: unable to authenticate user [kibana_system] for REST request [/_nodes?filter_path=nodes.*.version%2Cnodes.*.http.publish_address%2Cnodes.*.ip]
但是我可以通过curl验证用户身份:
$ curl -u kibana_system:3tWlx_uMNAemfyh5YUN= -k https://localhost:9200/_security/_authenticate
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 273 100 273 0 0 1418 0 --:--:-- --:--:-- --:--:-- 1421{"username":"kibana_system","roles":["kibana_system"],"full_name":null,"email":null,"metadata":{"_reserved":true},"enabled":true,"authentication_realm":{"name":"reserved","type":"reserved"},"lookup_realm":{"name":"reserved","type":"reserved"},"authentication_type":"realm"}
如果有人有任何可以帮助我的想法,我将不胜感激。
你找到答案了吗?我和你有同样的问题