Zabbix 3.0 installation, zabbix3.0
Zabbix3.0 Installation notes:
1. PHP version 5.4 or later. 2. Firewall shutdown. 3. selinux shutdown. Step 1. install PHP and add the epel source.
# rpm -Uvh http://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
Add remi Source
# rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm
Install PHP
# yum --enablerepo=remi,remi-php55 install php-fpm php-common php-devel php-mysqlnd php-mbstring php-mcrypt
View PHP version
# php -vPHP 5.5.9 (cli) (built: Feb 11 2014 08:25:33) Copyright (c) 1997-2014 The PHP GroupZend Engine v2.5.0, Copyright (c) 1998-2014 Zend Technologies
Ii. Install mysql
Install Mysql
yum -y install mysql-server mysql
Create zabbix Library
create database zabbix
Create and authorize a user
grant all on zabbix.* to zabbix@“%” identified by ‘zabbix’;
3. Install zabbix
Install plug-ins
yum -y install mysql-devel libxml2-devel net-snmp-devel libcurl-devel
1. Download The zabbix 3.0 package
wget https://sourceforge.net/projects/zabbix/files/ZABBIX%20Latest%20Stable/3.0.1/zabbix-3.0.1.tar.gz/download --no-check-certificate
tar xf zabbix-3.0.1.tar.gz
cd zabbix-3.0.1
groupadd zabbix
useradd -g zabbix zabbix
./configure --prefix=/usr/local/zabbix-server --enable-server --with-mysql --with-net-snmp --with-libcurl --with-libxml2
make install
2. Edit the configuration file and start:
Logs are stored in the/tmp directory by default.
Vim/usr/local/zabbix-server/etc/zabbix_server.conf
------------------------------------------------------------->
DBHost = localhost
DBName = zabbix
DBUser = zabbix
DBPassword = zabbix
ListenIP = 127.0.0.1
<-------------------------------------------------------------
/Usr/local/zabbix-server/sbin/zabbix_server-c/usr/local/zabbix-server/etc/zabbix_server.conf // start the service
Check the port and start listening:
3. Copy the zabbix application to the WEB root directory.
cd zabbix-3.0.1/frontends/php/
cp -a . /var/www/html/zabbix/
chown -R apache.apache /var/www/html/zabbix/*
4. Configure php and start httpd:
Vim/etc/php. ini
----------------------------------------->
Date. timezone = Asia/Shanghai
Post_max_size = 16 M
Max_execution_time= 300
Max_input_time= 300
----------------------------------------->
Service httpd start
Access http: // 192.168.19.76/zabbix in a browser and follow the prompts to install:
During database connection operations
The frontend does not match Zabbix database. Current database version (mandatory/optional): 2050061/2050061. Required mandatory version: 3000000. Contact your system administrator.
In this case, you need to delete the created zabbix library and then import the zabbix library file again.
The permission error is reported. Download the configuration file and save it to the/var/www/html/zabbix/conf/zabbix. conf. php file. If an error is returned after the configuration file is manually written, you can ignore it. Close the browser and re-open the connection. Log on to the admin account with the logon password zabbix:
Vim/var/www/html/zabbix/conf/zabbix. conf. php // manually write the configuration
---------------------------------------------------------->
<? Php
// Zabbix GUI configuration file.
Global $ DB;
$ DB ['type'] = 'mysql ';
$ DB ['server'] = '192. 0.0.1 ';
$ DB ['Port'] = '0 ';
$ DB ['database'] = 'zabbix ';
$ DB ['user'] = 'zabbix ';
$ DB ['Password'] = 'zabbix ';
// Schema name. Used for IBM DB2 and PostgreSQL.
$ DB ['scheme'] = '';
$ ZBX_SERVER = '2017. 0.0.1 ';
$ ZBX_SERVER_PORT = '123 ';
$ ZBX_SERVER_NAME = '';
$ IMAGE_FORMAT_DEFAULT = IMAGE_FORMAT_PNG;
?>
4. Enable Chinese support for zabbix
In the past, zabbix disabled Chinese support by default. We need to modify the php source file of zabbix. Modify the include/locales. inc. php file under the root directory of the site.
- # Vim include/locales. inc. php
- Function getLocales (){
- Return array (
- 'En _ gb' => array ('name' => _ ('English (en_GB) '), 'display' => true ),
- 'En _ us' => array ('name' => _ ('English (en_US) '), 'display' => true ),
- 'Bg _ bg '=> array ('name' => _ ('Bulgarian (bg_BG)'), 'display' => true ),
- 'Zh _ cn' => array ('name' => _ ('Chinese (zh_CN) '), 'display' => true ),
- // The original value is false. Change it to true.
- ...... The code is omitted ........
- );
- }