title: MySQL Host '::1' or '127.0.0.1' is not allowed to connect to this MySQL server
body: <p>I have a strange issue on a web server (Windows Server 2012) with MySQL 5.7.16.
  I can't connect anymore to mysql server, I don't know why.</p>
  
  <p>If I type mysql -uroot -ppassword  appear an error </p>
  
  <pre><code>ERROR 1130 &lt;HY000&gt;: Host '::1' is not allowed to connect to this MySQL server or
  ERROR 1130 &lt;HY000&gt;: Host '127.0.0.1' is not allowed to connect to this MySQL server
  </code></pre>
  
  <p>I tried to use another user with all privileges and I've seen that in host there is only localhost (not 127.0.0.1 or ::1)</p>
  
  <p>How can I login with root@localhost and not with root@127.0.0.1? 
  It's very frustrating... 
  Every account trying to use @127.0.0.1 or @::1 but there exist only localhost in host and I can't change it. </p>
  
  <p>If I type mysql -uroot -ppassword I see<br>
  <code>ERROR 1130 &lt;HY000&gt;: Host '127.0.0.1' is not allowed to connect to this MySQL server</code></p>
  
  <p>Same if I type mysql -uroot -ppassword -h localhost or anything else</p>