Page 1 of 1

apache server slow in serving php pages

Posted: Sat Nov 11, 2006 9:39 pm
by Hilan
I'm running my website on a server Apache/1.3.27 Unix Red-Hat/Linux PHP/4.3.11
Normal web page requests run fine, except when asking for a web page coded in php. It takes the server always from 10 to 20 seconds to respond to the first php page request.
Afterwards when the first php page is served, the server response is better and other php pages are served faster. Have not gotten any real good answers from any one why this happens. I'm told this is normal, which seems to me far fetched.

Posted: Sat Nov 11, 2006 10:56 pm
by feyd
Without knowing more about your configuration it's hard to say much. Is PHP run as a module or CGI? Do you have caching enabled anywhere? How is that caching set up? You said this happens during the first request. First request since the server has started? .. a new user session? .. after a period of time? .. at certain times? Does this behavior affect everyone, including those not on your network(s)? .. those not in your geographical area? .. those not on your service provider?

Posted: Sun Nov 12, 2006 12:30 am
by Hilan
First of all thank you for responding and taking your time

1.) php runs as a module.
2.) Compressing of text is handled in htaccess file with a low #2
3.)With first request, I mean a user session
4.)Local support people at the server site don't believe on my timing and don't see it. But I do and other ones too.
even my Rss reader times sometimes out on my feed.
5.)It's not the php coding as in Wordpress and Expression Engine the same problem occurs.
6.)I'm also told that the server takes that long as for the first user request there is no cache on the server, whatever that means.
hope that is somehow helpfull
Thank you

Posted: Sun Nov 12, 2006 4:00 am
by timvw
How does your httpd run? Is it running as a daemon, or is it started from inetd?

Posted: Sun Nov 12, 2006 9:58 am
by Hilan
The server httpd is run as a daemon process