CentOS 7.2安装zabbix 3.2
admin
2023-05-20 05:01:58
0

系统环境:LNMP

Linux: Centos 7.2

Nginx: 1.10.3

Mysql: 5.6.35

PHP: 5.4.16


安装zabbix-server

1 Repository installation

rpm -ivh http://repo.zabbix.com/zabbix/3.2/rhel/7/x86_64/zabbix-release-3.2-1.el7.noarch.rpm

2 Install Zabbix-server


yum install -y zabbix-release zabbix-server-mysql zabbix-get zabbix-web zabbix-web-mysql zabbix-agent

3 Creating initial database

shell> mysql -uroot -p
mysql> create database zabbix character set utf8 collate utf8_bin;
mysql> grant all privileges on zabbix.* to zabbix@localhost identified by '';
mysql> quit;


zcat /usr/share/doc/zabbix-server-mysql-3.2.*/create.sql.gz | mysql -uzabbix -p zabbix

4  Database configuration for Zabbix server


# vi /etc/zabbix/zabbix_server.conf
DBHost=localhost
DBName=zabbix
DBUser=zabbix
DBPassword=

5 Starting Zabbix server process


# systemctl start zabbix-server
# systemctl enable zabbix-server

PHP configuration for Zabbix frontend

vi /etc/php.ini
max_execution_time 300
memory_limit 128M
post_max_size 16M
upload_max_filesize 2M
max_input_time 300
always_populate_raw_post_data -1
date.timezone Asia/Shanghai


7. copy frontend web files

cp -R /usr/share/zabbix /usr/local/nginx/html

8. Starting Service

/etc/init.d/php-fpm
systemctl restart nginx
systemctl start zabbix-server.service

9. Install web

http://localhost/zabbix


问题

A non well formed numeric value encountered [zabbix.php:21 → require_once() → ZBase->run() → ZBase->proce***equest() → CView->getOutput() → include() → make_status_of_zbx() → CFrontendSetup->checkRequirements() → CFrontendSetup->checkPhpMemoryLimit() → str2mem() in include/func.inc.php:410]
A non well formed numeric value encountered [zabbix.php:21 → require_once() → ZBase->run() → ZBase->proce***equest() → CView->getOutput() → include() → make_status_of_zbx() → CFrontendSetup->checkRequirements() → CFrontendSetup->checkPhpPostMaxSize() → str2mem() in include/func.inc.php:410]
A non well formed numeric value encountered [zabbix.php:21 → require_once() → ZBase->run() → ZBase->proce***equest() → CView->getOutput() → include() → make_status_of_zbx() → CFrontendSetup->checkRequirements() → CFrontendSetup->checkPhpUploadMaxFilesize() → str2mem() in include/func.inc.php:410]


安装完成之后启动就出现这个问题,这个是因为PHP 7.1.0类型强化,处理方法也很简单找到Zabbix WEB目录下include/func.inc.php文件

问题解决

sed -i '/$last = strtolower(substr($val, -1));/a$val = substr($val,0,-1);' /usr/local/nginx/html/zabbix/include/func.inc.php



相关内容

热门资讯

柳州5.2级地震致楼房倒塌,店... 据中国地震台网消息,5月18日00时21分在广西柳州市柳南区发生5.2级地震,震源深度8千米。有网友...
“华南第一商圈”再升级!全国首... 5月16日,“万兆AI惠商,联通美好未来”2026年517电信日暨中国联通品牌与产品广东宣传推广会在...
原创 3... 如果今年618你手里预算在3000多元,又特别看重拍照,我反而不建议只盯着那些刚发布、热度很高的新机...
苹果首款折叠屏iPhone U... 快科技5月17日消息,今年4月曾有消息称,苹果首款折叠屏手机iPhoneUltra(iPhone F...
广西柳州发生5.2级地震,南宁... 据中国地震台网正式测定,5月18日0时21分在广西柳州市柳南区发生5.2级地震,震源深度8公里,震中...
购药新规落地!多地药房称买“减... 5月17日消息,近日有消息称,自5月15日起,司美格鲁肽、替尔泊肽等GLP-1药物均需要凭有效期内的...
苹果深夜“放价”:iPhone... 来源:环球网 【环球网科技综合报道】5月15日消息,苹果在深夜毫无预警地打响了一轮价格战,iPho...
原创 从... 进入2026年5月下旬,手机圈即将迎来全年最密集的新品发布窗口。 从今天开始到7月下旬,短短两个月时...
全钢实验台厂家梳理 医疗/科研... 导语:实验室设备选型需兼顾功能适配性与长期稳定性。基于2026年实验室建设行业白皮书及公开市场数据,...
半年内,中方连续迎来安理会“四... 半年内,中方连续迎来联合国安理会“四常”领导人。5月16日,外交部发言人宣布:应中方邀请,俄罗斯总统...