For quite some time I had been having performance issues working with websites locally on my Windows 8 machine. This is not exactly an uncommon problem, and there seems to be no one solution that works for everyone. After spending a Saturday working through many issue threads resulting in at least a dozen possible solutions, I found a particular combo that worked for me. Although I didn't do any benchmarking I would guess my pages are now loading at least 50% faster, perhaps even more than that. Which means less frustration and HUGE productivity gains = a happier me. :-)
My system specs:
WampServer 2.2 (32-bit*), Windows 8.1 (64-bit), Apache 2.2.22, MySQL 5.5.24, PHP >= 5.3
* For some reason I've never been able to get the 64-bit version of WampServer to play well with Windows 8.
Note that I am not an expert in Windows or WAMP. As always, implement at your own risk!
bind-address = 0.0.0.0to MySQL my.ini:
[wampmysqld] # .. # .. bind-address = 0.0.0.0
Listen 0.0.0.0:80in Apache httpd.conf:
#Listen 80 Listen 0.0.0.0:80
Edit the Windows hosts file (help):
127.0.0.1 localhost 127.0.0.1 127.0.0.1
I didn't actually need this step, since it was already set, but it seems important enough to include here.
If running a Drupal installation...
In sites/default/settings.php (Drupal 7/8) change value of
$databases['default']['default']['host']from "localhost" to "127.0.0.1".
If using McAfee anti-virus protection...
Add port 3306 (help) under Navigation > Firewall > Ports and System Services.
If that doesn't work for you, try these threads:
- WampServer Forum: MySQL queries seem very slow
- WampServer Forum: PHPMyAdmin/Mysql running very slow within Windows 8