Question 429 of 500
Deploying and implementing a cloud solutionhardMultiple ChoiceObjective-mapped

Quick Answer

The correct choice is the `gcs` backend storing state in a Cloud Storage bucket, because it natively supports state locking through object versioning and write-preconditions, ensuring only one team member can modify the Terraform state at a time. This prevents concurrent modifications from corrupting the shared state file, while IAM policies on the bucket provide secure, team-wide access. On the Google Associate Cloud Engineer exam, this question tests your understanding of Terraform backend mechanics versus remote state storage options—a common trap is confusing the `gcs` backend with the `http` or `consul` backends, which lack native GCP integration or locking. Remember that the `gcs` backend is the only one that leverages Cloud Storage’s built-in generation numbers for lock contention. For a quick memory tip: think “GCS Locks with Objects”—the bucket’s object versioning is what enforces the lock, not a separate database.

Google ACE Deploying and implementing a cloud solution Practice Question

This ACE practice question tests your understanding of deploying and implementing a cloud solution. This is a configuration task: choose the command set that satisfies every stated requirement. Small differences — like 'secret' vs 'password' or 'transport input ssh' vs 'all' — change whether the answer is correct. After answering, compare your reasoning against the explanation and wrong-answer breakdown below. Once you have made your selection, read the full explanation to reinforce the concept and understand why each distractor is designed to mislead on exam day.

A DevOps team uses Terraform to manage GCP infrastructure and wants to store Terraform state in a shared location that all team members can access securely, with state locking to prevent concurrent modifications. Which backend configuration achieves this?

Question 1hardmultiple choice
Full question →

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

gcs backend storing state in a Cloud Storage bucket

The `gcs` backend is the correct choice because it stores Terraform state in a Google Cloud Storage bucket, which provides secure, shared access via IAM policies and supports state locking natively through object versioning and write-preconditions. This ensures that only one team member can modify the state at a time, preventing conflicts and corruption.

Key principle: Answer the scenario, not the keyword: identify the specific constraint before choosing the most familiar-sounding option.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • gcs backend storing state in a Cloud Storage bucket

    Why this is correct

    The `gcs` backend stores Terraform state in a Cloud Storage bucket and supports state locking via GCS object lock, enabling safe concurrent team usage.

    Related concept

    Read the scenario before looking for a memorised answer.

  • gcp backend storing state in a BigQuery table

    Why it's wrong here

    Terraform has no native `gcp` or BigQuery backend. BigQuery is not supported as a Terraform state backend.

  • remote backend connected to a Cloud SQL database

    Why it's wrong here

    The `remote` backend in Terraform connects to Terraform Cloud/Enterprise — not Cloud SQL. Cloud SQL is not a Terraform state backend.

  • local backend with a path shared over Cloud Filestore

    Why it's wrong here

    A local backend stores state on the local filesystem. Even if shared via Filestore, it lacks built-in state locking and is error-prone for team use.

Common exam traps

Common exam trap: answer the scenario, not the keyword

The trap here is that candidates confuse the `gcp` provider (which manages GCP resources) with a backend name, or assume that any shared filesystem (like Cloud Filestore) can provide locking, ignoring that Terraform requires atomic, server-side locking which only object storage backends like `gcs` or `s3` provide natively.

Detailed technical explanation

How to think about this question

The `gcs` backend uses Cloud Storage's object generation numbers and conditional writes (via `If-Match` headers) to implement state locking: when Terraform writes state, it checks the current generation number, and if another process has already updated the object, the write fails, preventing concurrent modifications. This mechanism is analogous to optimistic locking and ensures consistency even in high-velocity CI/CD pipelines where multiple pipelines might attempt to apply changes simultaneously.

KKey Concepts to Remember

  • Read the scenario before looking for a memorised answer.
  • Find the constraint that changes the correct option.
  • Eliminate answers that are true in general but not in this case.

TExam Day Tips

  • Watch for words such as best, first, most likely and least administrative effort.
  • Review why wrong options are wrong, not only why the correct option is correct.

Key takeaway

Answer the scenario, not the keyword: identify the specific constraint before choosing the most familiar-sounding option.

Real-world example

How this comes up in practice

A media company stores terabytes of video archives that are accessed once a year for audit purposes. Moving these objects to a cold storage tier (Azure Archive, S3 Glacier, or Google Nearline) costs a fraction of hot storage. Questions like this test whether you understand storage tiers, access frequency tradeoffs, and retrieval latency requirements.

What to study next

Got this wrong? Here's your next step.

Identify which exam domain this question belongs to, review the core concept, then practise similar questions from the same domain.

Related practice questions

Related ACE practice-question pages

Use these pages to review the topic behind this question. This is how one missed question becomes focused revision.

Practice this exam

Start a free ACE practice session

Short sessions build daily habit. Longer sessions build exam-day stamina. Try a timed session to simulate real conditions.

FAQ

Questions learners often ask

What does this ACE question test?

Deploying and implementing a cloud solution — This question tests Deploying and implementing a cloud solution — Read the scenario before looking for a memorised answer..

What is the correct answer to this question?

The correct answer is: gcs backend storing state in a Cloud Storage bucket — The `gcs` backend is the correct choice because it stores Terraform state in a Google Cloud Storage bucket, which provides secure, shared access via IAM policies and supports state locking natively through object versioning and write-preconditions. This ensures that only one team member can modify the state at a time, preventing conflicts and corruption.

What should I do if I get this ACE question wrong?

Identify which exam domain this question belongs to, review the core concept, then practise similar questions from the same domain.

What is the key concept behind this question?

Read the scenario before looking for a memorised answer.

About these practice questions

Courseiva creates original exam-style practice questions with explanations and wrong-answer analysis. It does not publish real exam questions, exam dumps, or protected exam content. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

Same concept, more angles

1 more ways this is tested on ACE

These questions test the same concept from different angles. Work through them to make sure you can recognise it however the exam phrases it.

Variation 1. You are managing Terraform state for a GCP infrastructure project shared by a team of 5 engineers. You need to prevent simultaneous `terraform apply` operations from causing state corruption. What is the recommended backend configuration?

hard
  • A.Store state locally on each engineer's machine and merge state files manually after each apply.
  • B.Configure the `gcs` backend in Terraform, pointing to a Cloud Storage bucket with versioning enabled.
  • C.Use Terraform Cloud (HashiCorp) as the backend for state locking.
  • D.Use a Cloud Source Repository to store state files with branch-based locking.

Why B: Option B is correct because the `gcs` backend with versioning enabled provides both remote state storage and built-in state locking via Cloud Storage's object-level consistency model. When one engineer runs `terraform apply`, the backend acquires a lock by writing a lock file to the bucket; other concurrent operations are blocked until the lock is released, preventing state corruption. Versioning further protects against accidental state deletion or corruption by allowing rollback to previous state versions.

Last reviewed: Jun 11, 2026

Question Discussion

Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.

Loading comments…

Sign in to join the discussion.

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.