Favicon.ico and server load
A site that I manage has been undergoing some pretty intensive load testing over the past few days (side note: BrowserMob is amazing) and I was seeing some results that weren’t making sense to me. Specifically, I was load testing a static HTML page and the mysqld service would start consuming 90% of the CPU and memory would spike. It didn’t make sense because there weren’t any database calls on the page. As well, when I browsed to the page during the test it would all load but then hang as if it was waiting on an external script. After much digging and head scratching I found the issue. There was no favicon.ico file on the server. This paired up with that instead having a 404 page the site actually just loads the home page on failures. So on each page load the browser tries to load a favicon.ico and since the file doesn’t exist it actually ends up loading the home page when it makes the request. I created a blank favicon.ico and put it in place and the issue was resolved.