2
votes

gcloud sql instances describe [INSTANCE_id] command is showing "HTTPError 404: The Cloud SQL instance does not exist."

I tried to include the --project="Project name" but it didn't work.

in instance_id i put my instance id of gcloud sql

admin1 ~/Desktop/practice_app/heroku-test-app master $ gcloud sql instances describe [instance_id] ERROR: (gcloud.sql.instances.describe) HTTPError 404: The Cloud SQL instance does not exist.

1
Try with project if, not name. - guillaume blaquiere

1 Answers

2
votes
  1. First you need to identify you Cloud SQL INSTANCE_id. You can find this information in Cloud Console. To know more, please check documentation .
    In case of doubts it is last part of the instance connection name, that has 3 parts <project-id>:<zone-name>:<instance-id>

  2. Please check that you initialized cloud SDK properly, using correct project ID where Cloud SQL instance is located.
    Please also be aware that project name is not project-id. That is probable cause that your --project= flag did not work. You can initialize cloud SDK using following command: gcloud init.

  3. Then you can use:

    gcloud sql instances describe <instance-id> --project=<project-id>

    If my project Id is: test-id, and cloud sql instance: cloudsql1 complete command is:

    $ gcloud sql instances describe cloudsql1 --project=test-idgcloud