简体   繁体   中英

Cannot connect Google Cloud SQL in MySql Workbench

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)

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

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM