For MySQL, you need to add the --skip-name-resolve option either to the command line parameters of the MySQL service or in my.ini.

I am not sure if this disables name resolution from the PHP MySQL connector though.

Seems a strange issue?