Localhost taking too long. What to do?

20,835

Solution 1

I just changed the server name from localhost to 127.0.0.1 in database connection configuration and it worked light speed.

Solution 2

Just want to share my fix with this similar problem.

Try changing the permission of the user "Authenticated Users" of the drive where XAMPP is installed (for me its C:). Right click Drive C:\, click "Security" tab, edit "Authenticated Users", allow everything except "full control" and "special permission" which you can't. Apply and OK. Restart XAMPP.

Solution 3

WAMPServer has some probelms with Windows 8. Use XAMPP. I am a hardcore WAMPServer user. But, had to switch to XAMPP due to some threading issues.

You can read more about the issue here.

Solution 4

Disabling the ipv6 also improves response speed issue.

http://www.techunboxed.com/2012/08/how-to-disable-ipv6-in-windows-8.html

Solution 5

As an IPV6 issue, here is how you make MYSQL not to use it. (so, without disabling IPV6)

edit mysql file 'my.ini'

under the [wampmysqld] add the following: bind-address = ::

save file and restart mysql service

enjoy!

Share:
20,835
Yousuf Memon
Author by

Yousuf Memon

.__.

Updated on July 29, 2022

Comments

  • Yousuf Memon
    Yousuf Memon almost 2 years

    I'm working on a project. Yesterday it was working very fine but when I've updated my system OS from Windows 7 32 bit to Windows 8 64 bit and wamp server from 32 bit to 64 bit now I'm getting very slow localhost response in my Php project (6 Senonds delay on each page) also I didn't change anything within the script. Unable to identify what could be the problem.

  • Ibn Saeed
    Ibn Saeed over 11 years
    Where should i look for the constant.php file ?
  • Artur Rain
    Artur Rain about 11 years
    Same question here. Where is that constant.php?
  • andrewtweber
    andrewtweber almost 11 years
    Changing the MySQL host from localhost to 127.0.0.1 has improved things, but still every few minutes, I have to wait 10-15 seconds for it to connect to the database. Incredibly frustrating
  • Ginchen
    Ginchen almost 10 years
    This helped me when trying to make my webserver accessible from the internet on Windows 8.1! It wouldn't work, not matter what I tried. It kept saying "Server not found" or "Timeout" all the time. Disabling IPv6 solved all my problems - both WAMP and XAMPP websites can not be accessed from the web! THANK YOU!
  • Adrián E
    Adrián E over 5 years
    Completely life saving! The time taken to complete a request went from 4 seconds to instantaneous!
  • Sahil Patel
    Sahil Patel almost 2 years
    Still One of the best answer.