Page 1 of 1

Apache fails to respond about 20% of the time

PostPosted: 18. September 2015 17:44
by maxnugget
Been having this problem for about a year, it's extremely frustrating.

When loading any page locally on my computer running XAMPP, about 20% of the time, Chrome (and other browsers) will just sit there with "Connecting..." in the status bar and eventually time out. Sometimes when it happens I have to reload the page like 5 times to get it to connect.

I've tried reinstalling XAMPP, upgrading to newer versions, etc. Cant' seem to figure anything out. I don't know where to start troubleshooting this. The timed-out requests are not appearing in any of the main Apache log files (access.log., error.log, php_errror.log). I'm totally stumped. I don't have this problem on my laptop install of XAMPP.

Any suggestions?

Re: Apache fails to respond about 20% of the time

PostPosted: 25. September 2015 00:13
by maxnugget
No responses? This is killing me...

Re: Apache fails to respond about 20% of the time

PostPosted: 25. September 2015 00:30
by JJ_Tagy
What AV are you using? Perhaps it stalls when checking safety of site.

Other thoughts: HDD, RAM, NIC.

Re: Apache fails to respond about 20% of the time

PostPosted: 25. September 2015 11:17
by Nobbie
Mostly problems of this kind happen due to certain hardware/software environments.

It may depend on the Xampp installation itself (where is Xampp installed?), it may depend on some network issues, it may depend on the installed PHP Scripts etc.pp. Unfortunately, you do not tell anything (not even one bit) about your environment, this makes it definately completely impossible to give any hint or clue. I really know NOTHING about your local installation.

Re: Apache fails to respond about 20% of the time

PostPosted: 25. September 2015 22:17
by melius2
It looks like a network issue, maybe a NAT problem, have you tried changing Apache default port from 80 to other to see if you can replicate the issue?

Re: Apache fails to respond about 20% of the time

PostPosted: 28. September 2015 02:12
by maxnugget
Sorry about the lack of details. Here's my setup

AMD A8-660K APU
Windows 7
16GB RAM
Hard drive: Samsung EVO 850 250GB
XAMPP 5.6.12 (though I've had this problem with older versions over the course of the past year or so)
Antivirus: Microsoft Security Essentials but I have the real-time protection disabled



The problem occurs even when I try to access XAMPP sites from the computer XAMPP is running on.

It happens on every site I work on (I've got about a dozen sites on my local machine). I'm working on trying to rule out whether it ever happens on requests that don't involve mysql, I'll update this thread if I figure that out. It definitely happens regularly on sites using PHP and mysql. These sites are typically running Joomla 3.4 but I believe it has happened on non-Joomla sites as well.

I'm just at a loss for how to begin to troubleshoot this, having already tried checking the logs, etc.

Re: Apache fails to respond about 20% of the time

PostPosted: 13. October 2015 10:53
by maxnugget
melius2 wrote:It looks like a network issue, maybe a NAT problem, have you tried changing Apache default port from 80 to other to see if you can replicate the issue?


Ok, so for all the sites I work on, I set a subdomain of my company's domain (i.e. acmepaint.mycompany.com) to point to my public IP, which my router then NATs to my local development workstation which is running XAMPP.

For whatever reason I decided to try adding a hosts file override to map those subdomains to 127.0.0.1, and viola! The problem disappeared instantly. I'm not sure if people outside of my office are still having intermittent issues, but I don't really care as that's a secondary concern for me.

So, thanks for the suggestion, which led me to the above idea. This is (seemingly) the end of a year+ nightmare that has made my development work absolutely miserable.

Thanks!