一、kibana简介
Kibana 核心产品搭载了一批经典功能:柱状图、线状图、饼图、旭日图,等等。
Kibana 开发工具为开发人员提供了多种强大方法来帮助其与 Elastic Stack 进行交互。
四、启用xpack安全验证
集群模式需要先在server1创建证书:
# cd /usr/share/elasticsearch/
# bin/elasticsearch-certutil ca
# bin/elasticsearch-certutil cert --ca elastic-stack-ca.p12
# cp elastic-certificates.p12 elastic-stack-ca.p12 /etc/elasticsearch
# chown elasticsearch elastic-certificates.p12 elastic-stack-ca.p12
server2和server3上接受证书并改所有者
scp elastic-certificates.p12 elastic-stack-ca.p12 server2:/etc/elasticsearch
chown elasticsearch elastic-certificates.p12 elastic-stack-ca.p12
scp elastic-certificates.p12 elastic-stack-ca.p12 server3:/etc/elasticsearch
chown elasticsearch elastic-certificates.p12 elastic-stack-ca.p12
配置所有的elasticsearch集群节点:
# vim /etc/elasticsearch/elasticsearch.yml
xpack.security.enabled: true
xpack.security.transport.ssl.enabled: true
xpack.security.transport.ssl.verification_mode: certificate
xpack.security.transport.ssl.keystore.path: /etc/elasticsearch/elastic-certificates.p12
xpack.security.transport.ssl.truststore.path: /etc/elasticsearch/elastic-certificates.p12
ES集群重启正常后,设置用户密码:
设置kibana连接ES的用户密码:
# vim /etc/kibana/kibana.yml
elasticsearch.username: "kibana"
elasticsearch.password: "westos"
设置Logstash连接ES用户密码:
output {
elasticsearch {
hosts => "172.25.0.13:9200"
index => "apachelog-%{+YYYY.MM.dd}"
user => "elastic"
password => "westos"
}
}
head访问:http://172.25.0.13:9100/?auth_user=elastic&auth_password=westos