centos7安装Zabbix3.4
2018-02-27 15:51
260 查看
参考网址: https://www.zabbix.com/documentation/3.4/manual/installation/install http://blog.csdn.net/mr_rsq/article/details/78457587
http://www.21yunwei.com/archives/5941 http://blog.csdn.net/yu757371316/article/details/55271762
http://blog.51cto.com/cesar/1631313
https://www.5ibc.net/centos/2572.html
下载地址: https://excellmedia.dl.sourceforge.net/project/zabbix/ZABBIX%20Latest%20Stable/3.4.7/zabbix-3.4.7.tar.gz $ tar -zxvf zabbix-3.4.7.tar.gz
yum install gcc* mysql-devel libxml2-devel net-snmp* java* curl-devel -y
yum install libevent-devel -y
yum install unixODBC-devel mysql-devel net-snmp-devel libxml2-devel libcurl-devel libevent-devel
yum install mariadb-devel
yum install -y php-mysql.x86_64 php-devel
yum install php-bcmath
configure: error: Not found mysqlclient library #yum -y install mysql-develconfigure: error: LIBXML2 library not found #yum -y install libxml2-develconfigure: error: unixODBC library not found # yum -y install unixODBC-develconfigure: error: Invalid Net-SNMP directory - unable to find net-snmp-config #yum -y install net-snmp-develconfigure: error: Invalid OPENIPMI directory - unable to find ipmiif.h #yum -y install OpenIPMI-develconfigure: error: Curl library not found #yum -y install curl-devel$ cd zabbix-3.4.7./configure --enable-server --enable-agent --with-mysql=/usr/bin/mysql_config --enable-ipv6 --enable-java --with-net-snmp --with-libcurl --with-libxml2 --with-unixodbc --with-ssh2 --with-openipmi --with-openssl --prefix=/usr/local/zabbix
make install
3 Create Zabbix database
shell> mysql -uroot -p<password>
mysql> create database zabbix character set utf8 collate utf8_bin;
mysql> grant all privileges on zabbix.* to zabbix@localhost identified by '<password>';
mysql> quit;
mysql -uroot -pbimd zabbix3 < /data/local/zabbix-3.4.7/database/mysql/schema.sql
mysql -uroot -pbimd zabbix3 < /data/local/zabbix-3.4.7/database/mysql/images.sql
mysql -uroot -pbimd zabbix3 < /data/local/zabbix-3.4.7/database/mysql/data.sql
修改配置文件zabbix_server.conf
#vi /usr/local/zabbix/etc/zabbix_server.conf
DBHost=localhost
DBName=zabbix
DBUser=zabbix
DBPassword=zabbix888
添加Zabbix服务器和Zabbix代理启动脚本
cp /data/local/zabbix-3.4.7/misc/init.d/fedora/core/zabbix_server /etc/init.d/zabbix_server
cp /data/local/zabbix-3.4.7/misc/init.d/fedora/core/zabbix_agentd /etc/init.d/zabbix_agentd
$vi /etc/init.d/zabbix_server
$vi /etc/init.d/zabbix_agentd
修改BASEDIR=/usr/local/zabbix
安装apache,php
https://www.cnblogs.com/zakun/p/5840073.html
cp -rf /data/local/zabbix-3.4.7/frontends/php /var/www/html/zabbix
cp -rf /data/local/zabbix-3.4.7/frontends/php /var/www/html/zabbix3
systemctl start httpd.service
启动所有服务,并设置开机自启
systemctl status zabbix_agentd #启动zabbix-agent服务
http://blog.csdn.net/slovyz/article/details/503493966.启动zabbix_agent#/usr/local/zabbix/sbin/zabbix_agentd查看是否启动:#netstat -tnlp | grep 'zabbix'
安装web http://www.book.com:8889/zabbix http://www.book.com:8880/zabbix3
http://www.21yunwei.com/archives/5941 http://blog.csdn.net/yu757371316/article/details/55271762
http://blog.51cto.com/cesar/1631313
https://www.5ibc.net/centos/2572.html
下载地址: https://excellmedia.dl.sourceforge.net/project/zabbix/ZABBIX%20Latest%20Stable/3.4.7/zabbix-3.4.7.tar.gz $ tar -zxvf zabbix-3.4.7.tar.gz
groupadd zabbix useradd -g zabbix zabbix#可能会出现以下的报错信息,建议直接全部安装
yum install gcc* mysql-devel libxml2-devel net-snmp* java* curl-devel -y
yum install libevent-devel -y
yum install unixODBC-devel mysql-devel net-snmp-devel libxml2-devel libcurl-devel libevent-devel
yum install mariadb-devel
yum install -y php-mysql.x86_64 php-devel
yum install php-bcmath
configure: error: Not found mysqlclient library #yum -y install mysql-develconfigure: error: LIBXML2 library not found #yum -y install libxml2-develconfigure: error: unixODBC library not found # yum -y install unixODBC-develconfigure: error: Invalid Net-SNMP directory - unable to find net-snmp-config #yum -y install net-snmp-develconfigure: error: Invalid OPENIPMI directory - unable to find ipmiif.h #yum -y install OpenIPMI-develconfigure: error: Curl library not found #yum -y install curl-devel$ cd zabbix-3.4.7./configure --enable-server --enable-agent --with-mysql=/usr/bin/mysql_config --enable-ipv6 --enable-java --with-net-snmp --with-libcurl --with-libxml2 --with-unixodbc --with-ssh2 --with-openipmi --with-openssl --prefix=/usr/local/zabbix
make install
3 Create Zabbix database
shell> mysql -uroot -p<password>
mysql> create database zabbix character set utf8 collate utf8_bin;
mysql> grant all privileges on zabbix.* to zabbix@localhost identified by '<password>';
mysql> quit;
mysql -uroot -pbimd zabbix3 < /data/local/zabbix-3.4.7/database/mysql/schema.sql
mysql -uroot -pbimd zabbix3 < /data/local/zabbix-3.4.7/database/mysql/images.sql
mysql -uroot -pbimd zabbix3 < /data/local/zabbix-3.4.7/database/mysql/data.sql
修改配置文件zabbix_server.conf
#vi /usr/local/zabbix/etc/zabbix_server.conf
DBHost=localhost
DBName=zabbix
DBUser=zabbix
DBPassword=zabbix888
添加Zabbix服务器和Zabbix代理启动脚本
cp /data/local/zabbix-3.4.7/misc/init.d/fedora/core/zabbix_server /etc/init.d/zabbix_server
cp /data/local/zabbix-3.4.7/misc/init.d/fedora/core/zabbix_agentd /etc/init.d/zabbix_agentd
$vi /etc/init.d/zabbix_server
$vi /etc/init.d/zabbix_agentd
修改BASEDIR=/usr/local/zabbix
安装apache,php
https://www.cnblogs.com/zakun/p/5840073.html
2 Installing Zabbix web interface
vi /etc/httpd/conf/httpd.conf #修改端口为8889cp -rf /data/local/zabbix-3.4.7/frontends/php /var/www/html/zabbix
cp -rf /data/local/zabbix-3.4.7/frontends/php /var/www/html/zabbix3
systemctl start httpd.service
启动所有服务,并设置开机自启
#启动Apache服务 service httpd start #启用mysql服务 service mysqld start /etc/init.d/zabbix_server start /etc/init.d/zabbix_agentd start #设置开机自启 chkconfig httpd on chkconfig mysqld on chkconfig --add /etc/init.d/zabbix_server chkconfig --add /etc/init.d/zabbix_agentd chkconfig zabbix_server on chkconfig zabbix_agentd on #查看端口号80、3306、10050(zabbix_agentd)、10051(zabbix_server)是否监听 ss -tnulsystemctl status zabbix_server #启动zabbix-server服务
systemctl status zabbix_agentd #启动zabbix-agent服务
http://blog.csdn.net/slovyz/article/details/503493966.启动zabbix_agent#/usr/local/zabbix/sbin/zabbix_agentd查看是否启动:#netstat -tnlp | grep 'zabbix'
安装web http://www.book.com:8889/zabbix http://www.book.com:8880/zabbix3
相关文章推荐
- Centos7安装Zabbix3.4
- 测试centos7安装zabbix3.4
- centos7安装zabbix3.4
- centos7 安装erlang rabbitMQ
- Redis在Centos7上的安装部署
- SpringCloud(第 057 篇)CentOS7 安装 maven 编译工具
- CentOS7安装Ant
- SuperSet CentOs7安装部署
- CentOS7安装Docker,运行Nginx镜像、Centos镜像
- centos7安装redis4集群服务
- CentOS7安装、配置PostgreSQL
- CentOS7 安装MySQL
- 解决HP服务器安装Centos7 x64无法识别硬盘
- (OK) 在CentOS7上安装Codeblocks的过程
- 安装CentOS7重启后提示License information
- centos7 安装wireshark
- CentOS7安装Hadoop2.7教程待实践。
- CentOS7下安装MySQL5.7安装与配置(YUM)
- Centos7 安装字体库&中文字体
- Win7,Ubuntu14.04 amd64下安装CentOS7三系统后无法启动CentOS7