Slow down problem developed locally by localhost! IMac VS XAMPP

Environment
iMac macos 10.12
the connected mysql is external, not the mysql of XAMPP
there is no problem with the: linode, JP speed of the server

reason
I found that I am very slow to run localhost on this iMac. On average, it may take at least 20-50 seconds for a rearrangement.
the way we send mysql is not through the local XAMPP, but to another server, but there is nothing wrong with the server and it is very fast.

later
I don"t have this problem at all when I run localhost in macbook 2015 (it"s not new). The speed is very fast, so I guess it"s the iMac itself, but the new one doesn"t have a multi-pack installed?

question
what is the possibility of slowing down? I make sure that there is no problem with the mysql speed of the server, and that the speed of running through localhost is almost as fast in other settings.

reload
check it a little bit, it seems that the problem of macos version plus ipv6 leads to

charge 10 amp 10:
it is still slow to upgrade to high sierra.

I find that even if I use the apache and php, built in imac, it seems to be slow.


I've encountered this problem before. Ultra-slow, and then I deleted the xampp redirection in the host file. No, no, no.


if you haven't used XAMPP, you don't have much say. Please try it one by one according to the following methods.

  1. you can temporarily disable ipv6, from using traditional ipv4, to eliminate its suspicion. Temporarily comment out :: 1 localhost in \ etc\ hosts .
  2. if the first step doesn't work, try changing the port of Apache to non-80, which may solve your problem.

thanks for the invitation, you can try using phpdebugger or Xdebug to debug complex code. As for you saying that MySQL is on the public network, you can try to create a new file, add microtime () to the header and bottom of the file, use mysqli_* or PDO method, and calculate and compare the time twice to determine whether the connection is slow caused by the remote database. If there is any problem, please chase.


Thank you for the invitation. You can try to change the database connection from localhost to 127.0.0.1


I use mamp under iMac to feel better!

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e45016-437b8.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e45016-437b8.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?