php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #5243 Could not start apache 1.3.12 Returncode 3
Submitted: 2000-06-28 08:09 UTC Modified: 2001-01-03 09:06 UTC
From: alf dot nicolaysen at gmx dot de Assigned:
Status: Closed Package: Reproducible Crash
PHP Version: 4.0 Release Candidate 2 OS: AIX 4.2.1
Private report: No CVE-ID: None
 [2000-06-28 08:09 UTC] alf dot nicolaysen at gmx dot de
Under AIX 4.2.1 Maintenance Level 6 I compiled first the newest apache 1.3.12 with DSO-Support (not gcc but xlC).

Second I changed in sourcecode of php the dlerror definition to avoid the compile problem described in further. Then I compiled with apxs-support and all went well beside a bunch of warnings about wrong prefixes in files (earlier described in buglist)

When all was finished, I tried to start the apache and it just says: httpd could not be started (ExitCode 3)

Another try with ./httpd -X exits with exitcode 6

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-06-30 01:15 UTC] alf dot nicolaysen at gmx dot de
Tried to compile the same but static, exactly same strange behavior.
Not even a log file is created.
 [2000-07-26 01:57 UTC] waldschrott@php.net
Please verify that it?s still happening using the latest version of PHP (release 4.0.1pl2 or CVS).
 [2000-08-18 05:45 UTC] alf dot nicolaysen at gmx dot de
Thanx for reply. But Sorry, no changes in behaviour. Initiated new test with:

IBM HTTP Server (which is in fact a precompiled apache 1.3.12)
gcc 2.95.2
AIX 4.2.1

Building as a shared object, no results so far.
 [2000-08-18 08:17 UTC] alf dot nicolaysen at gmx dot de
Compiled the following:

PHP4.0 Relase Candidate 2
IBM HTTP Server (Apache 1.3.12 precompiled)
gnu-gcc-2.95.2

First Try failed with error: File not found in os.h:81 os-inline.c.
This file I unpacked from the ./apachesrc-DIR and put it in the inlude dir of my WebServer.  After that the compile runs through, but the start of the WebServer results in a coredump, where the details are below.

First my configure line:

# CC=gcc ./configure --with-mysql --enable-shared --enable-libgcc --with-apxs=/usr/HTTPServer/bin/apxs --prefix=/usr
# make
# make install
# apachectl start 
Segmentation Fault (Coredump)

# dbx httpd (Here comes the debugoutput)
.warning: Unable to access address 0x20245c64 from core
warning: Unable to access address 0x20245c64 from core
warning: Unable to access address 0x20245c68 from core
warning: Unable to access address 0x20245c68 from core
warning: Unable to access address 0x20245c6c from core
warning: Unable to access address 0x20245c6c from core
warning: Unable to access address 0x20245c70 from core
warning: Unable to access address 0x20245c70 from core
warning: Unable to access address 0x20245c74 from core
warning: Unable to access address 0x20245c74 from core
warning: Unable to access address 0x20245c78 from core
warning: Unable to access address 0x20245c78 from core
warning: Unable to access address 0x20245c7c from core
warning: Unable to access address 0x20245c7c from core
warning: no source compiled with -g

[using memory image in core]
warning: Unable to access address 0xf01875d8 from core

Segmentation fault in php_if_apache_lookup_uri at 0xd14c311c
0xd14c311c (php_if_apache_lookup_uri+0x4c4) 800c0000        lwz   r0,0x0(r12)

(dbx) where
php_if_apache_lookup_uri() at 0xd14c311c
php_create_dir(??, ??) at 0xd14c4498
ap_single_module_configure(??, ??, ??) at 0x10024050
load_module(??, ??, ??, ??) at 0x1004b72c
invoke_cmd(0x100325b0, 0x0, 0x0, 0x2ff209b0) at 0x10021a50
ap_handle_command(??, ??, ??) at 0x10022a50
ap_srm_command_loop(??, ??) at 0x10024120
ap_process_resource_config(??, ??, ??, ??) at 0x100232bc
ap_read_config(??, ??, ??) at 0x10023f54
http_main.main(??, ??) at 0x10001804

 [2000-08-20 04:06 UTC] sniper@php.net
Does this problem still persist with more recent version of php (from CVS or http://snaps.php.net) ??

--Jani
 [2000-08-21 02:38 UTC] alf dot nicolaysen at gmx dot de
Same behaviour with newset version from snaps.php.net, which was

php4-200008202145

vera:/usr/HTTPServer/bin # dbx httpd
Type 'help' for help.
reading symbolic information ...warning: no source compiled with -g

[using memory image in core]

Segmentation fault in php_if_apache_lookup_uri at 0xd16b8918 ($t1)
0xd16b8918 (php_if_apache_lookup_uri+0x4c4) 800c0000        lwz   r0,0x0(r12)
(dbx) where
php_if_apache_lookup_uri() at 0xd16b8918
php_create_dir(??, ??) at 0xd16b9bb8
ap_single_module_configure(??, ??, ??) at 0x10024050
load_module(??, ??, ??, ??) at 0x1004b72c
invoke_cmd(0x100325b0, 0x0, 0x0, 0x2ff209a0) at 0x10021a50
ap_handle_command(??, ??, ??) at 0x10022a50
ap_srm_command_loop(??, ??) at 0x10024120
ap_process_resource_config(??, ??, ??, ??) at 0x100232bc
ap_read_config(??, ??, ??) at 0x10023f54
http_main.main(??, ??) at 0x10001804
(dbx) quit

 [2000-08-21 14:14 UTC] sniper@php.net
Have you tried to compile Apache by yourself from sources?

--Jani

 [2000-08-24 06:25 UTC] alf dot nicolaysen at gmx dot de
Yes, even with the above mentioned version of php and a new compiled apache1.3.12 I am back at the first entry of this bug report:


# /opt/apache_php/bin/apachectl start
/opt/apache_php/bin/apachectl start: httpd could not be started
# echo $?
3

No entries in error_log, even in debug mode. Sorry, no further details I can deliver. If you have some hints for debugging the (not)starting of the apache, I would appreciate.
 [2000-08-25 01:59 UTC] alf dot nicolaysen at gmx dot de
Yes, I started the apache as root. The strace under AIX is not the same as under LINUX, so that won?t help. E-Mailed instead the output from sctrace, which is a system-Call tracer for AIX
 [2000-08-29 06:40 UTC] alf dot nicolaysen at gmx dot de
Once again I tried to compile the php on a brand new installed 4.3.3 machine with a new compiled apache 1.3.12 and gcc.

Here is the output of the compile:

# CC='gcc' ./configure --with-apxs=/opt/apache/bin/apxs --prefix=/usr
# make
.
.
.
Making all in libmysql
        /bin/sh /usr/sys/inst.images/php4-200008202145/libtool --silent --mode=compile gcc  -I. -I/usr/sys/inst.images/php4-200008202145/ext/mysql/libmysql -I/usr/sys/inst.images/php4-200008202145 -I/usr/sys/inst.images/php4-200008202145/main -I/opt/apache/include -I/usr/sys/inst.images/php4-200008202145/Zend -I/usr/sys/inst.images/php4-200008202145 -I/usr/sys/inst.images/php4-200008202145/ext/mysql/libmysql -I/usr/sys/inst.images/php4-200008202145/ext/xml/expat/xmltok -I/usr/sys/inst.images/php4-200008202145/ext/xml/expat/xmlparse  -DXML_BYTE_ORDER=21 -O2  -c libmysql.c
In file included from libmysql.c:11:
global.h:484: conflicting types for `int8'
/usr/include/sys/inttypes.h:622: previous declaration of `int8'
global.h:485: warning: redefinition of `int16'
/usr/include/sys/inttypes.h:623: warning: `int16' previously declared here
global.h:495: warning: redefinition of `int32'
/usr/include/sys/inttypes.h:624: warning: `int32' previously declared here
make: 1254-004 The error code from the last command is 1.


Stop.
make: 1254-004 The error code from the last command is 1.


Stop.
make: 1254-004 The error code from the last command is 1.


Stop.
make: 1254-004 The error code from the last command is 1.


Stop.
make: 1254-004 The error code from the last command is 1.


Stop.

 [2000-08-29 11:49 UTC] dshafer@php.net
There are known problems with the distributed MySQL source and AIX. Try configuring either without the included MySQL support (--without-mysql) or with a known working MySQL installation (--with-mysql=DIR) to bypass the MySQL errors.
 [2000-08-30 04:56 UTC] alf dot nicolaysen at gmx dot de
Okay, started once again with the yesterday released php4.0.2 and apache_1.3.12:

 CC='gcc' ./configure --with-apxs=/opt/apache/bin/apxs --prefix=/usr --without-mysql 

then

make and 
make install

Once again I got a coredump, where the debugger output you can see below.. It is always in function php_if_apache_lookup_uri. What is the trick??

# dbx ./httpd
Geben Sie 'help' ein, um die Hilfefunktion aufzurufen.
Symbolische Informationen werden gelesen...Warnung: Es wurde kein Quellenwert mit -g kompiliert.

[Hauptspeicherabbild in core wird verwendet]

Segmentation fault in php_if_apache_lookup_uri at 0xd12596f8
0xd12596f8 (php_if_apache_lookup_uri+0x4d8) 800c0000        lwz   r0,0x0(r12)
(dbx) where
php_if_apache_lookup_uri() at 0xd12596f8
php_create_dir(??, ??) at 0xd125aadc
ap_single_module_configure(0x2001f6e8, 0x2001f710, 0x2006e2d0) at 0x1002fe84
load_module(0x2ff22a08, 0x0, 0x20020d40, 0x20020d50) at 0x1007d354
invoke_cmd(0x20015f58, 0x2ff22a08, 0x0, 0x2ff209e0) at 0x1002d2fc
ap_handle_command(0x2ff22a08, 0x200202a0, 0x2ff209b0) at 0x1002e510
ap_srm_command_loop(0x2ff22a08, 0x200202a0) at 0x1002ff24
ap_process_resource_config(0x2001f710, 0x20020be0, 0x2001f6e8, 0x20023728) at 0x1002ef88
ap_read_config(0x2001f6e8, 0x20023728, 0x20005598) at 0x1002fd78
http_main.main(0x1, 0x2ff22c00) at 0x10000714

 [2000-12-18 11:13 UTC] sniper@php.net
Does this happen with latest snapshot from http://snaps.php.net/ ??

--Jani
 [2001-01-03 08:58 UTC] alf dot nicolaysen at gmx dot de
So, I gave a final try and it worked!!!! What happened?

In the meantime , PHP 4.0.4 was released. So I used that with AIX 4.3.3 Maint Level 5, a new compiled GNU-gcc and GNU-make. 

I used the same configure line, but beside the further mentioned dlerror decl. and os-inlne.c error I followed the workaround described in BugReport 4630. 

You should mention, that the described $PHP4/libtool is named $PHP4/ltconfig (That is not obvious)

So, I changed the lines in the aix4 section to the following:  


 archive_cmds="\$CC $shared_flag"' -o $objdir/$soname $libobjs $deplibs $linkopts ${wl}-bexpall ${wl}-bnoen
try${allow_undefined_flag} ${wl}-bI:/usr/HTTPServer/apachesrc/apache-1.3/src/support/httpd.exp'
    archive_expsym_cmds="\$CC $shared_flag"' -o $objdir/$soname $libobjs $deplibs $linkopts ${wl}-bE:$export_s
ymbols ${wl}-bnoentry${allow_undefined_flag} ${wl}-bI:/usr/HTTPServer/apachesrc/apache-1.3/src/support/httpd.e
xp'

then

configure ......
make
make install

amd minimum <?php phpinfo() ?> worked. First time. Thanks for the help.
 [2001-01-03 09:06 UTC] jmoore@php.net
User reports bug fixed with work around
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat May 04 18:01:32 2024 UTC