getenforce
setenforce 0
vim /etc/yum.repos.d/epel.repo ##如果無包則配置阿里yum源
#######################################
[epel]
name=epel
baseurl=
gpgcheck=0
############################################
yum clean all
yum install php-fpm
yum install nginx -y
yum install mysql
獲取zabbix官方yum源
rpm -ivh ##rc版本
rpm -uvh ## 正式版4.0.7
yum install php php-mysql php-gd php-bcmath php-common php-xml php-mbstring php-cli php-fpm
yum install pcre glibc gcc livevent zlib libcurl-devel curl-devel openipmi-devel libssh2 fping net-snmp-devel perl-dbi openssl-devel iksemel libxml2 ntp
yum install zabbix-agent zabbix-server-mysql zabbix-web-mysql zabbix-get zabbix-web
zabbix
配置檔案 vi /etc/zabbix/zabbix_server.conf //配置資料庫使用者及密碼
dbhost=192.168.182.130
dbname=zabbix
dbuser=zabbix
dbpassword=zabbix
資料庫建立
mysql -uroot -pmysql
mysql> create database zabbix character set utf8 collate utf8_bin;
query ok, 1 row affected (0.02 sec)
mysql> grant all on zabbix.* to 'zabbix'@'%' identified by 'zabbix';
query ok, 0 rows affected (0.01 sec)
mysql> flush privileges;
query ok, 0 rows affected (0.01 sec)
mysql> quit
bye匯入zabbbix資料庫表
zcat /usr/share/doc/zabbix-server-mysql-4.0.0/create.sql.gz | mysql -uzabbix -p -h 192.168.182.130 zabbix ##//
以上為匯入資料到資料庫
配置nginx配置檔案加入php配置關聯
############################################
proxy_buffer_size 128k;
proxy_buffers 4 256k;
proxy_busy_buffers_size 256k;
fastcgi_buffers 32 32k;
fastcgi_buffer_size 128k;
#######################################
# load modular configuration files from the /etc/nginx/conf.d directory.
# see
# for more information.
include /etc/nginx/conf.d/*.conf;
server }}
# settings for a tls enabled server.
vim /etc/php-fpm.d/www.conf ##配置php配置檔案
vim /etc/php.ini
systemctl restart php-fpm
按照
vim /etc/zabbix/zabbix_agentd.conf
# zabbix server端ip
server=127.0.0.1
# zabbix server端ip
serveractive=127.0.0.1
# zabbix客戶端主機名
hostname=zabbix server
zabbix監控平台搭建
zabbix服務端 1 安裝yum源配置檔案 rpm uvh yum clean all2 安裝服務端 前端和客戶端 yum y install zabbix server mysql zabbix web mysql zabbix agent3 初始化資料庫 mysql uroot p passw...
搭建zabbix服務
參考 本地yum源,local.repo 阿里源,ali.repo wget o ali.repo curl o ali.repoepel源,epel.repo 官方 yum install epel release y 阿里 wget o epel.repozabbix源,zabbix.repo ...
部署zabbix監控平台
bin bash author qi date 2019 6 2 email zhqlwl0121 163.com describe 部署zabbix監控平台 1.安裝lnmp環境 2.原始碼安裝zabbix 3.安裝監控端主機,修改基本配置 4.初始化zabbix監控web頁面 5.修改php配置...