Apache very slow to respond on windows server

时间:2017-05-16 09:26:46

标签: php apache

Apache 2.4 is very slow to respond on my windows server SBS 2011 to serve a complicated php script that takes a lot of files and database queries and outputs it. It should take 1-2 seconds but takes 5-7 seconds.

I edited hosts.conf to have mappings

127.0.0.1 localhost intranet
192.168.0.235 intranet

disabled ipv6, disabled firewall, added listen option

Listen 0.0.0.0:80

added the filter options to httpd conf

AcceptFilter http none 
AcceptFilter https none 
EnableSendfile off 
EnableMMAP on 

added:

ServerName 192.168.0.235:80

checked all my requests, it does nothing really except serve pages for the intra net, no heavy load, like 1 request per minute.

Yet a page takes 5 seconds to render, but on another server it renders within 2 seconds whilst that other server is more underpowered and has the exact same config AND hosts the database both apache servers use.

What am I missing here?

1 个答案:

答案 0 :(得分:3)

If you've done all that google has told you to do and the issue still exists, check if xdebug or another debugger is enabled.

As soon as I commented xdebug in php.ini and restarted the apache process it went lightning fast.