Install the ZABBIX client with source code
I have installed ZABBIX server before. For more information, see my previous article. Install ZABBIX client now
Client installation Configuration
Download and install the client
All versions: http://www.zabbix.com/download.php. You can directly download the compiled binary file, or install the source code.
# Cd/usr/local/src
# Wget "http://downloads.sourceforge.net/project/zabbix/ZABBIX%20Latest%20Stable/2.2.2/zabbix-2.2.2.tar.gz? R = http % 3A % 2F % 2Fwww.zabbix.com % 2Fdownload. php & ts = 1395066528 & use_mirror = jaist"
# Tar-xzvf zabbix-2.2.2.tar.gz
# Cd zabbix-2.2.2
#./Configure -- prefix =/usr/local/zabbix-2.2.2/-- enable-agent
# Make
# Make install
Zabbix client Configuration
Configure the zabbix_server configuration file, under the zabbix source code directory
# Vim/usr/local/zabbix-2.2.2/etc/zabbix_agentd.conf
Server = 127.0.0.1 (note that the IP address above the client needs to be changed to the IP address of the invigilator)
ServerActive = 127.0.0.1 (note that the IP address on the client needs to be changed to the IP address of the invigilator)
Hostname = Zabbix server (the name must be the same as that configured on the invigilator)
Both Server and ServerActive specify the IP address of zabbixserver. The difference is that the former is passive and the latter is active. That is to say, the Server configuration is used to allow the ip address 127.0.0.1 to fetch data from me. ServerActive 127.0.0.1 means that the client actively submits data to him. Do you understand? Why do we need to distinguish between active and passive? We will discuss this issue later!
Add zabbix users when installing clients on other hosts.
Zabbix client startup (Be sure to create zabbix Users)
For the sake of security, zabbix only runs as a common user. If your current user is asd, then you run it as an asd. However, if you run zabbix in the root environment, zabbix will take the initiative to run zabbix. However, if your system does not have a user named zabbix, you need to create a user, as shown below:
# Groupadd zabbix
# Useradd-g zabbix
#/Usr/local/zabbix-2.2.2/sbin/zabbix_agentd
Default port 10050
Vim/etc/rc. local
Add
/Usr/local/zabbix-2.2.2/sbin/zabbix_agentd
Set Automatic startup
1. configure the firewall to enable TCP and UDP ports 10050 and 10051
Vi/etc/sysconfig/iptables # edit the firewall configuration file
-A input-s 192.168.21.127-m state -- state NEW-m tcp-p tcp -- dport 10050: 10051-j ACCEPT
-A input-s 192.168.21.127-m state -- state NEW-m udp-p udp -- dport 10050: 10051-j ACCEPT
: Wq! # Save and exit
Service iptables restart # restart the firewall to make the configuration take effect
Note: 192.168.21.127 is the IP address of the Zabbix server, indicating that the port is only open to this IP address. to open it to all IP addresses, the rules are as follows:
-A input-m state -- state NEW-m tcp-p tcp -- dport 10050: 10051-j ACCEPT
-A input-m state -- state NEW-m udp-p udp -- dport 10050: 10051-j ACCEPT
Alternatively, you can directly clear the iptables table, iptables-F, and then clear all iptables rules in/etc/init. d/iptables save.
Ii. Disable SELINUX
Vi/etc/selinux/config
# SELINUX = enforcing # comment out
# SELINUXTYPE = targeted # comment out
SELINUX = disabled # Add
: Wq! # Save and exit
Setenforce 0 # Make the configuration take effect immediately
Some Zabbix Tutorials:
Install and deploy the distributed monitoring system Zabbix 2.06
Install and deploy the distributed monitoring system Zabbix 2.06
Install and deploy Zabbix in CentOS 6.3
Zabbix distributed monitoring system practice
Under CentOS 6.3, Zabbix monitors apache server-status
Monitoring MySQL database Parameters Using Zabbix in CentOS 6.3
Install Zabbix 2.0.6 in 64-bit CentOS 6.2
ZABBIX details: click here
ZABBIX: click here
This article permanently updates the link address: