安装zabbix3.0系统环境[root@centos7 ~]# cat /etc/redhat-releaseCentOS Linux release 7.5.1804 (Core)[root@centos7 ~]# uname -r3.10.0-862.el7.x86_64[root@centos7 ~]# systemctl status firewalld● fir...
安装zabbix3.0
系统环境
[root@centos7 ~]# cat /etc/redhat-release CentOS Linux release 7.5.1804 (Core) [root@centos7 ~]# uname -r 3.10.0-862.el7.x86_64 [root@centos7 ~]# systemctl status firewalld ● firewalld.service - firewalld - dynamic firewall daemon Loaded: loaded (/usr/lib/systemd/system/firewalld.service; disabled; vendor preset: enabled) Active: inactive (dead) Docs: man:firewalld(1) [root@centos7 ~]# getenforce Disabled
如何下载zabbix服务端
官网下载地址:https://www.zabbix.com/download
zabbix服务端安装
下载
官网下载地址:https://www.zabbix.com/download
rpm -ivh https://repo.zabbix.com/zabbix/3.0/rhel/7/x86_64/zabbix-release-3.0-1.el7.noarch.rpm
为什么选择zabbix-release版本:
因为下载这个版本会在yum.repos.d下面生成一个zabbix.repo的文件
检查是否下载成功:主要检查/etc/yum.repos.d/目录中没有zabbix.repo这个文件
[root@centos7 ~]# ls /etc/yum.repos.d/ CentOS-Base.repo CentOS-Debuginfo.repo CentOS-Media.repo CentOS-Vault.repo zabbix.repo CentOS-CR.repo CentOS-fasttrack.repo CentOS-Sources.repo epel.repo
安装软件
yum install -y zabbix-server-mysql zabbix-web-mysql mariadb-server
修改PHP时区设置
sed -i.ori '18a php_value date.timezone Asia/Shanghai' /etc/httpd/conf.d/zabbix.conf
启动mysql并创建zabbix库与zabbix用户
systemctl start mariadb.service
mysql -e 'create database zabbix character set utf8 collate utf8_bin;'
mysql -e 'grant all privileges on zabbix.* to zabbix@localhost identified by "zabbix";'
导入zabbix数据至数据库
gzip -d /usr/share/doc/zabbix-server-mysql-3.0.22/create.sql.gz
mysql -uzabbix -pzabbix zabbix < /usr/share/doc/zabbix-server-mysql-3.0.22/create.sql
配置zabbix配置文件
sed -i.ori '115a DBPassword=zabbix' /etc/zabbix/zabbix_server.conf
解决中文乱码
yum -y install wqy-microhei-fonts
\cp /usr/share/fonts/wqy-microhei/wqy-microhei.ttc /usr/share/fonts/dejavu/DejaVuSans.ttf
启动服务
systemctl start zabbix-server
systemctl start httpd
浏览器访问
访问地址是:
echo "浏览器访问 http://`hostname -I|awk '{print $1}'`/zabbix"
快速安装命令
rpm -ivh https://repo.zabbix.com/zabbix/3.0/rhel/7/x86_64/zabbix-release-3.0-1.el7.noarch.rpm cat /etc/yum.repos.d/zabbix.repo yum install zabbix-server-mysql zabbix-web-mysql mariadb-server -y rpm -qa zabbix-server-mysql zabbix-web-mysql mariadb-server yum install zabbix-server-mysql zabbix-web-mysql mariadb-server -y sed -i.ori '18a php_value date.timezone Asia/Shanghai' /etc/httpd/conf.d/zabbix.conf systemctl start mariadb.service mysql -e 'create database zabbix character set utf8 collate utf8_bin;' mysql -e 'grant all privileges on zabbix.* to zabbix@localhost identified by "zabbix";' gzip -d /usr/share/doc/zabbix-server-mysql-3.0.22/create.sql.gz mysql -uzabbix -pzabbix zabbix < /usr/share/doc/zabbix-server-mysql-3.0.22/create.sql sed -i.ori '115a DBPassword=zabbix' /etc/zabbix/zabbix_server.conf yum -y install wqy-microhei-fonts \cp /usr/share/fonts/wqy-microhei/wqy-microhei.ttc /usr/share/fonts/dejavu/DejaVuSans.ttf systemctl start zabbix-server systemctl start httpd
本文标题为:centos7.5安装zabbix3.0
- 阿里云ECS排查CPU数据分析 2022-10-06
- nginx中封禁ip和允许内网ip访问的实现示例 2022-09-23
- KVM虚拟化Linux Bridge环境部署的方法步骤 2023-07-11
- 解决:apache24 安装后闪退和配置端口映射和连接超时设置 2023-09-11
- CentOS7安装GlusterFS集群的全过程 2022-10-10
- 教你在docker 中搭建 PHP8 + Apache 环境的过程 2022-10-06
- 利用Docker 运行 python 简单程序 2022-10-16
- CentOS_mini下安装docker 之 安装docker CE 2023-09-23
- IIS搭建ftp服务器的详细教程 2022-11-15
- 【转载】CentOS安装Tomcat 2023-09-24