激情久久久_欧美视频区_成人av免费_不卡视频一二三区_欧美精品在欧美一区二区少妇_欧美一区二区三区的

服務(wù)器之家:專注于服務(wù)器技術(shù)及軟件下載分享
分類導(dǎo)航

Linux|Centos|Ubuntu|系統(tǒng)進(jìn)程|Fedora|注冊表|Bios|Solaris|Windows7|Windows10|Windows11|windows server|

服務(wù)器之家 - 服務(wù)器系統(tǒng) - Centos - 詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

2022-02-28 16:51789-yankerp Centos

這篇文章主要介紹了詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟),小編覺得挺不錯的,現(xiàn)在分享給大家,也給大家做個參考。一起跟隨小編過來看看吧

zabbix簡介

zabbix簡介zabbix是完全開源的工具,整合了cacti和nagios等特性,snmp(udp 161  udp 162)眾多網(wǎng)絡(luò)工具都支持此協(xié)議,比如常見路由交換,常見os可以做管理端,也可以做被管理端,snmp大致的三個版本分為v1 v2 v3,無論是v1和v2他們的安全性還是比較差的,因為傳輸?shù)氖敲魑牡模瑅3的認(rèn)證密碼用 md5/sha摘要算法加密。

很多工具都支持網(wǎng)絡(luò)管理的功能,而對非網(wǎng)絡(luò)設(shè)備(操作系統(tǒng))可以完全拋開snmp這種不安全的架構(gòu)來實現(xiàn)監(jiān)控的,所以很多工具都是控制端和agent架構(gòu),他們有專屬的agent。

zabbix的主要功能:

具備常見的商業(yè)監(jiān)控軟件具備的功能比如:(主機性能的監(jiān)控,網(wǎng)絡(luò)設(shè)備性能的監(jiān)控,數(shù)據(jù)庫,ftp等通用協(xié)議的監(jiān)控)還具備有告警方式,詳細(xì)的報表圖表的繪制。

支持自動發(fā)現(xiàn)網(wǎng)絡(luò)設(shè)備和服務(wù)器,可以通過配置自動發(fā)現(xiàn)服務(wù)器規(guī)則來實現(xiàn),支持分布式,能集中展示,管理分布式的監(jiān)控點,擴展性強server提供通過接口(api功能)可以自己開發(fā)完善各類的監(jiān)控,根據(jù)相關(guān)接口編寫程序?qū)崿F(xiàn)編寫插件容易,可以自定義監(jiān)控項,報警級別的設(shè)置。數(shù)據(jù)收集,支持snmp(包括trapping and polling) ipmi jmx ssh telnel;

自定義的檢測;自定義收集數(shù)據(jù)的頻率;

服務(wù)器/代理和客戶端模式;靈活的觸發(fā)器;可以定義非常靈活的問題閥值,稱為觸發(fā)器,高可定制的報警,發(fā)送通過,可定制報警的升級,收件人媒體類型,cpu負(fù)荷,內(nèi)存使用,磁盤使用,網(wǎng)絡(luò)狀況,端口監(jiān)視,日志監(jiān)視等等;

硬件監(jiān)控:

  1. zabbix ipmi interface 系統(tǒng)監(jiān)控:
  2. zabbixagent interface java監(jiān)控:
  3. zabbix jmx interface 網(wǎng)絡(luò)設(shè)備監(jiān)控:
  4. zabbix snmp interface 應(yīng)用服務(wù)監(jiān)控:
  5. zabbix agent userparameter mysql數(shù)據(jù)庫監(jiān)控:percona-monitoring-plulgins   url監(jiān)控:zabbix web 監(jiān)控zabbix重要組件

說明:1)zabbix server:負(fù)責(zé)接收agent發(fā)送的報告信息的核心組件,所有配置、統(tǒng)計數(shù)據(jù)及操作數(shù)據(jù)都由它組織進(jìn)行;
2)database storage:專用于存儲所有配置信息,以及由zabbix收集的數(shù)據(jù);
3)web interface:zabbix的gui接口;
4)proxy:可選組件,常用于監(jiān)控節(jié)點很多的分布式環(huán)境中,代理server收集部分?jǐn)?shù)據(jù)轉(zhuǎn)發(fā)到server,可以減輕server的壓力;
5)agent:部署在被監(jiān)控的主機上,負(fù)責(zé)收集主機本地數(shù)據(jù)如cpu、內(nèi)存、數(shù)據(jù)庫等數(shù)據(jù)發(fā)往server端或proxy端;另外,zabbix server、proxy、agent都有自己的配置文件以及l(fā)og文件;一個監(jiān)控系統(tǒng)運行的大概的流程是這樣的:agentd需要安裝到被監(jiān)控的主機上,它負(fù)責(zé)定期收集各項數(shù)據(jù),并發(fā)送到zabbix server端,zabbix server將數(shù)據(jù)存儲到數(shù)據(jù)庫中,zabbix web根據(jù)數(shù)據(jù)在前端進(jìn)行展現(xiàn)和繪圖。

這里agentd收集數(shù)據(jù)分為主動和被動兩種模式:

主動:agent請求server獲取主動的監(jiān)控項列表,并主動將監(jiān)控項內(nèi)需要檢測的數(shù)據(jù)提交給server/proxy

被動:server向agent請求獲取監(jiān)控項的數(shù)據(jù),agent返回數(shù)據(jù)。zabbix是一個基于web界面的提供分布式系統(tǒng)監(jiān)視以及網(wǎng)絡(luò)監(jiān)視功能的企業(yè)級開源解決方案。借助zabbix,可以很輕松地減輕運維人員們繁重的服務(wù)器管理任務(wù),實現(xiàn)業(yè)務(wù)系統(tǒng)的持續(xù)運行。

下面會逐步介紹zabbix分布式監(jiān)控系統(tǒng)的部署及使用配置好ip、dns 、網(wǎng)關(guān),確保使用遠(yuǎn)程連接工具能夠連接服務(wù)器zabbix監(jiān)控服務(wù)器:192.168.146.100  #zabbix的服務(wù)端(若要監(jiān)控本機,則需要配置本機的zabbix agent)zabbix agent被監(jiān)控主機:192.168.146.110 #zabbix的客戶端(被監(jiān)控端,需要配置zabbix agent)

一、編譯安裝zabbix3.21

安裝編譯工具及庫文件

 

復(fù)制代碼 代碼如下:

yum-y install make apr* autoconf automake curl-devel gcc gcc-c++  openssl openssl-devel gd kernel keyutilspatch perl kernel-headers compat* mpfr cpp glibc libgomp libstdc++-develkeyutils-libs-devel libcom_err-devel libsepol-devel libselinux-devel krb5-develzlib-devel libxpm* freetype libjpeg* libpng* libtool* libxml2 libxml2-devel patch libcurl-devel bzip2-devel freetype-devel2)

 

 詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

2)安裝mysql5.7并安裝gcc編譯器如下

?
1
[root@yankerp-zabbix ~]# yum install gcc gcc-c++ -y

因為在centos7中默認(rèn)安裝了mysql的分支mariadb 所以需要卸載mariadb

?
1
2
3
[root@yankerp-zabbix src]# rpm -qa | grep mariadb
mariadb-libs-5.5.44-2.el7.centos.x86_64
[root@yankerp-zabbix src]# rpm -e mariadb-libs-5.5.44-2.el7.centos.x86_64 --nodeps

安裝mysql

下載mysql二進(jìn)制包

 

復(fù)制代碼 代碼如下:

[root@yankerp-zabbix src]# wget http://mirrors.sohu.com/mysql/mysql-5.7/mysql-5.7.18-linux-glibc2.5-x86_64.tar.gz

 

解壓mysql二進(jìn)制包,并拷貝到/usr/local/mysql目錄下

?
1
2
[root@yankerp-zabbix src]# tar zxf mysql-5.7.18-linux-glibc2.5-x86_64.tar.gz
[root@yankerp-zabbix src]# mv mysql-5.7.18-linux-glibc2.5-x86_64 /usr/local/mysql

進(jìn)入/usr/local/mysql/目錄創(chuàng)建data目錄以及l(fā)og目錄,并給予data755權(quán)限。

?
1
2
3
4
[root@yankerp-zabbix src]# cd /usr/local/mysql/
[root@yankerp-zabbix mysql]# mkdir data
[root@yankerp-zabbix mysql]# mkdir log
[root@yankerp-zabbix mysql]# chmod +755 data/

設(shè)置變量

 

復(fù)制代碼 代碼如下:

echo "export path=$path:/usr/local/mysql/bin" >> /etc/profile && source /etc/profile 

 

創(chuàng)建mysql組,以及mysql用戶

 

復(fù)制代碼 代碼如下:

[root@yankerp-zabbix mysql]# groupadd mysql && useradd -r -g mysql -s /bin/false mysql 

 

打開/etc/my.cnf添加mysql的主配置文件如下:

vim /etc/my.cnf

?
1
2
3
4
5
6
7
8
[client]
socket=/usr/local/mysql/mysql.sock
[mysqld]
basedir=/usr/local/mysql
datadir=/usr/local/mysql/data
pid-file=/usr/local/mysql/data/mysqld.pid
socket=/usr/local/mysql/mysql.sock
log_error=/usr/local/mysql/log/mysql.err

初始化mysql數(shù)據(jù)庫

 

復(fù)制代碼 代碼如下:

[root@yankerp-zabbix mysql]# chmod 750 data/ && chown -r mysql . && chgrp -r mysql . && bin/mysqld --initialize --user=mysql 

 

復(fù)制mysql啟動腳本,并啟動mysql數(shù)據(jù)庫

 

復(fù)制代碼 代碼如下:

cp /usr/local/mysql/support-files/mysql.server /etc/init.d/mysqld && service mysqld start 

 

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

啟動完成后mysql的密碼存放到了/usr/local/mysql/log/目錄下

?
1
2
[root@yankerp-zabbix mysql]# cat /usr/local/mysql/log/mysql.err | grep password
2018-01-06t06:31:34.837627z 1 [note] a temporary password is generated for root@localhost: s>2%8=/q>skp

進(jìn)入mysql數(shù)據(jù)庫并修改mysql數(shù)據(jù)庫密碼

 詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

到這里mysql的安裝正式完成

二、安裝nginx

1)安裝pcre-devel zlib-devel 相關(guān)支持包

?
1
[root@yankerp-zabbix ~]# yum install zlib-devel pcre-devel -y

2)創(chuàng)建www組以及www用戶

?
1
2
[root@yankerp-zabbix ~]# groupadd www
[root@yankerp-zabbix ~]# useradd -g www www -s /sbin/nologin

3)下載nginx源碼包

?
1
[root@yankerp-zabbix ~]# wget http://nginx.org/download/nginx-1.10.2.tar.gz

4)解壓nginx源碼包并進(jìn)入nginx解壓目錄

?
1
2
[root@yankerp-zabbix ~]# tar zxf nginx-1.10.2.tar.gz
[root@yankerp-zabbix ~]# cd nginx-1.10.2

 

復(fù)制代碼 代碼如下:

[root@yankerp-zabbix nginx-1.10.2]# ./configure --prefix=/usr/local/nginx1.10 --with-http_dav_module --with-http_stub_status_module --with-http_addition_module --with-http_sub_module  --with-http_flv_module --with-http_mp4_module   --with-http_ssl_module --with-http_gzip_static_module --user=www --group=www

 

make && make install

5)創(chuàng)建軟連接,優(yōu)化執(zhí)行路徑,并啟動nginx服務(wù)

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

訪問測試:

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

三、安裝php

?
1
2
3
4
5
[root@yankerp-zabbix ~]# wget ftp://mcrypt.hellug.gr/pub/crypto/mcrypt/libmcrypt/libmcrypt-2.5.7.tar.gz
[root@yankerp-zabbix ~]# tar zxf libmcrypt-2.5.7.tar.gz
[root@yankerp-zabbix ~]# cd libmcrypt-2.5.7/
[root@yankerp-zabbix libmcrypt-2.5.7]# ./configure && make && make install
ln -s /usr/local/mysql/lib/libmysqlclient.so.20.3.0 /usr/local/mysql/lib/libmysqlclient_r.so

下載php源碼包

?
1
2
3
4
[root@yankerp-zabbix ~]# tar zxf php-5.6.27.tar.gz
[root@yankerp-zabbix ~]# cd php-5.6.27/
[root@yankerp-zabbix php-5.6.27]# ./configure --prefix=/usr/local/php5.6 --with-config-file-path=/etc --with-mysql=/usr/local/mysql --with-mysqli=/usr/local/mysql/bin/mysql_config --with-mysql-sock=/usr/local/mysql/mysql.sock --with-gd --with-iconv --with-libxml-dir=/usr --with-mhash --with-mcrypt --with-config-file-scan-dir=/etc/php.d --with-bz2 --with-zlib --with-freetype-dir --with-png-dir --with-jpeg-dir --enable-xml --enable-bcmath --enable-shmop --enable-sysvsem --enable-inline-optimization --enable-mbregex --enable-fpm --enable-mbstring --enable-ftp --enable-gd-native-ttf --with-openssl --enable-pcntl --enable-sockets --with-xmlrpc --enable-zip --enable-soap --without-pear --with-gettext --enable-session --with-mcrypt --with-curl && make && make install
[root@yankerp-zabbix php-5.6.27]# cp php.ini-production /etc/php.ini

編輯配置文件/etc/php.ini ,修改后的內(nèi)容如下:

找到:
;date.timezone =
修改為:
date.timezone = prc #設(shè)置時區(qū)
找到:
expose_php = on
修改為:
expose_php = off #禁止顯示php版本的信息
找到:
short_open_tag = off
修改為:
short_open_tag = on //支持php短標(biāo)簽
找到:
post_max_size = 8m
修改為:
post_max_size = 16m  //上傳文件大小
找到:
max_execution_time = 30
修改為:
max_execution_time = 300  //php腳本最大執(zhí)行時間
找到:
max_input_time = 60
修改為:
max_input_time = 300  //以秒為單位對通過post、get以及put方式接收數(shù)據(jù)時間進(jìn)行限制
always_populate_raw_post_data = -1
mbstring.func_overload = 0

創(chuàng)建php服務(wù)啟動腳本

?
1
2
3
4
5
6
[root@yankerp-zabbix php-5.6.27]# cp sapi/fpm/init.d.php-fpm /etc/init.d/php-fpm
[root@yankerp-zabbix php-5.6.27]# chmod +x /etc/init.d/php-fpm
[root@yankerp-zabbix php-5.6.27]# chkconfig --add php-fpm
[root@yankerp-zabbix php-5.6.27]# chkconfig php-fpm on
[root@yankerp-zabbix php-5.6.27]#cp /usr/local/php5.6/etc/php-fpm.conf.default /usr/local/php5.6/etc/php-fpm.conf
[root@yankerp-zabbix php-5.6.27]#vim /usr/local/php5.6/etc/php-fpm.conf

修改內(nèi)容如下:

?
1
2
3
4
5
6
7
8
pid = run/php-fpm.pid
user = www
group = www
listen =127.0.0.1:9000
pm.max_children = 300
pm.start_servers = 10
pm.min_spare_servers = 10
pm.max_spare_servers =50

啟動php-fpm服務(wù)

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

配置nginx并解析php

?
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
#user nobody;
worker_processes 1;
 
#error_log logs/error.log;
#error_log logs/error.log notice;
#error_log logs/error.log info;
 
#pid  logs/nginx.pid;
 
 
events {
 worker_connections 1024;
}
 
 
http {
 include  mime.types;
 default_type application/octet-stream;
 
 #log_format main '$remote_addr - $remote_user [$time_local] "$request" '
 #     '$status $body_bytes_sent "$http_referer" '
 #     '"$http_user_agent" "$http_x_forwarded_for"';
 
 #access_log logs/access.log main;
 
 sendfile  on;
 #tcp_nopush  on;
 
 #keepalive_timeout 0;
 keepalive_timeout 65;
 
 #gzip on;
 
 server {
  listen  80;
  server_name localhost;
 
  #charset koi8-r;
 
  #access_log logs/host.access.log main;
 
  location / {
   root html;
   index index.php index.html index.htm;
  }
 
  #error_page 404    /404.html;
 
  # redirect server error pages to the static page /50x.html
  #
  error_page 500 502 503 504 /50x.html;
  location = /50x.html {
   root html;
  }
 
  # proxy the php scripts to apache listening on 127.0.0.1:80
  #
  #location ~ \.php$ {
  # proxy_pass http://127.0.0.1;
  #}
 
  # pass the php scripts to fastcgi server listening on 127.0.0.1:9000
  #
  location ~ \.php$ {
   root   html;
   fastcgi_pass 127.0.0.1:9000;
   fastcgi_index index.php;
   fastcgi_param script_filename /scripts$fastcgi_script_name;
   include  fastcgi.conf;
  }
 
  # deny access to .htaccess files, if apache's document root
  # concurs with nginx's one
  #
  #location ~ /\.ht {
  # deny all;
  #}
 }
 
 
 # another virtual host using mix of ip-, name-, and port-based configuration
 #
 #server {
 # listen  8000;
 # listen  somename:8080;
 # server_name somename alias another.alias;
 
 # location / {
 #  root html;
 #  index index.html index.htm;
 # }
 #}
 
 
 # https server
 #
 #server {
 # listen  443 ssl;
 # server_name localhost;
 
 # ssl_certificate  cert.pem;
 # ssl_certificate_key cert.key;
 
 # ssl_session_cache shared:ssl:1m;
 # ssl_session_timeout 5m;
 
 # ssl_ciphers high:!anull:!md5;
 # ssl_prefer_server_ciphers on;
 
 # location / {
 #  root html;
 #  index index.html index.htm;
 # }
 #}
 
}

在html目錄下創(chuàng)建test.php寫入測試頁訪問測試:

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

寫入mysql測試頁

vim /usr/local/nginx/html/test2.php

?
1
2
3
4
5
<?php
$link=mysql_connect('localhost','root','123456');
if($link) echo "ok";
mysql_close();
?>

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

出現(xiàn)以上圖片證明lnmp環(huán)境已經(jīng)可以正常工作!

四、正式安裝zabbix,以上只是搭建環(huán)境下面正式安裝zabbix

此環(huán)境需要提前安裝好lnmp環(huán)境(mysql,nginx,php的安裝目錄均是/usr/local/下)

創(chuàng)建zabbix運行用戶

?
1
2
[root@yankerp-zabbix ~]# groupadd zabbix
[root@yankerp-zabbix ~]# useradd -g zabbix zabbix

安裝所需的包

 

復(fù)制代碼 代碼如下:

[root@yankerp-zabbix ~]#yum install -y net-snmp net-snmp-devel curl-devel java-1.8.0-openjdk java-1.8.0-openjdk-devel  openipmi-devel  libssh2-devel

 

安裝fping

?
1
2
3
4
5
[root@yankerp-zabbix ~]# tar zxf fping-3.10.tar.gz 
[root@yankerp-zabbix ~]# cd fping-3.10/
[root@yankerp-zabbix fping-3.10]# ./configure && make && make install
[root@yankerp-zabbix fping-3.10]# chown root:zabbix /usr/local/sbin/fping 
[root@yankerp-zabbix fping-3.10]# chmod 4710 /usr/local/sbin/fpin

安裝zabbix-server

?
1
2
[root@yankerp-zabbix ~]# tar zxf zabbix-3.2.1.tar.gz 
[root@yankerp-zabbix ~]# cd zabbix-3.2.1/

 

復(fù)制代碼 代碼如下:

[root@yankerp-zabbix zabbix-3.2.1]# ./configure --prefix=/usr/local/zabbix --enable-server --enable-agent --enable-java --with-mysql=/usr/local/mysql/bin/mysql_config --with-net-snmp --with-libcurl --with-openipmi

 

在編譯的時候最好帶上--enable-java這個參數(shù),方便后續(xù)監(jiān)控tomcat等程序。

make && make install

添加系統(tǒng)軟連接

?
1
2
[root@yankerp-zabbix zabbix-3.2.1]# ln -s /usr/local/zabbix/bin/* /usr/local/bin/
[root@yankerp-zabbix zabbix-3.2.1]# ln -s /usr/local/zabbix/sbin/* /usr/local/sbin/

創(chuàng)建zabbix數(shù)據(jù)庫和mysql用戶:

?
1
2
3
4
5
6
7
mysql> create database zabbix character set utf8;
query ok, 1 row affected (0.18 sec)
 
mysql> grant all privileges on zabbix.* to zabbix@localhost identified by 'zabbix';
query ok, 0 rows affected, 1 warning (0.37 sec)
 
mysql>

導(dǎo)入zabbix初始數(shù)據(jù);(切換到zabbix目錄)

?
1
2
3
4
5
6
7
/root/zabbix-3.2.1/database/mysql
[root@yankerp-zabbix mysql]# mysql -uzabbix -pzabbix -hlocalhost zabbix < schema.sql 
mysql: [warning] using a password on the command line interface can be insecure.
[root@yankerp-zabbix mysql]# mysql -uzabbix -pzabbix -hlocalhost zabbix < images.sql 
mysql: [warning] using a password on the command line interface can be insecure.
[root@yankerp-zabbix mysql]# mysql -uzabbix -pzabbix -hlocalhost zabbix < data.sql 
mysql: [warning] using a password on the command line interface can be insecure.

編輯/usr/local/zabbix/etc/zabbix_server.conf(修改如下)

?
1
2
3
4
5
6
7
8
logfile=/usr/local/zabbix/logs/zabbix_server.log
pidfile=/usr/local/zabbix/logs/zabbix_server.pid
dbhost=localhost
dbname=zabbix
dbuser=zabbix
dbpassword=zabbix
dbport=3306
fpinglocation=/usr/local/sbin/fping
?
1
2
[root@yankerp-zabbix mysql]# mkdir -p /usr/local/zabbix/logs
[root@yankerp-zabbix mysql]# chown -r zabbix:zabbix /usr/local/zabbix/

啟動zabbix server

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

解決方法:

在ld.so.conf中加入/usr/local/mysql/lib

?
1
2
3
4
[root@yankerp-zabbix ~]# cat /etc/ld.so.conf
include ld.so.conf.d/*.conf
/usr/local/mysql/lib
/usr/local/lib

插入完后執(zhí)行

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

我們發(fā)現(xiàn)還是沒有啟動那么接下來查看zabbix_server的日志如下:

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

上面的提示mysql.sock問題,接下來打開zabbix主配置文件修改如下:

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

添加啟動腳本

?
1
2
3
4
5
6
7
8
[root@yankerp-zabbix zabbix-3.2.1]# cp misc/init.d/fedora/core/zabbix_server /etc/rc.d/init.d/zabbix_server
[root@yankerp-zabbix zabbix-3.2.1]# cp misc/init.d/fedora/core/zabbix_agentd /etc/rc.d/init.d/zabbix_agentd
[root@yankerp-zabbix zabbix-3.2.1]# chmod +x /etc/rc.d/init.d/zabbix_server 
[root@yankerp-zabbix zabbix-3.2.1]# chmod +x /etc/rc.d/init.d/zabbix_agentd 
[root@yankerp-zabbix zabbix-3.2.1]# chkconfig --add zabbix_server
[root@yankerp-zabbix zabbix-3.2.1]# chkconfig --add zabbix_agentd
[root@yankerp-zabbix zabbix-3.2.1]# chkconfig zabbix_server on
[root@yankerp-zabbix zabbix-3.2.1]# chkconfig zabbix_agentd on

修改zabbix開機啟動腳本中的zabbix安裝目錄

?
1
2
3
4
5
6
7
8
vi /etc/rc.d/init.d/zabbix_server #編輯服務(wù)端配置文件
basedir=/usr/local/zabbix/ #zabbix安裝目錄
pidfile=/usr/local/zabbix/logs/$binary_name.pid  #pid文件路徑
:wq! #保存退出
vi /etc/rc.d/init.d/zabbix_agentd #編輯客戶端配置文件
basedir=/usr/local/zabbix/ #zabbix安裝目錄
pidfile=/usr/local/zabbix/logs/$binary_name.pid #pid文件路徑
:wq! #保存退出

正式啟動zabbix_server

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

啟動成功后配置zabbix的web界面

?
1
2
3
[root@zabbix-yankerp ~]# cd /root/zabbix-3.2.1/
[root@zabbix-yankerp zabbix-3.2.1]# cp -r frontends/php/ /usr/local/nginx/html/zabbix
[root@zabbix-yankerp zabbix-3.2.1]# chown -r www:www /usr/local/nginx/html/zabbix/

出現(xiàn)以下界面證明 

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

詳解Centos7.2編譯安裝zabbix3.2(詳細(xì)步驟)

出現(xiàn)以上圖片那么證明zabbix正式搭建成功!

以上就是本文的全部內(nèi)容,希望對大家的學(xué)習(xí)有所幫助,也希望大家多多支持服務(wù)器之家。

原文鏈接:http://blog.csdn.net/qq_39591494/article/details/78983861

延伸 · 閱讀

精彩推薦
  • CentosCentOS7設(shè)置日期和時間方法以及基本概念介紹

    CentOS7設(shè)置日期和時間方法以及基本概念介紹

    這篇文章主要介紹了CentOS7設(shè)置日期和時間方法以及基本概念介紹,本文講解使用CentOS7中的新命令timedatectl設(shè)置日期時間方法,需要的朋友可以參考下 ...

    CentOS之家6522019-09-19
  • CentosCentos7運用/dev/shm進(jìn)行網(wǎng)站優(yōu)化

    Centos7運用/dev/shm進(jìn)行網(wǎng)站優(yōu)化

    這篇文章主要介紹了LINUX中Centos7運用/dev/shm進(jìn)行網(wǎng)站優(yōu)化相關(guān)知識點,對此有興趣的朋友參考學(xué)習(xí)下。...

    彬菌9912022-03-02
  • CentosCentOS6.5下Redis安裝與配置詳細(xì)步驟

    CentOS6.5下Redis安裝與配置詳細(xì)步驟

    本篇文章主要介紹了CentOS6.5下Redis安裝與配置詳細(xì)步驟,詳細(xì)介紹redis單機單實例安裝與配置,服務(wù)及開機自啟動。有興趣的可以了解一下。...

    飛流11452021-12-24
  • CentosCentOS 6.6實現(xiàn)永久修改DNS地址的方法

    CentOS 6.6實現(xiàn)永久修改DNS地址的方法

    這篇文章主要介紹了CentOS 6.6實現(xiàn)永久修改DNS地址的方法,涉及針對CentOS配置文件的相關(guān)設(shè)置技巧,具有一定參考借鑒價值,需要的朋友可以參考下 ...

    Linux社區(qū)4472020-08-21
  • CentosCentos 7開啟網(wǎng)卡自動獲取IP的詳細(xì)方法

    Centos 7開啟網(wǎng)卡自動獲取IP的詳細(xì)方法

    本篇文章主要介紹了Centos 7開啟網(wǎng)卡自動獲取IP的詳細(xì)方法,小編覺得挺不錯的,現(xiàn)在分享給大家,也給大家做個參考。一起跟隨小編過來看看吧...

    凌鋒8972021-12-29
  • Centoscentos 安裝與操作方法

    centos 安裝與操作方法

    這篇文章主要介紹了centos 安裝與操作方法,需要的朋友可以參考下...

    centos之家5272019-07-11
  • Centoscentos不小心刪除/root目錄該如何解決?

    centos不小心刪除/root目錄該如何解決?

    一些朋友最近在問小編centos不小心刪除/root目錄該如何解決?今天小編就為大家分享centos不小心刪除/root目錄解決辦法;希望對大家會有幫助,有需要的朋友...

    腳本之家8022019-05-29
  • CentosCentOS下Uptime命令詳解

    CentOS下Uptime命令詳解

    在Linux下,我們可以使用uptime命令,而且此命令不必使用root權(quán)限。uptime命令在系統(tǒng)中已經(jīng)默認(rèn)安裝了。今天小編為大家?guī)淼氖荂entOS下Uptime命令詳解;希望...

    CentOS之家11482019-06-19
主站蜘蛛池模板: 成人精品 | 国产福利不卡一区二区三区 | 99亚洲国产精品 | 中文字幕在线观看成人 | 国产免费一级淫片a级中文 99国产精品自拍 | 久久综合给合久久狠狠狠97色69 | 亚洲第一成av人网站懂色 | 国产亚洲精品久久久久久久软件 | 国产午夜亚洲精品午夜鲁丝片 | 欧美91看片特黄aaaa | 国产一级毛片a | 日韩毛片一区二区三区 | 毛片免费在线播放 | 久久久久女人精品毛片 | 蜜桃麻豆视频 | 亚洲一区 国产精品 | 一级免费特黄视频 | 一级在线免费观看视频 | 久草在线资源福利站 | 亚洲导航深夜福利涩涩屋 | 毛片视频网址 | 欧美69free性videos| 国产精品一区免费在线观看 | 国产一区二区视频在线播放 | 成人在线观看免费观看 | 国产精品视频一区二区三区四 | 香蕉成人在线视频 | 美女视频大全网站免费 | 久久久久久久久久美女 | 精品久久久一二三区播放播放播放视频 | 国产成人精品一区二区仙踪林 | 欧美特一级| a黄网站 | 国产视频在线免费观看 | 亚洲成人福利电影 | 日韩精品dvd | 久久久久久免费免费 | 天天夜夜操操 | 蜜桃久久一区二区三区 | h视频在线免费观看 | 九九热免费精品 |