MySQL error: Can't get hostname from your ip address

52,572

Just add below in my.ini or my.cnf.

[mysqld]

skip-name-resolve 

Linux:

Otherwise, start MySQL server with the following flag:

sudo service --skip-name-resolve

For more information: http://dev.mysql.com/doc/refman/5.0/en/host-cache.html

Share:
52,572

Related videos on Youtube

Jean Louis
Author by

Jean Louis

Sorry, I dont speak english very well.

Updated on January 01, 2020

Comments

  • Jean Louis
    Jean Louis over 4 years

    I use my remote MySQL database during long time.

    But today I suddenly have found that I cannot connect to the database. I have got an error.

    "Can't get hostname from your ip address".

    I haven't changed anything in MySQL settings.

    What's the problem?

    • wimvds
      wimvds about 13 years
      As the error states : MySQL is unable to resolve your current IP to a hostname (ie. it cannot perform a reverse lookup on your current IP). Check this bug report and also how MySQL uses DNS for some background info.
  • Sajal
    Sajal over 10 years
    i am having same problem. Can anyone explain how to resolve it. This answer is not clear to me.

Related