centos下安装zabbix

Posted zlfoak

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了centos下安装zabbix相关的知识,希望对你有一定的参考价值。

1. 安装mysql

CREATE DATABASE zabbix;
GRANT ALL ON zabbix.* TO ‘zabbix‘@‘192.168.19.%‘ IDENTIFIED BY ‘123456‘;
GRANT ALL ON zabbix.* TO ‘zabbix‘@‘localhost‘ IDENTIFIED BY ‘123456‘;
GRANT ALL ON zabbix.* TO ‘zabbix‘@‘mysql.jason.com‘ IDENTIFIED BY ‘123456‘;
FLUSH PRIVILEGES;

service mysqld start

2. groupadd zabbix
useradd -g zabbix zabbix

3. yum install -y curl curl-devel net-snmp snmp net-snmp-devel perl-DBI php-gd php-xml php-bcmath php-mbstring

4. 导入数据库文件:

wget http://iweb.dl.sourceforge.net/project/zabbix/ZABBIX%20Latest%20Development/3.0.0alpha2/zabbix-3.0.0alpha2.tar.gz
tar xf zabbix-3.0.0alpha2.tar.gz
cd zabbix-3.0.0alpha2/database/mysql/
/usr/local/mysql/bin/mysql -uzabbix -p123456 zabbix < schema.sql          //导入顺序不能错
/usr/local/mysql/bin/mysql -uzabbix -p123456 zabbix < images.sql
/usr/local/mysql/bin/mysql -uzabbix -p123456 zabbix < data.sql

5.编译安装参数

 ./configure --prefix=/usr/local/zabbix --enable-server --enable-agent --enable-proxy --with-mysql --enable-net-snmp --with-libcurl

make && make install

6.查看端口:

#netstart -tnlp | grep ‘zabbix’

停止zabbix服务:

 

以上是关于centos下安装zabbix的主要内容,如果未能解决你的问题,请参考以下文章

Centos7下安装及配置Zabbix3.0

Centos7下zabbix-3.2.4安装部署

Zabbix-CentOS7下zabbix的安装与配置

Centos7下zabbix安装与部署,设置中文(保姆级图文)网络工程

Centos7下yum安装zabbix的部署

centos6.5下安装zabbix4.x