Re: flock and lseek issues
Re: flock and lseek issues
- Subject: Re: flock and lseek issues
- From: Jeremy Bush <email@hidden>
- Date: Mon, 26 Sep 2005 14:48:05 -0500
I installed the APD php profiler and got the following output:
==========================================
www:/usr/lib/php admin$ sudo pprofp -ucO 100
/Volumes/WebData/gallery2/flexicoil/pprof.05091
Trace for /Volumes/WebData/WebData/Documents/gallery2_flexicoil/main.php
Total Elapsed Time = 5.84
Total System Time = 1.05
Total User Time = 0.20
Real User System secs/ cumm
%Time (excl/cumm) (excl/cumm) (excl/cumm) Calls call s/call
Memory Usage Name
--------------------------------------------------------------------------------------
25.0 2.19 4.80 0.05 0.14 0.32 0.84 46 0.0011 0.0030 0
require_once
20.0 0.95 0.95 0.04 0.04 0.20 0.20 65 0.0006 0.0006 0
dirname
10.0 0.65 0.65 0.02 0.02 0.06 0.06 14 0.0014 0.0014 0
defined
10.0 0.54 0.54 0.02 0.02 0.09 0.09 83 0.0002 0.0002 0
define
10.0 0.46 0.55 0.02 0.04 0.14 0.21 12 0.0017 0.0033 0
include
5.0 0.00 0.00 0.01 0.01 0.00 0.00 1 0.0100 0.0100 0
gallery->gettranslator
5.0 0.00 0.00 0.01 0.01 0.00 0.00 1 0.0100 0.0100 0
serialize
5.0 0.00 0.00 0.01 0.01 0.00 0.00 38 0.0003 0.0003 0
sizeof
5.0 0.00 0.00 0.01 0.01 0.01 0.01 110 0.0001 0.0001 0
str_replace
5.0 0.46 0.46 0.01 0.01 0.13 0.13 8 0.0013 0.0013 0
fopen
===================================
It seems to get stuck up on require_once, but it doesnt really help me
solve the problem. I think disk access is being the bottleneck, but I am
not sure where to go from there.
Jeremy Bush
Image Management LLC
262-898-9137
http://www.imagemanagement.ws
AgentM wrote:
Tracing is different from profiling- you really should use Shark in the
CHUD tools to attach to the process to figure out what is really going
on. It could be that the time is sucked up mostly in user- space. If
there is some way to profile PHP using PHP tools, I would recommend
that as well so you can figure out which PHP function is using up the
most time.
Are you using the same versions of the software (Apache+PHP+Gallery
software) on both machines? Be sure you are comparing Apples to Apples.
Perhaps your Apache setup is less than optimal for the scripts you are
running on Tiger?
On Sep 26, 2005, at 11:02 AM, Jeremy Bush wrote:
Hi, all not sure if this is the correct place to post this, but here
goes.
Im using a php application called gallery2, and I recently installed
Tiger on our webserver, an XServe G5. It now run extremely slow,
usualy taking 10-15 seconds to return a html page to the client.
During this time, httpd processes spawn and take the 10-15 seconds to
finish. I started doin ktraces on the httpd processes and sotring the
kdump by time, I saw many flock() calls taking .5 -.75 seconds each.
In the G2 app, I can change the locking from file locking to database
locking, so I changed that setting. This took about 5 seconds off of
the process time, but it is still taking 5-6 seconds to return a page.
Currently, ktrace/kdump shows many lseek() calls taking .3-.4 seconds
each.
Some notes:
1. This only happens on Tiger server. Panther server runs fine.
2. I have tried different web server, such as lighttpd, to the same
result.
3. The gallery developers did not have much awnsers for me, simply
saying, "your disk access is very slow"
Tiger kdump link: www.imagemanagement.ws/kdump.out
Tiger G2 link: www.imagemanagement.ws/gallery2
Panther G2 link: www3.imagemanagement.ws/gallery2
Are there known issues with flock or lseek on Tiger? Any insight on
how I can get this to run at an acceptable speed?
--
Jeremy Bush
Image Management LLC
262-898-9137
http://www.imagemanagement.ws
<jeremy.vcf>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40themactionfaction.com
This email sent to email@hidden
|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-
AgentM
email@hidden
|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-|-
begin:vcard
fn:Jeremy Bush
n:Bush;Jeremy
org:Image Management LLC
adr;dom:Suite 200;;610 Main St;Racine;Wi;53403
email;internet:email@hidden
title:Web Master
tel;work:262-898-9137
tel;fax:262-898-9138
url:http://www.imagemanagement.ws
version:2.1
end:vcard
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden