zabbix監(jiān)控4.4升級(jí)至5.0的詳細(xì)教程
1.ZABBIX備份
[root@iZ2zeapnvuohe8p14289u6Z /]# mkdir -p /soft/zabbixback/zabbix-backup [root@iZ2zeapnvuohe8p14289u6Z /]# cp /etc/zabbix/zabbix_server.conf /soft/zabbixback/zabbix-backup [root@iZ2zeapnvuohe8p14289u6Z /]# cp /etc/zabbix/zabbix_agentd.conf /soft/zabbixback/zabbix-backup [root@iZ2zeapnvuohe8p14289u6Z /]# cp /etc/zabbix/web/zabbix.conf.php /soft/zabbixback/zabbix-backup [root@iZ2zeapnvuohe8p14289u6Z /]# cp -R /usr/share/zabbix/ /soft/zabbixback/zabbix-backup [root@iZ2zeapnvuohe8p14289u6Z /]# cp –R /usr/share/doc/zabbix-* /soft/zabbixback/zabbix-backup
2. MariaDB數(shù)據(jù)庫(kù)備份
[root@iZ2zeapnvuohe8p14289u6Z /]# mysql # 進(jìn)入mysql MariaDB [(none)]> select count(8) tables,table_schema from information_schema.tables where table_schema = 'zabbix'; +--------+--------------+ | tables | table_schema | +--------+--------------+ | 166 | zabbix | +--------+--------------+ 1 row in set (0.00 sec) MariaDB [(none)]> mysqldump -uzabbix -pzabbix --opt --skip-lock-tables zabbix | gzip > /home/backup/zabbix_$(date +%Y%m%d_%H%M%S).sql.gz [root@iZ2zeapnvuohe8p14289u6Z /]# ll /soft/zabbixback 總用量 5120 -rw-r--r-- 1 root root 20 7月 23 10:48 zabbix_20200726_104832.sql.gz -rw-r--r-- 1 root root 526 7月 23 10:48 zabbix_20200726_104849.sql.gz drwxr-xr-x 3 root root 96 7月 23 10:45 zabbix-backup<br data-filtered="filtered"><br data-filtered="filtered">
3. 停止 zabbix-server,zabbix-agent
[root@iZ2zeapnvuohe8p14289u6Z /]# systemctl stop zabbix-agent zabbix-server
4.卸載舊版本4.4
[root@iZ2zeapnvuohe8p14289u6Z /]# yum remove zabbix-web-* httpd
5. 4.4升級(jí)5.0
[root@iZ2zeapnvuohe8p14289u6Z /]# rpm -Uvh https://repo.zabbix.com/zabbix/5.0/rhel/7/x86_64/zabbix-release-5.0-1.el7.noarch.rpm [root@iZ2zeapnvuohe8p14289u6Z /]# yum clean all [root@iZ2zeapnvuohe8p14289u6Z /]# yum update zabbix-server zabbix-agent -y [root@iZ2zeapnvuohe8p14289u6Z /]# yum-config-manager --enable rhel-server-rhscl-7-rpms
6.編輯zabbix.repo文件
[root@iZ2zeapnvuohe8p14289u6Z /]# vim /etc/yum.repos.d/zabbix.repo
7.安裝zabbix前端包
[root@iZ2zeapnvuohe8p14289u6Z /]# yum install zabbix-web-mysql-scl zabbix-apache-conf-scl -y
8.Zabbix前端PHP配置
[root@iZ2zeapnvuohe8p14289u6Z /]# vim /etc/opt/rh/rh-php72/php-fpm.d/zabbix.conf
9.啟動(dòng)zabbix的server和agent、并設(shè)置為開(kāi)機(jī)啟動(dòng)
[root@iZ2zeapnvuohe8p14289u6Z /]# systemctl restart zabbix-server zabbix-agent httpd rh-php72-php-fpm [root@iZ2zeapnvuohe8p14289u6Z /]# systemctl enable zabbix-server zabbix-agent httpd rh-php72-php-fpm
到此這篇關(guān)于zabbix監(jiān)控4.4升級(jí)至5.0的文章就介紹到這了,更多相關(guān)zabbix監(jiān)控內(nèi)容請(qǐng)搜索本站以前的文章或繼續(xù)瀏覽下面的相關(guān)文章希望大家以后多多支持本站!
版權(quán)聲明:本站文章來(lái)源標(biāo)注為YINGSOO的內(nèi)容版權(quán)均為本站所有,歡迎引用、轉(zhuǎn)載,請(qǐng)保持原文完整并注明來(lái)源及原文鏈接。禁止復(fù)制或仿造本網(wǎng)站,禁止在非www.sddonglingsh.com所屬的服務(wù)器上建立鏡像,否則將依法追究法律責(zé)任。本站部分內(nèi)容來(lái)源于網(wǎng)友推薦、互聯(lián)網(wǎng)收集整理而來(lái),僅供學(xué)習(xí)參考,不代表本站立場(chǎng),如有內(nèi)容涉嫌侵權(quán),請(qǐng)聯(lián)系alex-e#qq.com處理。