Cannot connect Google Cloud SQL in MySql Workbench

爷,独闯天下 提交于 2021-02-11 02:47:11

问题


I have created a MySql server in Google Cloud SQL and trying it to connect it from my local machine using MySql Workbench but i am not able to establish a connection to it.

I get the following error Failed to Connect to MySQL at {IP-Address}:3306 with user root(10060)


回答1:


If you are trying to connect from outside network to gcp sql instance you need to add your public ip of your machine in the connection of sql instance

  1. Go to your sql instance
  2. Go to Connections tab
  3. Under Connectivity select public IP and add a network by giving CIDR for your IP and save it

Then check with your sql client or workbench



来源:https://stackoverflow.com/questions/54123009/cannot-connect-google-cloud-sql-in-mysql-workbench

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!