Script and installation package [click to download]
4 centos7
192.168.59.130
jdk,zookeeper,kafka,filebeat, elasticsearch
192.168.59.131
jdk,zookeeper,kafka,logstash
192.168.59.132
jdk,zookeeper,kafka,kibana
192.168.59.133
one-click deployment
192.168.59.133 upload EFK script
Install ansible
yum search ansible
yum -y install centos-release-ansible-29.noarch
yum -y install ansible
Add manifest file
vim /etc/ansible/hosts
[EFK]
192.168.59.130
192.168.59.131
192.168.59.132
Do three ssh without password
ssh-keygen
ssh-copy-id root@192.168.59.130
ssh-copy-id root@192.168.59.131
ssh-copy-id root@192.168.59.132
Test the connection
ansible EFK -m ping
3 hosts modify the host name
第一台
hostnamectl set-hostname kafka1
第二台
hostnamectl set-hostname kafka2
第三台
hostnamectl set-hostname kafka3
Modify the ansible-playbook execution file
cd EFk
vim efk.yml
vim kafka.sh
vim elasticsearch.sh
vim kibana.sh
vim log_ng.sh
Perform ansible one-click deployment
ansible-playbook efk.yml
ab pressure test
ab -n100 -c100 http://192.168.59.130/
192.168.59.130 restart filebeat
systemctl restart filebeat
192.168.59.131 restart logstash
systemctl restart logstash
Web access 192.168.59.132::5601 For
other graphic settings, please refer to ELK installation and collection log blog
Script and installation package [click to download]