标签:httpd inux selinux char 主机 gpg rest 相关配置 eve
1、时间同步、配置主机名/解析、SELinux/firewalld关闭
2、配置zabbix运行环境
[root@zabbix-server ~]# cat /etc/yum.repos.d/cent.repo
[root@zabbix-server ~]# cat /etc/yum.repos.d/centos.repo
[centos]
name=centos
baseurl=ftp://172.16.8.100/centos7u2
enabled=1
gpgcheck=0
[zabbix]
name=zabbix
baseurl=file:///zabbix
enabled=1
gpgcheck=0
[root@zabbix-server ~]# yum install -y httpd mariadb mariadb-server mariadb-devel libdbi-dbd-mysql net-snmp net-snmp-devel net-snmp-utils curl-devel mod_ssl mod_auth_mysql mod_perl
[root@zabbix-server ~]# systemctl start httpd
[root@zabbix-server ~]# systemctl enable httpd
[root@zabbix-server ~]# systemctl start mariadb
[root@zabbix-server ~]# systemctl enable mariadb
[root@zabbix-server ~]# yum install -y zabbix-server-mysql zabbix-web zabbix-web-mysql
mysql> CREATE DATABASE zabbix CHARACTER SET utf8;
mysql> GRANT all ON zabbix.* TO ‘zabbixuser‘@‘localhost‘ IDENTIFIED BY ‘redhat‘;
mysql> FLUSH PRIVILEGES;
[root@zabbix-server ~]# cd /usr/share/doc/zabbix-server-mysql-3.2.1/
[root@zabbix-server zabbix-server-mysql-3.2.1]# zcat create.sql.gz | mysql -u root -p zabbix
登陆mysql查询是否登陆成功(127张表)
7) 在zabbix_server.conf文件中编辑数据库相关配置
[root@server ~]# vim /etc/zabbix/zabbix_server.conf
DBHost=localhost
DBName=zabbix
DBUser=zabbixuser
DBPassword=redhat
DBSocket=/var/lib/mysql/mysql.sock
8) 启动Zabbix Server并配置其开机启动
[root@zabbix-server ~]# systemctl start zabbix-server
[root@zabbix-server ~]# systemctl enable zabbix-server
[root@server ~]# netstat -antp | grep zabbix
tcp 0 0 0.0.0.0:10051 0.0.0.0:* LISTEN 5909/zabbix_server
tcp 0 0 :::10051 ::?? LISTEN 5909/zabbix_server
[root@server ~]#
[root@zabbix-server zabbix-web-3.2.1]# vim /etc/httpd/conf.d/zabbix.conf
php_value date.timezone Asia/Shanghai
[root@zabbix-server ~]# systemctl restart httpd
标签:httpd inux selinux char 主机 gpg rest 相关配置 eve
原文地址:https://www.cnblogs.com/huoxc/p/12899803.html