1. 程式人生 > >PHP 7.X安裝Zabbix 3.0.7出現問題解決

PHP 7.X安裝Zabbix 3.0.7出現問題解決

A non well formed numeric value encountered [zabbix.php:21 → require_once() → ZBase->run() → ZBase->processRequest() → 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->processRequest() → 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->processRequest() → 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);' /opt/nginx/html/zabbix/include/func.inc.php

注意一下檔案路徑即可。