Zabbix Source Download: http://www.zabbix.com/download.php, take "Zabbix 2.2 LTS" as an example.
zabbix2.2 Official Installation Guide: Https://www.zabbix.com/documentation/2.2/doku.php?id=manual/installation/install
Create an Account
- Groupadd zabbixuseradd-g Zabbix Zabbix
Lamp Environment Construction:
Make sure that PHP supports the required extensions, such as:--with-mysql, if the phpinfo () information is--without-mysql, the front end cannot support the MySQL database.
PHP Databases Support:postgresql
The relevant environmental requirements are subject to the official website:
Https://www.zabbix.com/documentation/2.2/manual/installation/requirements
Source Configuration
The server and agent are installed on the same machine:
./configure--prefix=/usr/local/zabbix--enable-server--enable-agent--with-mysql--with-net-snmp--with-libcurl-- With-libxml2
Error encountered: Unable to find Net-snmp-config
Install dependency package: Yum install-y net-snmp-devel
If Ubuntu system: Apt-get install Libsnmp-dev SNMP
Common error: http://os.51cto.com/art/201104/252988.htm
To configure success information:
***********************************************************
* Now run ' make install ' *
* *
* Thank for using zabbix! *
* ***********************************************************
Source code Compilation
Follow the prompts to run: make; Make install
To check and modify the configuration file:
/usr/local/zabbix/etc/zabbix_agent.conf
Specify server=ip on all agents
/usr/local/zabbix/etc/zabbix_server.conf
Specify options for database-related configuration:
Dbname=zabbix
Dbuser=zabbix
Dbpassword=zabbix
Dbsocket=/tmp/mysql.sock
Add the following configuration to the/etc/httpd/conf.d/zabbix.conf configuration file, for example:
<directory "/var/www/html/zabbix" >
Options FollowSymLinks
AllowOverride None
Order Allow,deny
Allow from all
Php_value Max_execution_time 300
Php_value Memory_limit 128M
Php_value post_max_size 16M
Php_value upload_max_filesize 2M
Php_value Max_input_time 300
Php_value Date.timezone Asia/hong_kong
</Directory>
The settings for the time zone are based on the actual system, with the relevant configuration file:
/etc/localtime
/usr/share/zoneinfo/asia/hong_kong
Create DATABASE: https://www.zabbix.com/documentation/2.2/manual/appendix/install/db_scripts
Shell> mysql-u<username>-p<password>
Mysql> CREATE database Zabbix character set UTF8 collate utf8_bin;
Mysql> GRANT all privileges on zabbix.* to [email protected] '% ' identified by ' Zabbix ';
Mysql> quit;
Shell> CD Zabbix-2.2.7/database/mysql
shell> mysql-u<username>-p<password> Zabbix < Database/mysql/schema.sql
# Stop here if is creating database for Zabbix Proxy
shell> mysql-u<username>-p<password> Zabbix < Database/mysql/images.sql
shell> mysql-u<username>-p<password> Zabbix < Database/mysql/data.sql
7zabbix front-end access Http://IP/zabbix; configure as prompted. 9
This article is from the "Moagan" blog, make sure to keep this source http://brucemj.blog.51cto.com/3319384/1587614
Zabbix Source Installation