Google ACE Deploying and Implementing a Cloud Solution Practice Question
A Cloud SQL for MySQL instance needs to be created with the following requirements: MySQL 8.0, db-n1-standard-2 tier, in us-central1, with root password 'secret'. Which command meets these requirements?
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
gcloud sql instances create my-instance --database-version MYSQL_8_0 --tier db-n1-standard-2 --region us-central1 --root-password secret
The 'gcloud sql instances create' command with --database-version, --tier, --region, and --root-password correctly creates the instance.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
gcloud compute instances create my-instance --database-version MYSQL_8_0 --tier db-n1-standard-2 --region us-central1 --root-password secret
Why it's wrong here
This command invokes the Compute Engine service, not Cloud SQL, so it attempts to create a virtual machine instead of a database instance. The flags --database-version, --tier, and --root-password are not valid for gcloud compute instances create and will be rejected or ignored. Cloud SQL instances must be created with gcloud sql instances create, which has its own flag set.
- ✗
gcloud sql instances create my-instance --database-version MYSQL8 --tier n1-standard-2 --region us-central1 --password secret
Why it's wrong here
This command targets Cloud SQL but uses an invalid database version string: MYSQL8 is not a recognized version; the correct value is MYSQL_8_0. It also omits the required db- prefix in the tier, so n1-standard-2 should be db-n1-standard-2. Finally, the flag --password is not accepted; Cloud SQL uses --root-password to set the initial root account password.
- ✓
gcloud sql instances create my-instance --database-version MYSQL_8_0 --tier db-n1-standard-2 --region us-central1 --root-password secret
Why this is correct
This command correctly uses gcloud sql instances create with the supported database version MYSQL_8_0, the properly prefixed tier db-n1-standard-2, the target region us-central1, and the --root-password flag to set the initial root password. These are all valid and required parameters for provisioning a Cloud SQL for MySQL 8.0 instance from the command line.
- ✗
gcloud sql instances create my-instance --database-version MYSQL_8_0 --machine-type db-n1-standard-2 --region us-central1 --root-password secret
Why it's wrong here
This command incorrectly uses --machine-type, which is not a valid flag for gcloud sql instances create; Cloud SQL expects --tier to specify the machine class. Even though the value 'db-n1-standard-2' is correct, the flag name is wrong and will cause the command to fail. Additionally, the presence of this invalid flag prevents the command from creating the instance as intended.
Go deeper
Related to this question
Learn chapter
Google Cloud Platform Overview
Key term
Region
A region is a distinct geographic location where a cloud provider operates multiple data centers that are connected by low-latency networks and provide cloud services.
Key term
Cloud SQL
Cloud SQL is a fully managed relational database service that lets you set up, maintain, and scale SQL databases (like MySQL, PostgreSQL, and SQL Server) in the cloud without managing the underlying infrastructure.
About these practice questions
Courseiva writes every ACE question from scratch — 769 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This ACE practice question is part of Courseiva's free Google Cloud certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the ACE exam.