Question 322 of 519
Use Terraform outside the core workflowhardMultiple ChoiceObjective-mapped

Quick Answer

The correct answer is that the application workspaces are using a cached version of the remote state outputs and need to run `terraform plan` to refresh. This happens because Terraform caches remote state data during the planning phase, and the `terraform_remote_state` data source only fetches the latest state when `terraform plan` or `terraform apply` is executed. Since the application workspaces have not been re-planned, they are still reading a stale cached copy of the networking workspace’s outputs, which contains the old subnet ID. On the HashiCorp Terraform Associate TF-003 exam, this question tests your understanding of how remote state caching works and the refresh behavior of data sources—a common trap is assuming that data sources always fetch the latest state automatically. The key takeaway is that `terraform_remote_state` does not refresh on every read; it only updates when you explicitly run a plan or apply. Memory tip: “Plan to refresh” — if your remote state feels stale, run a plan to pull the latest.

TF-003 Use Terraform outside the core workflow Practice Question

This TF-003 practice question tests your understanding of use terraform outside the core workflow. The scenario asks you to isolate a root cause — eliminate options that address a different problem before choosing. 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.

You are a platform engineer at a large e-commerce company that uses Terraform Enterprise to manage thousands of infrastructure resources across multiple teams. The company has a central 'networking' workspace that provisions shared VPCs and subnets, and several application workspaces that consume these networking resources via remote state data sources. Recently, the networking team changed the CIDR block of a shared subnet from '10.0.1.0/24' to '10.0.2.0/24' and applied the change successfully. However, the application teams are now reporting that their Terraform runs are failing with errors indicating that the subnet ID they reference does not exist. The application workspaces use the following configuration to consume the subnet:

```hcl data "terraform_remote_state" "networking" { backend = "remote" config = { organization = "mycompany" workspaces = { name = "networking"

}
  }
}

resource "aws_instance" "app" { subnet_id = data.terraform_remote_state.networking.outputs.subnet_id ...

}

```

The application workspaces have not been modified recently. The networking workspace output 'subnet_id' now contains the ID of the updated subnet. What is the most likely cause of the failures?

Clue words in this question

Noticing these words before you look at the options changes how you read each choice.

  • Clue: "most likely"

    Why it matters: Probability qualifier — the question wants the most probable cause or outcome, not a guaranteed one. Eliminate low-probability options.

Question 1hardmultiple choice
Review the full subnetting walkthrough →

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

The application workspaces are using a cached version of the remote state outputs and need to run 'terraform plan' to refresh.

Option C is correct because Terraform caches remote state data during the planning phase, and the `terraform_remote_state` data source only fetches the latest state when `terraform plan` or `terraform apply` is executed. Since the application workspaces have not been modified or re-planned, they are using a stale cached version of the networking workspace's outputs, which still contains the old subnet ID. Running `terraform plan` forces a refresh of the remote state data, retrieving the updated `subnet_id` and resolving the error.

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.

  • The application workspaces do not have permission to read the networking workspace's state.

    Why it's wrong here

    If permissions were missing, the error would be about access denied, not a missing subnet.

  • The networking workspace output variable 'subnet_id' was removed or renamed.

    Why it's wrong here

    The problem states that the output now contains the ID of the updated subnet, so it still exists.

  • The application workspaces are using a cached version of the remote state outputs and need to run 'terraform plan' to refresh.

    Why this is correct

    Terraform caches remote state data for the duration of a run; a new plan refreshes the data.

    Clue confirmation

    The clue word "most likely" in the question point toward this answer.

    Related concept

    Read the scenario before looking for a memorised answer.

  • The application workspaces need to update the remote state data source to reference the new subnet ID.

    Why it's wrong here

    Data sources automatically fetch outputs; no code change is needed.

Common exam traps

Common exam trap: answer the scenario, not the keyword

The trap here is that candidates may assume the remote state data source always reads the latest state on every run, when in fact Terraform caches the data from the last plan and only refreshes it during a new plan or apply operation.

Trap categories for this question

  • Command / output trap

    The problem states that the output now contains the ID of the updated subnet, so it still exists.

Detailed technical explanation

How to think about this question

Under the hood, `terraform_remote_state` fetches state data during the `terraform plan` phase and stores it in memory for the duration of the run. Terraform does not automatically re-fetch remote state between runs unless a plan or apply is triggered, which means the cached outputs persist across runs until explicitly refreshed. In real-world scenarios, this caching behavior can cause subtle drift issues when dependent workspaces are updated independently, requiring careful orchestration or the use of `terraform plan -refresh-only` to force a state refresh without applying changes.

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 network engineer segments a warehouse floor into three subnets: 20 scanners, 5 printers, and 2 management hosts. Picking the wrong mask wastes addresses or leaves too few usable hosts. Exam questions test whether you can apply CIDR notation, calculate block size, and identify the correct usable-host range for a given prefix.

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 TF-003 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 TF-003 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 TF-003 question test?

Use Terraform outside the core workflow — This question tests Use Terraform outside the core workflow — Read the scenario before looking for a memorised answer..

What is the correct answer to this question?

The correct answer is: The application workspaces are using a cached version of the remote state outputs and need to run 'terraform plan' to refresh. — Option C is correct because Terraform caches remote state data during the planning phase, and the `terraform_remote_state` data source only fetches the latest state when `terraform plan` or `terraform apply` is executed. Since the application workspaces have not been modified or re-planned, they are using a stale cached version of the networking workspace's outputs, which still contains the old subnet ID. Running `terraform plan` forces a refresh of the remote state data, retrieving the updated `subnet_id` and resolving the error.

What should I do if I get this TF-003 question wrong?

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

Are there clue words in this question I should notice?

Yes — watch for: "most likely". Probability qualifier — the question wants the most probable cause or outcome, not a guaranteed one. Eliminate low-probability options.

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

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 TF-003 practice question is part of Courseiva's free HashiCorp 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 TF-003 exam.