Bug #60274 [Opn->Fbk]: cpu steady on httpd processes never clears
| From: | sixd@php.net | Date: | Tue, 28 Feb 2012 18:39:15 +0000 |
| Subject: | Bug #60274 [Opn->Fbk]: cpu steady on httpd processes never clears | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-167924@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=60274&edit=1
ID: 60274
Updated by: sixd@php.net
Reported by: jwprice at georgiasouthern dot edu
Summary: cpu steady on httpd processes never clears
-Status: Open
+Status: Feedback
Type: Bug
-Package: Performance problem
+Package: OCI8 related
Operating System: Solaris 10
PHP Version: 5.3.8
-Assigned To:
+Assigned To: sixd
Block user comment: N
Private report: N
New Comment:
This bug just came to my attention and I've now changed the package from
"Performance" to "OCI8".
How are you measuring CPU load? How is Apache configured and what is the system
configuration? Are httpd process spinning? Are they being cycled? 600 processes
seems a large number for a single commodity machine. One old rule of thumb was
to set maxclients to 25 for a 1Gb, 2-core machine. Look at reducing maxclients
and using persistent OCI8 connections. If possible, use Oracle 11g DRCP
connections.
I'd recommend upgrading the Oracle client by using the free Oracle Instant
Client. Use the latest version that can still connect back to your DB.
The current PHP OCI8 hasn't had any particularly relevant changes since 5.3.4.
Make sure the code uses binds, prefetches, etc. effectively. Check the
performance tips in
http://www.oracle.com/technetwork/topics/php/underground-php-oracle-manual-
098250.html
Previous Comments:
------------------------------------------------------------------------
[2011-11-11 21:21:27] jwprice at georgiasouthern dot edu
Description:
------------
During a busy time over 600 httpd processes on the webserver and oracle database
cpu load over 88. The cpu load on each httpd process climbs to 3 and 4 % over
loading our server forcing cpuloads of > 200 on the webserver. After load on the
database clears usually in about 15 min, the httpd process never clear their cpu
usage even after a week of no activity. The cpu load on the httpd processes
usally ranges from .4 to 0%. The cpu load problem on the webserver is definitely
related to slowness on the oracle database side, but what concerns me is the
apache server never clears itself. I suspect there is some issue with the oci
functionality.
I'm reporting this before upgrading to the latest version because i don't see
any fixes related. We are using php version 5.3.4. Configure script below.
Home=/portal
ApacheStdName=httpd-
ApacheVer=2.2.17
PHPVer=5.3.4
PHPStdName=php-
OracleClientHome=/oraclient/ora920
MysqlHome=/usr/local/mysql
ModSSLStdName=mod_ssl-
ModSSLVer=2.8.22-1.3.33
cd ${Home}/${PHPStdName}${PHPVer}
./configure \
--prefix=${Home}/local \
--with-apxs2=${Home}/server/bin/apxs \
--with-gettext \
--enable-ftp \
--with-openssl=/usr/local/ssl \
--with-mysql=${MysqlHome} \
--with-pear=${HOME}/pear \
--enable-cli \
--disable-cgi \
--with-curl \
--with-mcrypt=/usr/local \
--with-zlib \
--with-zlib-dir=/usr/local \
--with-jpeg-dir=/usr/local \
--with-png-dir=/usr/local \
--with-xpm-dir=/usr/local \
--with-freetype-dir=/usr/local \
--enable-gd-native-ttf \
--with-ttf=/usr/local \
--with-gd \
--with-ldap=/usr/local \
--with-oci8=${OracleClientHome} \
--with-config-file-path=${Home}/etc
Test script:
---------------
We use
oci_connect
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=60274&edit=1