Solaris 8 , Apache 1.3.26 , php-4.3.1 install problems
| From: | Garrett, Matt M SITI-ITDIEEE | Date: | Tue, 27 May 2003 12:54:53 +0000 |
| Subject: | Solaris 8 , Apache 1.3.26 , php-4.3.1 install problems | ||
| Groups: | php.install | ||
| Request: | Send a blank email to php-install+get-10968@lists.php.net to get a copy of this message | ||
Folks
I have build PHP 4.3.1 quite happily using
./configure --with-apxs=/local/apache/bin/apxs --prefix=/local/php4
--with-config-file-path=/local/php4/lib
Done make , make install
Added the following to httpd.conf file
LoadModule php4_module libexec/libphp4.so
ScriptAlias /php/ /local/apache/php/
AddType application/x-httpd-php .php
<Directory "/local/apache/php">
AllowOverride None
Options ExecCGI
Order allow,deny
Allow from all
</Directory>
I have done a stop / start of apache which reports
[Tue May 27 11:30:05 2003] [notice] Apache/1.3.26 (Unix) PHP/4.3.1 mod_fastcgi/2.2.12 mod_perl/1.27
configured -- resuming normal operations
So all looks fine
A very simple php test program e.g test.php
<?phpinfo(); ?>
Doing /local/php4/bin/php test.php
Works fine
However from the web e.g http://server/php/test.php
I get the following web error
Internal Server Error
The apache error log shows the following
[Tue May 27 13:44:53 2003] [error] (8)Exec format error: exec of /local/apache/php/test.php failed
[Tue May 27 13:44:53 2003] [error] [client IP.IP.IP.IP] Premature end of script headers:
/local/apache/php/test.php
If I change the test.php file to look like
#!/local/php4/bin/php
<?phpinfo(); ?>
I get the error log file showing
[Tue May 27 13:47:52 2003] [error] [client IP.IP.IP.IP] malformed header from script. Bad
header=phpinfo(): /local/apache/php/test.php
I know I am doing something really stupid but just can not find the answer.
Any idea
Thanks
Matt
Matthew Garrett
Unix System Support
Shell Information Technology International Limited
Seafield House, North Anderson Drive, Aberdeen AB15 6GZ, United Kingdom
Tel: +44 (0)1224 81 8373 Other Tel: Internal 630 8373
Email: Matt.M.Garrett@is.shell.com
Internet: http://www.shell.com