Zabbix 3.0.0beta1 Installing the-centos6.8 version

Source: Internet
Author: User
Tags snmp import database

Zabbix 3.0 Installation

Zabbix minimum required MySQL 5.5 php5.3

Query MySQL version
Yum List Installed | grep MySQL
# #mysql-libs.x86_64 5.1.73-5.el6_6 @anaconda-centos-201508042137.x86_64/6.7

Uninstall MySQL
Yum Remove mysql*

Specify MySQL Source
RPM-IVH http://dev.mysql.com/get/mysql-community-release-el6-5.noarch.rpm

Install MySQL
Yum Install Mysql-server

Install the Vim text editor
Yum Install Vim-y

Modify MySQL Configuration
Vim/etc/my.cnf

[Mysqld]
Innodb_file_per_table

Start the MySQL service
Service mysqld Start

Update configuration
Mysql_secure_installation
Enter current password to root (enter for none):

Set root Password? [y/n]

Remove anonymous users? [y/n]

Disallow Root login remotely? [y/n]

Remove test database and access to it? [y/n]

Reload privilege tables now? [y/n]

Log in to MySQL database
Mysql-u root-p

Create a Zabbix database
CREATE DATABASE Zabbix CHARACTER SET UTF8 COLLATE utf8_bin;
Authorizing the Zabbix system to access the MySQL database user and password:
GRANT all privileges the zabbix.* to [e-mail protected] identified by ' Zabbix ';

Querying database Information
mysql> show databases;
+--------------------+
Database
+--------------------+
Information_schema
Mysql
Performance_schema
Zabbix
+--------------------+
4 rows in Set (0.00 sec)
If everything is fine then exit the database for now.

Exit

Zabbix 3.0 requires PHP to is at least version 5.4 or higher. Our CentOS 6.7 repositories come and PHP 5.3.3 therefore we need to install a newer one.

Specify Zabbix Source
RPM-IVH http://repo.webtatic.com/yum/el6/latest.rpm

Install support libraries such as PHP
Yum install httpd php56w php56w-gd php56w-mysql php56w-bcmath php56w-mbstring php56w-xml php56w-ldap

Edit PHP Configuration
Vim/etc/php.ini
post_max_size=16m
max_execution_time=300
max_input_time=300
Date.timezone=europe/riga
Always_populate_raw_post_data=-1

Launch Apache Service
Service httpd Start

Firewall Release 80 port
Iptables-i input-p TCP--dport 80-m State--state new,established-j ACCEPT
Iptables-save >/etc/sysconfig/iptables
Querying firewalls
IP A

Create Zabbix User
Groupadd Zabbix
Useradd-g Zabbix Zabbix

Create a Zabbix download path and enter
Mkdir/home/zabbix/downloads
Cd/home/zabbix/downloads

Installing the wget download tool
Yum Install Wget-y

Download Zabbix3.0gz Package
wget "Https://sourceforge.net/projects/zabbix/files/ZABBIX Latest development/3.0.0beta1/zabbix-3.0.0beta1.tar.gz "
wget "Https://sourceforge.net/projects/zabbix/files/ZABBIX Latest development/3.0.0alpha2/ Zabbix-3.0.0alpha2.tar.gz "
Extract
TAR-ZXVF zabbix-3.0.0beta1.tar.gz

Import Database
Cd/home/zabbix/downloads/zabbix-3.0.0beta1/database/mysql
Mysql-u Zabbix-p Zabbix < Schema.sql
Mysql-u Zabbix-p Zabbix < Images.sql
Mysql-u Zabbix-p Zabbix < Data.sql

Installing dependent libraries
Yum install gcc mysql-community-devel libxml2-devel unixodbc-devel net-snmp-devel libcurl-devel libssh2-devel Openipmi-devel Openssl-devel Openldap-devel

Cd.. /..
View Compilation Help
./configure--help
Configure all and required for Zabbix.
Compile
./configure--enable-server--enable-agent--with-mysql--enable-ipv6--with-net-snmp--with-libcurl--WITH-LIBXML2-- With-unixodbc--with-ssh2--WITH-OPENIPMI--with-openssl
Installing Zabbix
Make install

Configure Zabbix-server
Vim/usr/local/etc/zabbix_server.conf

Dbname=zabbix
Dbuser=zabbix
Dbpassword=your_password

Create a service path
Mkdir/var/www/html/zabbix
cd/home/zabbix/downloads/zabbix-3.0.0beta1/frontends/php/

Cp-a. /var/www/html/zabbix/

Create a rule to allow our Web server to access the front-end files.
CHCON-RV--type=httpd_sys_content_t/var/www/html

SELinux does not turn off grant permissions
Setsebool-p httpd_can_network_connect=1
Setsebool-p zabbix_can_network=1
Set Apache User as owner of the Web interface files.

granting permissions
Chown-r Apache:apache/var/www/html/zabbix
chmod +x/var/www/html/zabbix/conf/

Copy data
Cp/home/zabbix/downloads/zabbix-3.0.0beta1/misc/init.d/fedora/core/zabbix_server/etc/init.d/zabbix_server
Cp/home/zabbix/downloads/zabbix-3.0.0beta1/misc/init.d/fedora/core/zabbix_agentd/etc/init.d/zabbix_agentd
ADD Zabbix Server and Zabbix agent as services.

Self-booting
Chkconfig--add/etc/init.d/zabbix_server
Chkconfig--add/etc/init.d/zabbix_agentd
Chkconfig httpd on
Chkconfig mysqld on
Chkconfig Zabbix_server on
Chkconfig Zabbix_agentd on

Start the service
Service Zabbix_server Start
Service Zabbix_agentd Start

# # # #修改中文支持

Open Chinese support
locales.inc.php
' zhCN ' = = [' name ' = = (' Chinese (zh_cn) '), ' display ' = True]

Solve Chinese garbled characters
defines.inc.php
#修改第93行
Define (' Zbx_font_name ', ' msyh ');
#修改第45行改为
Define (' Zbx_graph_font_name ', ' msyh ')

Zabbix 3.0.0beta1 Installing the-centos6.8 version

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.