目录
前言
本文主要介绍在运维中常用的监控软件zabbix的安装。
Zabbix的作用:监视各种各种网络参数,保证服务器系统的安全运营;并提供灵活的通知机制以让系统管理员快速定位/解决存在的各种问题。
一、准备工作:
在VMware中安装虚拟机,这里我用的是centos7版本。
二、服务端具体步骤
1.环境准备:
cat /etc/redhat-release #查看系统版本
uname -r #查看内核版本
getenforce #检测selinux是否关闭
vi /etc/selinux/config #关闭selinux
将config中的SELINUX改为SELINUX=disabled
init 6 #重启
setenforce 0 #临时关闭
systemctl disable firewalld # 关闭防火墙开机自启动
systemctl stop firewalld #关闭防火墙
vi /etc/selinux/config中的内容为
2.安装MySQL,并初始化
1)安装数据库
yum install -y mariadb-server
systemctl start mariadb
2)设root用户密码
mysqladmin -u root password 123456
3)初始化zabbix库、表用户
mysql -u root –p123456
MariaDB [(none)]> create database zabbix character set utf8 collate utf8_bin;
MariaDB [(none)]> grant all privileges on zabbix.* to zabbix@localhost identified by 'zabbix';
MariaDB [(none)]> grant all privileges on zabbix.* to zabbix@compute identified by 'zabbix';
\q;