I've been having a pretty annoying problem with a website I work on, and I'm having difficulty saying whether the problem lies with PHP, Apache or MySQL.
System setup: cloud hosted solution (moved from dedicated servers last year) with two VMs: Apache VM and MySQL VM. The Apache VM has 1 core (2GHz),4GB RAM, the MySQL VM has two of the same core, 8GB RAM. The site doesn't get a large volume of traffic, due to its nature.
Problem: when viewing an account report, sometimes the page times out and fails to load. The page runs a lot of queries, and returns quite a lot of data (mostly text, still <1MB), so my first thought was a problem with MySQL. I've monitored the server during these time-outs, and nothing stands out. I've also run the queries isolated (both direct to DB and through a test page), and they run fairly quickly.
Apache also shows nothing out of the ordinary, and I never get PHP timeouts or memory errors. I've also run this on local systems, without experiencing the same issue (though these systems obviously have no competition, unlike the live box.
The strangest thing is that when I get this problem on one browser (say, Firefox), I can't load any other pages on the site through Firefox, but I can through another browser (say, Chrome). It suggests there's some kind of connection or queue issue with the server and that session?
Can anybody give me any idea what they think could cause something like this? Or is there any more info I can give you to help?