CentOS6搭建zabbix3.0

前端之家收集整理的这篇文章主要介绍了CentOS6搭建zabbix3.0前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。

1.1环境准备

[root@moban~]#cat/etc/redhat-release
CentOSrelease6.5(Final)
[root@moban~]#/etc/init.d/iptablesstop
[root@moban~]#getsebool
getsebool:SELinuxisdisabled
[root@moban~]#ifconfigeth0|awk-F"[:]+"'NR==2{print$4}'
192.168.199.10

1.2server端安装

rpm-ihvhttp://mirrors.aliyun.com/zabbix/zabbix/3.0/rhel/6/x86_64/zabbix-release-3.0-1.el6.noarch.rpm
yuminstallhttpdzabbixzabbix-serverzabbix-webzabbix-server-MysqLzabbix-web-MysqLMysqL-server-y

1.3PHP安装

rpm-ivhhttp://mirror.webtatic.com/yum/el6/latest.rpm
wget-O/etc/yum.repos.d/epel.repohttp://mirrors.aliyun.com/repo/epel-6.repo
yuminstallPHP55wPHP55w-MysqLPHP55w-commonPHP55w-gdPHP55w-mbstringPHP55w-mcryptPHP55w-develPHP55w-xmlPHP55w-bcmath-y
yumremovezabbix-server-pgsql-y
cp-R/usr/share/zabbix//var/www/html/
#这里有必要说一下zabbix3.0必须要PHP5.4以上因此需要安装特殊源,才能够安装PHP5.5

1.4MysqL配置

cp/usr/share/MysqL/my-medium.cnf/etc/my.cnf
启动MysqL
/etc/init.d/MysqLdstart
创建用户并授权
MysqL
createdatabasezabbixcharactersetutf8collateutf8_bin;
grantallonzabbix.*tozabbix@'localhost'identifiedby'123456';
flushprivileges;
exit

1.5 导入数据文件

cd/usr/share/doc/zabbix-server-MysqL-3.0.3
zcatcreate.sql.gz|MysqL-uzabbix-p123456zabbix

1.6 相关数据修改

修改PHP配置文件

vim/etc/PHP.ini
post_max_size=16M
max_execution_time=300
max_input_time=300
date.timezone=Asia/shanghai

修改zabbix_server配置文件

vim/etc/zabbix/zabbix_server.conf
修改数据库地址、数据库名、用户、密码
分别对应
DBHost=
DBName=
DBUser=
DBPassword=
DBSocket=/var/lib/MysqL/MysqL.sock

文件授权

chmod-R755/etc/zabbix/web
chown-Rapache.apache/etc/zabbix/web
启动apache&&zabbix
/etc/init.d/httpdstart
/etc/init.d/zabbix-serverstart

1.7 登录web进行安装

访问http://192.168.199.10/zabbix

wKioL1ju0QDwppGPAACzaY9ffrs150.png-wh_50

右边必须全部OK

wKioL1ju0Seg3HuFAAC2vMM18bw102.png-wh_50

wKiom1ju0SeCuugtAACSbAImYhY156.png-wh_50

wKioL1ju0SiDHLeUAAB39rm988k418.png-wh_50

wKioL1ju0SjSGWrQAACXA0yMDW0494.png-wh_50

wKiom1ju0SiAVh_cAAB6nEDfKBo224.png-wh_50

wKiom1ju0SmBkgAIAABU6Oh6eKA975.png-wh_50

至此zabbix搭建完毕,可以尽情的去玩耍它了。

原文链接:https://www.f2er.com/centos/377977.html

猜你在找的CentOS相关文章