Search code examples
azure-database-mysql

mysql command line client says can't connect to Azure Database for Mysql


I was happily using mysql command line in my mac to connect Azure Database for MySql. But all of sudden it started throwing an error saying:

ERROR 2003 (HY000): Can't connect to MySQL server on 'XXXXXXXX.mysql.database.azure.com' (61)

I can see the the database instances is running alright, as I'm able to use the database from an application that is running in Azure.

Has anyone else experienced this?


Solution

  • This problem occurred because the particular network i was connected to not allowing any such connections. Later when i tried from my usual network ( home / office )it got connected. I haven't made any changes in my Azure Db for MySql nor in my local machine, this proves that problem was with that particular network.