I have an Apache 2.2 server offering up PhpBB3. Everything is working smoothly on that system. But, I am trying to migrate the database as well as the PhpBB3 page to another server for testing and such.
I used the Doc from the PhpBB website to do the transfer
http://www.phpbb.com/kb/article/transferring-your-board-to-a-new-host-or-domain/
Everything went according to plan until I transfered the actual documents from the original server to the 'test' server. All I get is a blank screen. I have been tirelessly scouring the Internet for a solution to the problem without avail.
Finally, I am turning to the experts here.
I will lay out my original and then my test server layouts.
"Hubert" -- Working server.
Php module is loaded:
System works fine!
Now for the test server - "Zap" (Yes, all the servers here are named after Futurama characters)
when I point my browser to zap.mydomain.com, all I get is a blank screen. I added a php file to the root directory with the following contents to test the php.
I get this:
And when I point to index.php, if I view source, I get this:
Like, I said. I have been at this for days and am not sure what to make of it. Any assistance will be greatly appreciated.
I used the Doc from the PhpBB website to do the transfer
http://www.phpbb.com/kb/article/transferring-your-board-to-a-new-host-or-domain/
Everything went according to plan until I transfered the actual documents from the original server to the 'test' server. All I get is a blank screen. I have been tirelessly scouring the Internet for a solution to the problem without avail.
Finally, I am turning to the experts here.
I will lay out my original and then my test server layouts.
"Hubert" -- Working server.
Code:
[root@hubert]/usr/local/etc/apache22-> httpd -v
Server version: Apache/2.2.22 (FreeBSD)
Php module is loaded:
Code:
[root@hubert]/usr/local/etc/apache22-> httpd -M
Loaded Modules:
- snip -
php5_module (shared)
Syntax OK
[root@hubert]/usr/local/etc/apache22->
Code:
#
# This is the main Apache HTTP server configuration file. It contains the
- snip -
LoadModule php5_module libexec/apache22/libphp5.so
-snip -
################ Virtual Hosts ##################
<VirtualHost *>
ServerName www.somedomain.net>
DocumentRoot /usr/www/somedomain.net
<Directory /music>
AllowOverride None
Order allow,deny
Allow from all
</Directory>
<Directory /apps>
AllowOverride None
Order allow,deny
Allow from all
</Directory>
<Directory /video>
AllowOverride None
Order allow,deny
Allow from all
</Directory>
<Directory /phpBB3>
AllowOverride None
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
<VirtualHost *>
ServerName www.anotherdomain.com
DocumentRoot /usr/www/anotherdomain.com
<Directory />
AllowOverride None
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
#################### End Virtual Hosts #########################
<IfModule dir_module>
DirectoryIndex index.html index.php
</IfModule>
-snip-
DefaultType text/plain
-snip-
AddType application/x-compress .Z
AddType application/x-gzip .gz .tgz
AddType application/x-httpd-php .php
-snip-
</IfModule>
-snip-
Code:
[root@hubert]/usr/local/etc-> php -v
PHP 5.3.13 with Suhosin-Patch (cli) (built: May 21 2012 00:01:21)
Copyright (c) 1997-2012 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies
Code:
php.conf
PHP_VER=53
PHP_VERSION=5.3.13
PHP_SAPI=cli cgi mod
PHP_EXT_INC=pcre spl
Code:
[root@hubert]/usr/local/etc-> mysqladmin -uXXXXXXX -pXXXXXXX version
mysqladmin Ver 8.41 Distrib 4.1.25, for portbld-freebsd9.0 on i386
Copyright (C) 2000 MySQL AB & MySQL Finland AB & TCX DataKonsult AB
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL license
Server version 4.1.25
Protocol version 10
Connection Localhost via UNIX socket
UNIX socket /tmp/mysql.sock
Uptime: 2 days 17 hours 55 min 16 sec
Threads: 1 Questions: 9068 Slow queries: 0 Opens: 126 Flush tables: 1 Open tables: 64 Queries per second avg: 0.038
System works fine!
Now for the test server - "Zap" (Yes, all the servers here are named after Futurama characters)
Code:
[root@zap]/usr/local/etc-> httpd -v
Server version: Apache/2.2.22 (FreeBSD)
Server built: Jul 15 2012 18:59:51
You have new mail.
[root@zap]/usr/local/etc->
Code:
#
# This is the main Apache HTTP server configuration file. It contains the
# configuration directives that give the server its instructions.
# See <URL:http://httpd.apache.org/docs/2.2> for detailed information.
# In particular, see
# <URL:http://httpd.apache.org/docs/2.2/mod/directives.html>
# for a discussion of each configuration directive.
#
# Do NOT simply read the instructions in here without understanding
# what they do. They're here only as hints or reminders. If you are unsure
# consult the online docs. You have been warned.
#
# Configuration and logfile names: If the filenames you specify for many
# of the server's control files begin with "/" (or "drive:/" for Win32), the
# server will use that explicit path. If the filenames do *not* begin
# with "/", the value of ServerRoot is prepended -- so "/var/log/foo_log"
# with ServerRoot set to "/usr/local" will be interpreted by the
# server as "/usr/local//var/log/foo_log".
#
# ServerRoot: The top of the directory tree under which the server's
# configuration, error, and log files are kept.
#
# Do not add a slash at the end of the directory path. If you point
# ServerRoot at a non-local disk, be sure to point the LockFile directive
# at a local disk. If you wish to share the same ServerRoot for multiple
# httpd daemons, you will need to change at least LockFile and PidFile.
#
ServerRoot "/usr/local"
#
# Listen: Allows you to bind Apache to specific IP addresses and/or
# ports, instead of the default. See also the <VirtualHost>
# directive.
#
# Change this to Listen on specific IP addresses as shown below to
# prevent Apache from glomming onto all bound IP addresses.
#
#Listen 12.34.56.78:80
Listen 80
#
# Dynamic Shared Object (DSO) Support
#
# To be able to use the functionality of a module which was built as a DSO you
# have to place corresponding `LoadModule' lines at this location so the
# directives contained in it are actually available _before_ they are used.
# Statically compiled modules (those listed by `httpd -l') do not need
# to be loaded here.
#
# Example:
# LoadModule foo_module modules/mod_foo.so
#
-snip-
LoadModule php5_module libexec/apache22/libphp5.so
AddType application/x-httpd-php .php
-snip-
<IfModule dir_module>
DirectoryIndex index.html index.php
</IfModule>
-snip-
DefaultType text/plain
<IfModule mime_module>
-snip-
AddEncoding x-compress .Z
AddEncoding x-gzip .gz .tgz
AddType application/x-httpd-php .php
-snip-
Include etc/apache22/Includes/*.conf
Code:
[root@zap]/usr/local/etc-> php -v
PHP 5.3.14 with Suhosin-Patch (cli) (built: Jul 15 2012 22:17:03)
Copyright (c) 1997-2012 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies
[root@zap]/usr/local/etc->
when I point my browser to zap.mydomain.com, all I get is a blank screen. I added a php file to the root directory with the following contents to test the php.
Code:
<?php
ini_set('display_errors', 1);
error_reporting(E_ALL);
Echo "Line 1</br>";
$link = mysql_connect('localhost', 'XXXX', 'XXXX');
Echo "Line 2</br>";
?>
I get this:
Code:
Line 1
Fatal error: Call to undefined function mysql_connect() in /usr/www/test.php on line 5
And when I point to index.php, if I view source, I get this:
Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content="text/html; charset=windows-1252" http-equiv=Content-Type></HEAD>
<BODY></BODY></HTML>
Like, I said. I have been at this for days and am not sure what to make of it. Any assistance will be greatly appreciated.
