开发者

XAMPP / WAMP / whatever it is: Apache is running super slow [closed]

Closed. This question is off-topic. It is not currently accepting answers.
开发者_如何转开发

Want to improve this question? Update the question so it's on-topic for Stack Overflow.

Closed 11 years ago.

Improve this question

I've got my Windows PC (localhost) running XAMPP. It loads the pages sometimes really quick or sometimes really slow.

So, I figured and searched and was recommended to get WAMP. I got that and installed it. Still, the pages load so damn slowly. No heavy CPU load or anything, all my ports are open too.

Any ideas?


Here's a solution that really worked for me.

One thing to try is changing the following two entries in apache/conf/httpd.conf from OFF to ON:

EnableMMAP on
EnableSendfile on

Also, enable and set realpath_cache_size= 4m to your php.ini file.

If your are using InnoDB database also enable and set in my.ini:

innodb_flush_log_at_trx_commit = 2

Finally, it seems it worked for some people: edit your host (C:\Windows\System32\drivers\etc\hosts) by adding

127.0.0.1 localhost
127.0.0.1 127.0.0.1

And commenting:

\# ::1 localhost


Try to add this lines to hosts file:

127.0.0.1 127.0.0.1

127.0.0.1 localhost

and comment this line:

# ::1 localhost

You can find hosts file under: C:\Windows\System32\drivers\etc


Very slow is a very general problem, but it happened for me when I first installed IIS to run alongside apache, and also after I did a windows update (config was reset?)

Anyhow, what happened was that IIS started conflicting with Apache on port 443 (SSL) and so I had to use the follow command to disable SSL on IIS so that Apache would run fast again:

c:\inetpub\adminscripts\>adsutil set w3svc/1/securebindings "::"

Hope this helps.

edit: I also found that if I had ColdFusion installed and the service timed out during startup apache would run really slow. If you have ColdFusion installed, run services.msc and check to see if the main service is running. If that works, try adjusting your startup time ( http://www.ahphosting.net/support/Customer/KBArticle.aspx?articleid=23 ) so it will start automatically on the next reboot.


Oddly, the IP hosts/address change did the trick to me.

I'm on XP, and have had "127.0.0.1 localhost" in my hosts file forever.

Recently (maybe after some Windows updates, maybe after adding other application directories to my xampp htdocs, maybe after installing something else that conflicts with those ports?) pages - even simple HTML pages - started loading extremely slowly.

Merely commenting out the "127.0.0.1 localhost" line in my hosts file seems to have done the trick - now pages are loading consistently quickly.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜