Bug #14333 Updated: Apache processes consume all CPU
| From: | tauren at servlets dot net | Date: | Sun, 09 Dec 2001 00:19:43 +0000 |
| Subject: | Bug #14333 Updated: Apache processes consume all CPU | ||
| References: | 1 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-73159@lists.php.net to get a copy of this message | ||
ID: 14333
User updated by: tauren@servlets.net
Reported By: tauren@servlets.net
Old Status: Feedback
Status: Open
Bug Type: Apache related
Operating System: RH 6.2 SMP
PHP Version: 4.0.6
New Comment:
Thanks for the help. I've installed the MySQL-shared RPM and now have
/usr/lib/libmysqlclient.so.
Also, I've recompiled with a minimal PHP configuration:
CPPFLAGS=-I/usr/local/include
LDFLAGS=-L/usr/local/lib
./configure --prefix=/usr/local \
--with-apache=/root/atb/Apachetoolbox-1.5.45/apache_1.3.22 \
--enable-exif \
--enable-track-vars \
--with-calendar=shared \
--enable-safe-mode \
--enable-magic-quotes \
--enable-trans-sid \
--enable-wddx \
--enable-ftp \
--with-mysql=/usr \
--with-ldap \
My Apache configuration is also very minimal. The only things I have included are the basics plus
mod_ssl and mod_php:
export CFLAGS=""
export LIBS=""
export INCLUDES=""
./configure --prefix=/usr/local/apache \
--enable-suexec \
--suexec-caller=nobody \
--suexec-docroot=/home \
--suexec-logfile=/var/log/httpd/cgi.log \
--suexec-uidmin=500 \
--suexec-gidmin=500 \
--suexec-safepath=/usr/local/bin:/usr/bin:/bin \
--enable-module=so \
--enable-module=access \
--disable-module=auth_db \
--disable-module=digest \
--enable-module=imap \
--enable-module=mime \
--enable-module=setenvif \
--disable-module=usertrack \
--enable-module=auth \
--disable-module=cern_meta \
--disable-module=expires \
--enable-module=log_config \
--disable-module=proxy \
--disable-module=vhost_alias \
--disable-module=auth_anon \
--enable-module=cgi \
--disable-module=headers \
--disable-module=log_referer \
--disable-module=rewrite \
--enable-module=userdir \
--enable-module=asis \
--enable-module=autoindex \
--disable-module=example \
--disable-module=log_agent \
--enable-module=negotiation \
--enable-module=status \
--enable-module=actions \
--disable-module=auth_dbm \
--enable-module=dir \
--enable-module=include \
--disable-module=mime_magic \
--disable-module=unique_id \
--enable-module=alias \
--disable-module=auth_digest \
--enable-module=env \
--disable-module=info \
--disable-module=mmap_static \
--disable-module=speling \
--enable-module=ssl \
--activate-module=src/modules/php4/libphp4.a \
However, as within a minute of installing and running this Apache, I start getting runaway httpd
processes (94% CPU usage).
It doesn't look like the libmysqlclient.so is the issue. I'm going to try installing with
the --without-mysql option to see if that makes a difference.
Previous Comments:
------------------------------------------------------------------------
[2001-12-08 10:14:24] derick@php.net
The RPm is called MySQL-shared BTW.
------------------------------------------------------------------------
[2001-12-08 10:12:49] sniper@php.net
What would help us to narrow down the possible places where
this bug might be is that you build PHP with minimal amount of
extensions ie. remove all the options and leave only the apache
option there.
--Jani
------------------------------------------------------------------------
[2001-12-08 05:14:21] tauren@servlets.net
I just installed the MySQL-devel-3.23.40-1.i386.rpm RPM. It installed the following files:
[root@s1 lib]# rpm -q -l MySQL-devel
/usr/bin/comp_err
/usr/bin/mysql_config
/usr/include/mysql
/usr/include/mysql/chardefs.h
/usr/include/mysql/dbug.h
/usr/include/mysql/errmsg.h
/usr/include/mysql/history.h
/usr/include/mysql/keymaps.h
/usr/include/mysql/m_ctype.h
/usr/include/mysql/m_string.h
/usr/include/mysql/my_config.h
/usr/include/mysql/my_global.h
/usr/include/mysql/my_list.h
/usr/include/mysql/my_net.h
/usr/include/mysql/my_no_pthread.h
/usr/include/mysql/my_pthread.h
/usr/include/mysql/my_sys.h
/usr/include/mysql/mysql.h
/usr/include/mysql/mysql_com.h
/usr/include/mysql/mysql_version.h
/usr/include/mysql/mysqld_error.h
/usr/include/mysql/raid.h
/usr/include/mysql/readline.h
/usr/include/mysql/sslopt-case.h
/usr/include/mysql/sslopt-longopts.h
/usr/include/mysql/sslopt-usage.h
/usr/include/mysql/sslopt-vars.h
/usr/include/mysql/tilde.h
/usr/lib/mysql
/usr/lib/mysql/libdbug.a
/usr/lib/mysql/libheap.a
/usr/lib/mysql/libmerge.a
/usr/lib/mysql/libmyisam.a
/usr/lib/mysql/libmyisammrg.a
/usr/lib/mysql/libmysqlclient.a
/usr/lib/mysql/libmysqlclient.la
/usr/lib/mysql/libmystrings.a
/usr/lib/mysql/libmysys.a
/usr/lib/mysql/libnisam.a
There isn't a libmysqlclient.so in this list, but there is a libmysqlclient.a. However, it is
in /usr/lib/mysql.
What line should I use to configure PHP? Is it still:
--with-mysql=/usr
Or would it be:
--with-mysql=/usr/lib/mysql
Or something else?
Thanks!
------------------------------------------------------------------------
[2001-12-05 01:26:37] derick@php.net
If you use other module for apache, then PHP only, you _must_ use the MySQL libraries that are
installed on your system, but not the bundled once. You should indeed try if --without-mysql would
work for you. (Simply leaving out --with-mysql does not work, it's on by default).
Derick
------------------------------------------------------------------------
[2001-12-04 17:57:03] tauren@servlets.net
I can't find the libmysqlclient.so file on my system (and definitely not in /usr/lib).
MySQL-3.23.40-1
was installed from RPM, not from ApacheToolbox. I don't think I've installed the
MySQL-devel package.
Do you think this has something to do with the PHP problem? I could try compiling it without the
--with-mysql to see if that helps at all.
Were the backtraces helpful at all?
Thanks again for the help!
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/?id=14333
Edit this bug report at http://bugs.php.net/?id=14333&edit=1