Zabbix故障:Apache源码和页面上的PHP红色提示


昨天把ansible-tower安装在这机器上,然后把原来的nginx霸占了,逼迫把zabbix的web换上了apache,源码安装上apache和重新编译php后,就出现这个php错误提示。

把php.ini的session路径改了,然后再把session目录递归权限改为777,然后重启php和apache即可。

附上关于zabbix的apache和php的源码指定的模块

./configure --prefix=/usr/local/php  --with-apxs2=/usr/local/apache2.4/bin/apxs --with-config-file-path=/usr/local/php/etc  --with-pdo-mysql=/usr/local/mysql  --with-mysqli=/usr/local/mysql/bin/mysql_config --with-libxml-dir --with-gd --with-jpeg-dir  --with-png-dir --with-freetype-dir --with-iconv-dir --with-zlib-dir --with-bz2 --with-openssl  --with-mcrypt --enable-soap  --enable-gd-native-ttf --enable-mbstring --enable-sockets --enable-exif

wget https://mirrors.cnnic.cn/apache/httpd/httpd-2.4.29.tar.gz
wget https://mirrors.cnnic.cn/apache/apr/apr-1.6.3.tar.gz
wget https://mirrors.cnnic.cn/apache/apr/apr-util-1.6.1.tar.gz
  ./configure --prefix=/usr/local/apache2.4 --with-apr=/usr/local/apr --with-apr-util=/usr/local/apr-util  --enable-so --enable-mods-shared=most

  ★ 在zabbix页面上显示A session had already been started - ignoring session_start()这个提示,把session.auto_start = 1改为0即可

编辑httpd.conf文件

添加如下代码

LoadModule php7_module modules/libphp7.so
AddType application/x-httpd-php .php
DirectoryIndex index.php index.htm index.html

更多Zabbix相关教程集合: 

在Ubuntu 16.04服务器上安装Zabbix 3.2 

CentOS 7 LNMP环境搭建Zabbix3.0 

Ubuntu 16.04安装部署监控系统Zabbix2.4 

Zabbix监控安装部署及警报配置 

Zabbix触发器表达式详解

Ubuntu 16.04下安装部署Zabbix3.0 

CentOS 6.3下Zabbix监控apache server-status

CentOS 7 下 Zabbix 3.0安装详解

64位CentOS 6.2下安装Zabbix 2.0.6 

Zabbix 3.2.6 通过Orabbix监控Oracle数据库 

ZABBIX 的详细介绍:请点这里
ZABBIX 的下载地址:请点这里

本文永久更新链接地址:https://www.bkjia.com/Linux/2018-03/151240.htm

相关内容

    暂无相关文章