How to Install and Configure Zabbix Agent on CentOS 8

How to Install and Configure Zabbix Agent on CentOS 8

On client machines, the Zabbix agent collects and sends data to the Zabbix server. As a result, in order for the server to function, all remote machines must be given with a client. Zabbix server was recently installed. We’ll walk through the steps to install and setup the Zabbix agent on CentOS 8 in this article.

Disabling SELinux

For Zabbix to perform properly, it is preferable to disable SELinux. So, open the configuration file.

$ sudo vim /etc/selinux/config

SELINUX should be turned off

SELINUX=disabled

Save and close the file before restarting the system.

Zabbix agent installation

To install the agent, first add the Zabbix repository.

rpm -Uvh https://repo.zabbix.com/zabbix/5.0/rhel/8/x86_64/zabbix-release-5.0-1.el8.noarch.rpm
dnf clean all

Let’s get the Zabbix agent package installed.

$ dnf install zabbix-agent

Now launch the service and have it start automatically when the system boots up.

$ systemctl enable --now zabbix-agent

Configuring the Zabbix agent

Open the Zabbix configuration file in a text editor.

$ vim /etc/zabbix/zabbix_agentd.conf

Determine and set the appropriate values for the following parameters:

Server=10.5.5.1
ServerActive=10.5.5.1
Hostname=client

The IP address of the Zabbix server must be included in the first two, and the Hostname is the name of the client that will appear in the server’s statistics.

The service should now be started.

$ systemctl restart zabbix-agent

Configuration of the firewall

For Zabbix to work, open the ports 10050, 10051, http, and https.

firewall-cmd --add-service={http,https} --permanent
firewall-cmd --add-port={10051/tcp,10050/tcp} --permanent
firewall-cmd --reload

Follow us TwitterFacebookLinkedIn

Open Source Listing

Previous Post
Next Post

Leave a Reply

Your email address will not be published. Required fields are marked *