Hi there,
I've recently done a full system upgrade with a lot of hiccups. This included having to replace a bunch of incompatible or missing libraries, a full portupgrade and a whole series of system rebuilds that went badly wrong.
Currently, my local Apache server displays nothing but blank pages with any PHP applications. I'm using torrentflux2 and jinzora2 - a frontend for bittornado and a music streaming application.
Both reside in subdirectories of the www DocumentRoot. This is on a purely local box, nothing fancy, just a bunch of php connnecting to MySQL backend
- users/groups and permissions are correct (all www)
- PHP5 module is installed.
- simple index.html works, both in the DocumentRoot and the actual subdirectories of the applications
- php5-mysql is installed, mysql_connect() works (i.e. I can get an echo "Connected to MySQL" to show up with the username and password from a simple test.php script
- phpinfo() works (output below). I can run phpinfo() via an index.php in the application directories so it's not a permissions thing.
- mysql is running, Apache is running
- testing application scripts with php -l <whatever.php> works without errors
- setting LogLevel to 'debug' in httpd.conf gives nothing relevant (logging works, but all I get is a warning about a deprecated php function which shouldn't cause this). Ditto for syslog
- php -v shows no errors
The index.php of the applications, though, display absolutely nothing at all.
If I place phpinfo() above the rest of the php in that file, it works. If I put it after the first include, like so
blank again.
gives no errors.
I'm almost 100% sure that it's something to do with php-related modules or configuration and I am convinced that it's something _really_ stupid that I am missing.
Attached is all the (loads of) info that might be relevant...I'm happy to post any other info (going away for the weekend so it'll be Monday).
I am thoroughly puzzled at this point and would be grateful for any tips at all. Happy to try anything suggested.
Thanks very much,
-John
-------
--------
--------
--------
--------
-----
------
I've recently done a full system upgrade with a lot of hiccups. This included having to replace a bunch of incompatible or missing libraries, a full portupgrade and a whole series of system rebuilds that went badly wrong.
Currently, my local Apache server displays nothing but blank pages with any PHP applications. I'm using torrentflux2 and jinzora2 - a frontend for bittornado and a music streaming application.
Both reside in subdirectories of the www DocumentRoot. This is on a purely local box, nothing fancy, just a bunch of php connnecting to MySQL backend
- users/groups and permissions are correct (all www)
- PHP5 module is installed.
- simple index.html works, both in the DocumentRoot and the actual subdirectories of the applications
- php5-mysql is installed, mysql_connect() works (i.e. I can get an echo "Connected to MySQL" to show up with the username and password from a simple test.php script
- phpinfo() works (output below). I can run phpinfo() via an index.php in the application directories so it's not a permissions thing.
- mysql is running, Apache is running
- testing application scripts with php -l <whatever.php> works without errors
- setting LogLevel to 'debug' in httpd.conf gives nothing relevant (logging works, but all I get is a warning about a deprecated php function which shouldn't cause this). Ditto for syslog
- php -v shows no errors
The index.php of the applications, though, display absolutely nothing at all.
If I place phpinfo() above the rest of the php in that file, it works. If I put it after the first include, like so
Code:
// main.internal
require_once("inc/main.internal.php");
phpinfo();
blank again.
Code:
php -l inc/main.internal.php
gives no errors.
I'm almost 100% sure that it's something to do with php-related modules or configuration and I am convinced that it's something _really_ stupid that I am missing.
Attached is all the (loads of) info that might be relevant...I'm happy to post any other info (going away for the weekend so it'll be Monday).
I am thoroughly puzzled at this point and would be grateful for any tips at all. Happy to try anything suggested.
Thanks very much,
-John
-------
Code:
behemoth# uname -a
FreeBSD behemoth 9.0-RELEASE FreeBSD 9.0-RELEASE #5: Thu Mar 8 12:20:20 CET 2012
root@behemoth:/usr/obj/usr/src/sys/BEHEMOTH i386
--------
Code:
behemoth# pkg_info|grep -i php
adodb-4.99.0 Database library for PHP
eaccelerator-0.9.6.1_1 A free open-source PHP accelerator & optimizer
php5-5.3.10_1 PHP Scripting Language
php5-bz2-5.3.10_1 The bz2 shared extension for php
php5-ctype-5.3.10_1 The ctype shared extension for php
php5-dom-5.3.10_1 The dom shared extension for php
php5-exif-5.3.10_1 The exif shared extension for php
php5-extensions-1.6 A "meta-port" to install PHP extensions
php5-fileinfo-5.3.10_1 The fileinfo shared extension for php
php5-filter-5.3.10_1 The filter shared extension for php
php5-hash-5.3.10_1 The hash shared extension for php
php5-iconv-5.3.10_1 The iconv shared extension for php
php5-json-5.3.10_1 The json shared extension for php
php5-mysql-5.3.10_1 The mysql shared extension for php
php5-openssl-5.3.10_1 The openssl shared extension for php
php5-pdo-5.3.10_1 The pdo shared extension for php
php5-pdo_sqlite-5.3.10_1 The pdo_sqlite shared extension for php
php5-phar-5.3.10_1 The phar shared extension for php
php5-posix-5.3.10_1 The posix shared extension for php
php5-session-5.3.10_1 The session shared extension for php
php5-simplexml-5.3.10_1 The simplexml shared extension for php
php5-sqlite-5.3.10_1 The sqlite shared extension for php
php5-sqlite3-5.3.10_1 The sqlite3 shared extension for php
php5-tokenizer-5.3.10_1 The tokenizer shared extension for php
php5-xml-5.3.10_1 The xml shared extension for php
php5-xmlreader-5.3.10_1 The xmlreader shared extension for php
php5-xmlwriter-5.3.10_1 The xmlwriter shared extension for php
php5-zlib-5.3.10_1 The zlib shared extension for php
--------
Code:
behemoth# php -v
PHP 5.3.10 with Suhosin-Patch (cli) (built: Mar 9 2012 01:07:52)
Copyright (c) 1997-2012 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies
with eAccelerator v0.9.6.1, Copyright (c) 2004-2010 eAccelerator, by eAccelerator
--------
Code:
behemoth# cat /usr/local/etc/php/extensions.ini
extension=eaccelerator.so
extension=dom.so
extension=bz2.so
extension=ctype.so
extension=exif.so
extension=fileinfo.so
extension=filter.so
extension=mysql.so
extension=hash.so
extension=iconv.so
extension=json.so
extension=openssl.so
extension=pdo.so
extension=pdo_sqlite.so
extension=phar.so
extension=posix.so
extension=sqlite3.so
extension=tokenizer.so
extension=xml.so
extension=xmlwriter.so
extension=zlib.so
extension=xmlreader.so
--------
Code:
behemoth# php -m
[PHP Modules]
bz2
Core
ctype
date
dom
eAccelerator
ereg
exif
fileinfo
filter
hash
iconv
json
libxml
mhash
mysql
mysqlnd
openssl
pcre
PDO
pdo_sqlite
Phar
posix
Reflection
SPL
sqlite3
standard
tokenizer
xml
xmlreader
xmlwriter
zlib
[Zend Modules]
eAccelerator
-----
Code:
behemoth# php --ini
Configuration File (php.ini) Path: /usr/local/etc
Loaded Configuration File: /usr/local/etc/php.ini
Scan for additional .ini files in: /usr/local/etc/php
Additional .ini files parsed: /usr/local/etc/php/extensions.ini
------