Install Zabbix Server using Docker in Less than 2 Minutes!

Install Zabbix Server using Docker in Less than 2 Minutes!

Setting up a robust monitoring solution for your infrastructure doesn't have to be a time-consuming task. With Zabbix, you can monitor your servers, applications, and network devices seamlessly.

In this guide, we’ll show you how to install the Zabbix Server, Frontend, Database, and Java Gateway on a CentOS Linux machine in just 2 minutes!

Requirements ?

Before we dive into the installation, ensure you have the following prerequisites:

  1. Docker You need Docker installed on your CentOS machine. For detailed installation instructions, refer to the official Docker installation guide for CentOS.
  2. Git: Git is required to clone the installation repository.

Download Zabbix Installation Script ??

Once you have Docker and Git installed, you can proceed to download the Zabbix installation script.

Clone the Repository

Run the following command to clone the Zabbix installation repository:

git clone https://github.com/karthick-dkk/zabbix-karthick_dk.gitCopy code        

Allow Permissions ??

Before running the installation script, you need to grant execution permissions:

chmod u+x zabbix-karthick_dk/zabbix_installation.shCopy code        

Run the Installation Script ??♂?

Now, you can execute the installation script to set up Zabbix:

zabbix-karthick_dk/zabbix_installation.sh        

Access the Zabbix Frontend

Once the installation is complete, you can access the Zabbix frontend using the following URL:

  • URL: https://localhost:8080 (or replace localhost with your server's IP address)
  • User: Admin
  • Password: zabbix

Note ??

Ensure that port 8080 is open on your machine or firewall to allow access to the Zabbix frontend.

Install Zabbix Agent 2 on CentOS ???

To monitor your CentOS machine itself, you'll want to install the Zabbix Agent 2.

Add the Repository

Run the following command to add the Zabbix repository:

sudo rpm -Uvh https://repo.zabbix.com/zabbix/6.4/rhel/8/x86_64/zabbix-release-6.4-1.el8.noarch.rpm        

After adding the repository, clean up the package manager cache:

dnf clean all        

Download Zabbix Agent 2 ??

Install the Zabbix Agent 2 and its plugins with the following command:

dnf install zabbix-agent2 zabbix-agent2-plugin-* -y        

Start and Enable on Boot ?

Finally, start the Zabbix Agent 2 service and enable it to start on boot:

systemctl restart zabbix-agent2 && systemctl enable zabbix-agent2        

Destroy Containers and Re-run ??

If you need to remove all Zabbix containers and re-run the installation, use the following command:

./zabbix_installation remove        

Conclusion

You’ve successfully installed Zabbix on your CentOS machine in under 2 minutes! You can now monitor your servers and applications effortlessly. Don't forget to customize your Zabbix configuration to suit your monitoring needs.

Feel free to reach out if you have any questions or need further assistance with your Zabbix setup.

Happy monitoring!

Jan Panoch

Core Network Engineer at trinactka.net, Core Infrastructure Engineer at odkarla.cz

3 周
回复

要查看或添加评论,请登录

Karthick D的更多文章

社区洞察

其他会员也浏览了