How to add Remote linux host on zabbix server to monitor

We have already covered in our previous article, Zabbix installation on RPM based systems such as CentOS & RHEL and Zabbix installation on DEB based systems such as Debian, Ubuntu & Mint, also refer Adding Zabbix Remote Windows Host . For Monitoring Linux/Windows hosts in Zabbix Server, We need to install Zabbix Agent to our Remote Linux/Windows systems. What Zabbix Agent does ? Zabbix Agent collects all the data such as (CPU usage, memory usage, network usage, http usage, etc…) and send the reports to Zabbix Server. Here I’m going to show your how to add remote Linux host on zabbix server to monitor

1) Install Zabbix Agent repository

You can directly download the repository configuration package from Zabbix website based on your distribution and version.

# Zabbix Agent repository For Ubuntu/Mint #
$ sudo wget http://repo.zabbix.com/zabbix/2.4/ubuntu/pool/main/z/zabbix/zabbix-agent_2.4.7-1+trusty_amd64.deb
$ sudo dpkg -i zabbix-agent_2.4.7-1+trusty_amd64.deb
$ sudo apt-get update

# Zabbix Agent repository For Debian 7 #
$ sudo wget http://repo.zabbix.com/zabbix/2.4/debian/pool/main/z/zabbix/zabbix-agent_2.4.7-1+wheezy_amd64.deb
$ sudo dpkg -i zabbix-agent_2.4.7-1+wheezy_amd64.deb
$ sudo apt-get update

# Zabbix Agent repository For Debian 8 #
$ sudo wget http://repo.zabbix.com/zabbix/2.4/debian/pool/main/z/zabbix/zabbix-agent_2.4.7-1+jessie_amd64.deb
$ sudo dpkg -i zabbix-agent_2.4.7-1+jessie_amd64.deb
$ sudo apt-get update

# Zabbix Agent repository For RHEL/CentOS 5 #
# rpm -Uvh http://repo.zabbix.com/zabbix/2.4/rhel/5/x86_64/zabbix-agent-2.4.7-1.el5.x86_64.rpm

# Zabbix Agent repository For RHEL/CentOS 6 #
# rpm -Uvh http://repo.zabbix.com/zabbix/2.4/rhel/6/x86_64/zabbix-agent-2.4.7-1.el6.x86_64.rpm

# Zabbix Agent repository For RHEL/CentOS 7 #
# rpm -Uvh http://repo.zabbix.com/zabbix/2.4/rhel/7/x86_64/zabbix-agent-2.4.7-1.el7.x86_64.rpm

2) Installing Zabbix Agent

Run the below command to install Zabbix Agent on your host.

# Install Zabbix Agent DEB based system # #
$ sudo apt-get install zabbix-agent

# Install Zabbix Agent RHEL based system #
# yum install zabbix-agent

3) Modify Zabbix Agent Configuration

Open zabbix_agentd.conf file on your favorite text editor and make below necessary changes (Add your Zabbix Server IP and add Zabbix Agent hostname) and save + Exit.

$ sudo nano /etc/zabbix/zabbix_agentd.conf
Server=192.168.1.137
Hostname=server.2daygeek.com

Restart Zabbix Agent

# For SysVinit Systeme #
# service zabbix-agent restart
or
# /etc/init.d/zabbix-agent restart

# For Systemd Systeme #
# systemctl restart zabbix-agent.service
or
# systemctl restart zabbix-agent
or
# /bin/systemctl restart zabbix-agent.service

4) Adding New host in Zabbix server

Login to Zabbix Server web interface.

Step-1

  • Go to Configuration Main menu
  • Click Hosts Sub menu
  • Then, Create Host button

linux-host-zabbix-server-monitor-4

Step-2

  • Enter your Original Host Name
  • Enter visible name which you want to show the host
  • Add Linux Servers group
  • Add Zabbix Server IP
  • Tick Enabled Check box to monitor the host
  • Click Templates

linux-host-zabbix-server-monitor-4a

Step-3

  • Click Select to add new template
  • Choose Template OS Linux because i’m going to add linux host
  • Select the Template
  • Add button to add the Template to new hosts
  • Click Update to complete the process

linux-host-zabbix-server-monitor-4b

Step-4

You can see New Linux hosted added for Monitoring.
linux-host-zabbix-server-monitor-4c
We document all the articles in-depth so that its understand by all level/stage Linux administrators. If the article was useful for you, then please spend less than a minute to share your valuable comments in our commenting section.

Please stay tuned with us…Good Luck!!

About Prakash Subramanian

Prakash Subramanian is a Linux lover and has 3.5+ years of experience in linux server administration with major Linux distribution such as (RHEL, CentOS, Ubuntu). He is currently working as a Senior L2 Linux Server administrator.

View all posts by Prakash Subramanian

7 Comments on “How to add Remote linux host on zabbix server to monitor”

Leave a Reply to siva Cancel reply

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