i cannot access the cloud sql(mysql) using private ip on vpc, then this message show.
ERROR 1045 (28000): Access denied for user 'root'@'10.146.15.196' (using password: YES)
i have confirmed the following items.
- use unix socket of cloud proxy, i can access and login with the same username and password (check username and password)
- In the user table of the msql database, root is host:% (check mysql allow ip)
- The request is being made using cloud logging (request can arrives)
- Connection test passes https://cloud.google.com/network-intelligence-center/docs/connectivity-tests/how-to/running-connectivity-tests (configuration is correct)
- use private ip of connect with tcp of cloud proxy, then i can login (check connect with tcp, and private ip)
- create another cloud sql instance same region then i can login this instance using private ip. (check region problem)
What's wrong?
mysql -u root -p --host [private ip]this cannot access.mysql -u root -p -S /cloudsql/[instanceID]this can access.mysql -u root -p --host 127.0.0.1this can access then i use cloud proxy target incstances (./cloud_sql_proxy -ip_address_types=PRIVATE --instances=[instanceID]=tcp:3306). - 佐藤慧太