I've been trying to connect unsuccessfully to my google cloud sql database (mysql) with the IPV6 address that Google gives you.
mysql -h 0:0:0:0:0:aaaa:aaaa:aaaa -u admin -p
The client prompts for a password but it won't allow me to connect.
ERROR 2003 (HY000): Can't connect to MySQL server on ...
If I use the IPV4 I can connect without any issues. Has anyone else experienced any issues with this?
Google Cloud supports IPv6 clients with proxy load balancers such as the global external HTTP(S) load balancers, External SSL Proxy Load Balancing, and External TCP Proxy Load Balancing.
In the Google Cloud console, go to the Cloud SQL Instances page. To open the Overview page of an instance, click the instance name. Select Connections from the SQL navigation menu. In the Authorized networks section, click Add network and enter the IP address of the machine where the client is installed.
If your ISP does not support IPv6 connectivity, then you will not be able to use the IPv6 address provided. If this is the case, then you will need to request an IPv4 address for your Cloud SQL instance. Then you must authorize the IP address from which you will be connecting (not the IP address of your Cloud SQL instance). The process can be found in this article on ‘Connecting from External Applications’.
It is important to note that while your IPv6 address is free to use, assigning an IPv4 address will incur additional charges. I recommend reviewing the pricing information for Cloud SQL so you can get a better idea of how this is calculated.
I hope that this information is helpful.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With