Before the zabbix3.0, but because the matter is put aside, record the convenience of their own later use.
Centos7 Install zabbix3.0.3 Check if SELinux is turned off
[Email protected] ~]# getenforcedisabled
If it is not closed, it can be used setenforce 0
to close the operation, but it is temporarily closed.
Check if FIREWALLD is turned off
[[email protected] ~]# systemctl stop firewalld.service[[email protected] ~]# systemctl disable Firewalld.service
MARIADB Installation
Repo source
[[email protected] ~]# Cat/etc/yum.repos.d/mariadb.repo # MariaDB 10.1 CentOS repository list-created 2016-05-12 09:28 utc# http://mariadb.org/mariadb/repositories/[mariadb]name = Mariadbbaseurl = HTTP://YUM.MARIADB.ORG/10.1/ Centos7-amd64gpgkey=https://yum.mariadb.org/rpm-gpg-key-mariadbgpgcheck=1
Installing MARIADB
[email protected] ~]# Yum install mariadb-server mariadb-client-y
In a production environment, use mysql_secure_installation
the Initialize operation
Start the MARIADB service
[[email protected] ~]# systemctl start mariadb.service[[email protected] ~ ]# ss -ntpl|grep mysqllisten 0 80 :::3306 :::* users: (("Mysqld", 3360,17))
MariaDB [(None)]> CREATE database Zabbix character set UTF8 collate utf8_bin; Query OK, 1 row Affected (0.00 sec) MariaDB [(none)]> grant all privileges on zabbix.* to [email protected] identified By ' Zabbix '; Query OK, 0 rows Affected (0.00 sec) MariaDB [(none)]> flush privileges; Query OK, 0 rows Affected (0.00 sec)
Installing the Zabbix repo source
Download Zabbix Repo source
[Email protected] ~]# wget http://repo.zabbix.com/zabbix/3.0/rhel/7/x86_64/zabbix-release-3.0-1.el7.noarch.rpm
Installing the Zabbix repo source
[Email protected] ~]# RPM-IVH zabbix-release-3.0-1.el7.noarch.rpmwarning:zabbix-release-3.0-1.el7.noarch.rpm: Header V4 dsa/sha1 Signature, key ID 79ea5ed4:nokeypreparing ... ################################ # [100%]updating/installing ... 1:zabbix-release-3.0-1.el7 ################################# [100%]
Installation Zabbix premise operation
Installing the Zabbix Component
[email protected] ~]# Yum install zabbix-server-mysql zabbix-web-mysql-y
Import SQL file
[[email protected] ~]# cd /usr/share/doc/zabbix-server-mysql-3.0.3/[[email protected] zabbix-server-mysql-3.0.3]# lltotal 1832-rw-r--r-- 1 root root 98 May 18 20:59 AUTHORS-rw-r--r-- 1 root root 682098 May 18 20:59 ChangeLog-rw-r--r-- 1 root root 17990 may 18 20:59 copying-rw-r--r-- 1 root root 1158948 may 23 16:56 create.sql.gz-rw-r--r-- 1 root root 52 May 18 20:59 NEWS-rw-r--r-- 1 root root 188 may 18 20:59 readme [[email protected] zabbix-server-mysql-3.0.3] # gunzip create.sql.gz[[email protected] zabbix-server-mysql-3.0.3]# mysql - Uzabbix -p zabbiX < create.sqlenter password:
Replace the timezone time zone with Shanghai
View TimeZone
[[email protected] ~]# grep "timezone"/etc/httpd/conf.d/zabbix.conf # php_value Date.timezone Europe/riga
SED replacement
[Email protected] ~]# sed-i ' [email protected]# php_value date.timezone europe/[email protected]_value date.timezone Asi A/[email protected] '/etc/httpd/conf.d/zabbix.conf
See if replace
[[email protected] ~]# grep "timezone"/etc/httpd/conf.d/zabbix.conf php_value date.timezone Asia/shanghai
Modifying the Zabbix-server configuration file
[Email protected] ~]# egrep-v "^#|^$"/etc/zabbix/zabbix_server.conf logfile=/var/log/zabbix/zabbix_ Server.loglogfilesize=0pidfile=/var/run/zabbix/zabbix_server.piddbhost=localhostdbname=zabbixdbuser= Zabbixdbpassword=zabbixdbport=3306snmptrapperfile=/var/log/snmptrap/snmptrap.logtimeout=4alertscriptspath=/usr /lib/zabbix/alertscriptsexternalscripts=/usr/lib/zabbix/externalscriptslogslowqueries=3000
Start httpd, Zabbix-server service
Start Service Command
[[email protected] ~]# systemctl start httpd.service[[email protected] ~]# systemctl start zabbix-server
Installing Zabbix
http://ip/zabbix can
650) this.width=650; src=/e/u261/themes/default/images/spacer.gif "Title=" "style=" Background:url ("/e/u261/lang/zh-cn/images/localimage.png") no-repeat center;border:1px solid #ddd; " alt= "Spacer.gif"/>
650) this.width=650; "src="/e/u261/themes/default/images/spacer.gif "title=" "style=" Background:url ("/e/u261/lang/ Zh-cn/images/localimage.png ") no-repeat center;border:1px solid #ddd;" alt= "Spacer.gif"/>
650) this.width=650; "Src=" Http://s1.51cto.com/wyfs02/M02/83/C5/wKioL1d7wN_ioX8kAACn981Ma5w602.png-wh_500x0-wm_3 -wmp_4-s_387579954.png "style=" Float:none; "title=" 1.png "alt=" Wkiol1d7wn_iox8kaacn981ma5w602.png-wh_50 "/>
650) this.width=650; "Src=" Http://s3.51cto.com/wyfs02/M02/83/C6/wKiom1d7wOCDse1-AADUcY1deo8211.png-wh_500x0-wm_3 -wmp_4-s_3780692294.png "style=" Float:none; "title=" 2.png "alt=" Wkiom1d7wocdse1-aaducy1deo8211.png-wh_50 "/>
650) this.width=650; "Src=" Http://s3.51cto.com/wyfs02/M00/83/C5/wKioL1d7wOCCVc6pAAC6W44Nzcc151.png-wh_500x0-wm_3 -wmp_4-s_1894210506.png "style=" Float:none; "title=" 3.png "alt=" Wkiol1d7woccvc6paac6w44nzcc151.png-wh_50 "/>
650) this.width=650; "Src=" Http://s3.51cto.com/wyfs02/M02/83/C5/wKioL1d7wODjVtGpAACxcqEkKa0206.png-wh_500x0-wm_3 -wmp_4-s_795252469.png "style=" Float:none; "title=" 4.png "alt=" Wkiol1d7wodjvtgpaacxcqekka0206.png-wh_50 "/>
650) this.width=650; "Src=" Http://s3.51cto.com/wyfs02/M02/83/C6/wKiom1d7wOGSIbC2AADXSEdx-yU719.png-wh_500x0-wm_3 -wmp_4-s_120659340.png "style=" Float:none; "title=" 5.png "alt=" Wkiom1d7wogsibc2aadxsedx-yu719.png-wh_50 "/>
650) this.width=650; "Src=" Http://s3.51cto.com/wyfs02/M00/83/C5/wKioL1d7wOHiaRwZAACnZjvcWOs505.png-wh_500x0-wm_3 -wmp_4-s_3106869075.png "style=" Float:none; "title=" 6.png "alt=" Wkiol1d7wohiarwzaacnzjvcwos505.png-wh_50 "/>
650) this.width=650; "Src=" Http://s2.51cto.com/wyfs02/M00/83/C6/wKiom1d7wOLD93ZhAACKg35L88s342.png-wh_500x0-wm_3 -wmp_4-s_293956122.png "style=" Float:none; "title=" 7.png "alt=" Wkiom1d7wold93zhaackg35l88s342.png-wh_50 "/>
650) this.width=650; "Src=" Http://s4.51cto.com/wyfs02/M01/83/C5/wKioL1d7wOLB4vmCAAFA6PPd6vo917.png-wh_500x0-wm_3 -wmp_4-s_4226272106.png "style=" Float:none; "title=" 8.png "alt=" Wkiol1d7wolb4vmcaafa6ppd6vo917.png-wh_50 "/>
650) this.width=650; "src="/e/u261/themes/default/images/spacer.gif "title=" "style=" Background:url ("/e/u261/lang/ Zh-cn/images/localimage.png ") no-repeat center;border:1px solid #ddd;" alt= "Spacer.gif"/> The above is the zabbix3.0.3 installation process, uh, first.
Problems encountered during the installation
[Email protected] ~]# systemctl start zabbix-serverjob for Zabbix-server.service failed. See ' systemctl status Zabbix-server.service ' and ' journalctl-xn ' for details.
First check if SELinux is off, shut down, and install the following two software. Start the Zabbix-server service again to start the success.
[email protected] ~]# Yum install trousers gnutls-y
This article is from the "Village Boys" blog, please make sure to keep this source http://noodle.blog.51cto.com/2925423/1796105
CENTOS7 installation zabbix3.0.3