I`m setting up a SQL instance on GCP, when configuring the options I want to choose a network path for connecting to this instance. I want to choose private IP:
So I tried option use automatically allocated IP range and it just wants to reconnect to the existing dafeault_ip_range and I get the error: The resource 'projects/[myProject]/global/addresses/default-ip-range' already exists
Don't know what else to try...
There are two ways to fix this issue. Either way, the objective is to allocate the respective IP ranges to the private connection.
First, using CLI Command, which will call update connection with new ranges and force flag to change the ranges used for the connection:
gcloud services vpc-peerings update --network=default --ranges=new-ip-range-4,default-ip-range --service=servicenetworking.googleapis.com --force
Or second, navigate to Google Cloud Platform > VPC Network > VPC Network Details > Private Service Connection > Private Connections to Services. Modify the private connection with the desired IP ranges