Connecting to mysql remotely


I have a database and a user and can connect fine locally.

However, when I add my IP address to the list of allowed hosts and try to connect to the database remotely I get "ERROR 2005 (HY000): Unknown MySQL server host "

What do I need to change?


well, clearly you haven’t specified the MySQL server host correctly.

you should consider tunnelling through ssh though if your database contains anything remotely sensitive. even logging in sends your db password in the clear. you can do this on unix by:

ssh -L

then just connect to localhost:3307