昨天把ansible-tower安裝在這機器上,而後把原來的nginx霸佔了,逼迫把zabbix的web換上了apache,源碼安裝上apache和從新編譯php後,就出現這個php錯誤提示。
把php.ini的session路徑改了,而後再把session目錄遞歸權限改成777,而後重啓php和apache便可。php
附上關於zabbix的apache和php的源碼指定的模塊
php重啓編譯html
./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 apache源碼編譯 ./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