Google ACE Setting Up a Cloud Solution Environment Practice Question
An engineer needs to create a new project and set up the environment. They are using the gcloud command-line tool. Which two commands are required to create a project and link it to a billing account? (Choose TWO.)
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 billing projects link PROJECT_ID --billing-account=BILLING_ACCOUNT_ID
To create a project and link a billing account, you need to create the project (gcloud projects create) and then link the billing account (gcloud billing projects link).
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 billing projects link PROJECT_ID --billing-account=BILLING_ACCOUNT_ID
Why this is correct
This command explicitly associates a specified project with a specified billing account. It is the standard gcloud operation for setting up the billing relationship after project creation, enabling the project to consume paid services. The command requires both the project ID and the billing account ID as arguments, and it performs an API call to the Cloud Billing API. Once run, the project's billing is active and can be used for resource consumption.
- ✓
gcloud projects create PROJECT_ID
Why this is correct
This command provisions a new Google Cloud project with the given unique project ID, which is the essential first step for establishing an environment. The project ID must be globally unique and immutable, and it becomes the root for all resources and quotas. Although it creates the project, it does not attach any billing account or enable service APIs, so subsequent setup steps are still required.
- ✗
gcloud alpha billing accounts create
Why it's wrong here
This command attempts to create an entirely new billing account, rather than linking an existing one. Billing accounts are generally created through the Cloud Console's Billing section because they represent corporate payment relationships and require special permissions. Even if the command succeeds, it leaves the new project unlinked, and the new account would need to be separately linked to the project, making this the wrong step for the intended task.
- ✗
gcloud services enable cloudbilling.googleapis.com
Why it's wrong here
This command enables the Cloud Billing API for the project, but that API is already enabled by default on all projects, so the command is unnecessary for billing linking. More importantly, enabling an API does not connect the project to any billing account; it only allows your project to make programmatic calls to billing-related operations. The actual association is made by gcloud billing projects link, which internally uses this API.
- ✗
gcloud config set project PROJECT_ID
Why it's wrong here
This command updates the local gcloud configuration to make a chosen project the default for future commands, avoiding the need to pass the --project flag each time. It simply alters your client-side settings and does not interact with Google Cloud at all, let alone create a billing association. The project must already exist, and running this command has zero effect on billing or on the project's ability to use paid services.
Go deeper
Related to this question
About these practice questions
This ACE question is part of Courseiva's 769-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam 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.