IntroductionSoon I will start my internship and I received the question if I knew something about this topic. Since I do not have any experience with Zabbix I wanted to configure this server in my test lab. In this post I will configure a CentOS 6.6 machine as Zabbix Server to monitor some Windows machines. To make it even more interesting for myself I used Ansible to configure it all.
What is Zabbix?
Wikipedia: "Zabbix is an enterprise open source monitoring solution for networks and applications, created by Alexei Vladishev. It is designed to monitor and track the status of various network services, servers, and other network hardware."
- CentOS 7 Workstation to configure Ansible playbook's.
- CentOS 6.6 Minimal for Zabbix Server
- Hyper-V running Windows Server's / Zabbix Server
Prepare Server to accept Ansible Playbooks
Configure Ansible and run the Playbook
After these steps Ansible should be able to talk to our configured servers. We can test this with a single ping. The command used for this is "ansible all -m ping", this command pings all the servers in the hosts file from the previous step.
|Ansible can communicate with our other server.|
Now we have defined the path, lets make the necessary folders and files for Zabbix.
|Here we configure the right roles for our hosts.|
main.yml (task folder)
MariaDB.repo (template folder)
zabbix.conf (template folder)
zabbix_server.conf (template folder)
Running the playbook
Configure ZabbixNow open your web browser and navigate to "http://<your server ip>/zabbix".
Add Windows host
Install agent on Windows machine
|Start the service|
Now the only thing we need to to is to configure the firewall to allow traffic on port 10050. I created the following rule for this. You might want to configure it more aggressive in a production environment.