HashiCorp Terraform Associate Practice Test 68
Question 670
An operations team wants to update Terraform state after an authorized external service changed only an automatically computed attribute, without reverting the remote change. The team has implemented an approved Terraform change. Which observed result most directly confirms that the original requirement is now met, beyond a successful command exit code?
- Recorded state reflects the accepted external attribute without rewriting resources.
- Auditors receive only approved evidence without broad raw state disclosure.
- The team distinguishes state ownership from all possible cloud resources.
- The remote backend retains the original managed resource bindings.
Explanation
Correct Answer
A:This is the appropriate measurable post-change acceptance criterion: Recorded state reflects the accepted external attribute without rewriting resources. A successful Terraform command or a completed change request alone would not demonstrate that outcome. Preserve this control during validation: Document whether configuration later needs a corresponding update.
Incorrect Answers
B:“Auditors receive only approved evidence without broad raw state disclosure” would address a different Terraform configuration concern; the source instead describes An operations team wants to update Terraform state after an authorized external service changed only an automatically computed attribute, without reverting the remote change. The appropriate design is to use an appropriate refresh-only plan/apply after reviewing what state values would be updated. Confirm whether recorded state reflects the accepted external attribute without rewriting resources.
C:“The team distinguishes state ownership from all possible cloud resources” would address a different Terraform configuration concern; the source instead describes An operations team wants to update Terraform state after an authorized external service changed only an automatically computed attribute, without reverting the remote change. The appropriate design is to use an appropriate refresh-only plan/apply after reviewing what state values would be updated. Confirm whether recorded state reflects the accepted external attribute without rewriting resources.
D:“The remote backend retains the original managed resource bindings” would address a different Terraform configuration concern; the source instead describes An operations team wants to update Terraform state after an authorized external service changed only an automatically computed attribute, without reverting the remote change. The appropriate design is to use an appropriate refresh-only plan/apply after reviewing what state values would be updated. Confirm whether recorded state reflects the accepted external attribute without rewriting resources.
Question 671
A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. The infrastructure review requires a supported, least-disruptive Terraform solution. Which proposed change most directly addresses this specific situation?
- Verify that no active operation owns the lock before using the supported force-unlock workflow.
- Confirm actual state location and migrate or intentionally isolate resources, never infer identity from the backend key name.
- Add a moved block or use controlled state move operations so the existing remote ID retains the new address.
- Use supported Terraform state subcommands or provider-aware reconciliation rather than manual JSON editing.
Explanation
Correct Answer
C:The proposed intervention addresses the reported Terraform engineering failure: A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. It applies the design choice Add a moved block or use controlled state move operations so the existing remote ID retains the new address. Review the primary diagnostic: Inspect old and new configuration resource addresses. The expected outcome is: Terraform recognizes the same managed server at the new address without recreation. The rollout safeguard is: Preserve backups and test the refactor against actual current state.
Incorrect Answers
A:“Verify that no active operation owns the lock before using the supported force-unlock workflow” would address a different Terraform configuration concern; the source instead describes A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. The appropriate design is to add a moved block or use controlled state move operations so the existing remote ID retains the new address. Confirm whether terraform recognizes the same managed server at the new address without recreation.
B:“Confirm actual state location and migrate or intentionally isolate resources, never infer identity from the backend key name” would address a different Terraform configuration concern; the source instead describes A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. The appropriate design is to add a moved block or use controlled state move operations so the existing remote ID retains the new address. Confirm whether terraform recognizes the same managed server at the new address without recreation.
D:“Use supported Terraform state subcommands or provider-aware reconciliation rather than manual JSON editing” would address a different Terraform configuration concern; the source instead describes A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. The appropriate design is to add a moved block or use controlled state move operations so the existing remote ID retains the new address. Confirm whether terraform recognizes the same managed server at the new address without recreation.
Question 672
A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. Before choosing a remedy, the team needs independent evidence of the actual root cause. Which TWO checks most directly test this case? (Select TWO.)
- Inspect Terraform workspace name and backend key.
- Inspect old and new configuration resource addresses.
- Inspect the lock identifier and backend run logs.
- Inspect the required DNS output and current state-sharing permissions.
- Review planned actions before and after the state address migration.
Explanation
Correct Answers
B:This is directly relevant evidence for the reported behavior: Inspect old and new configuration resource addresses. Pair it with a separate check from the same case rather than assuming one finding proves the cause. The evidence supports or refutes the change proposal: Add a moved block or use controlled state move operations so the existing remote ID retains the new address. The expected confirmation is Terraform recognizes the same managed server at the new address without recreation.
E:This is directly relevant evidence for the reported behavior: Review planned actions before and after the state address migration. Pair it with a separate check from the same case rather than assuming one finding proves the cause. The evidence supports or refutes the change proposal: Add a moved block or use controlled state move operations so the existing remote ID retains the new address. The expected confirmation is Terraform recognizes the same managed server at the new address without recreation.
Incorrect Answers
A:“Inspect Terraform workspace name and backend key” would address a different Terraform configuration concern; the source instead describes A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. The appropriate design is to add a moved block or use controlled state move operations so the existing remote ID retains the new address. Confirm whether terraform recognizes the same managed server at the new address without recreation.
C:“Inspect the lock identifier and backend run logs” would address a different Terraform configuration concern; the source instead describes A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. The appropriate design is to add a moved block or use controlled state move operations so the existing remote ID retains the new address. Confirm whether terraform recognizes the same managed server at the new address without recreation.
D:“Inspect the required DNS output and current state-sharing permissions” would address a different Terraform configuration concern; the source instead describes A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. The appropriate design is to add a moved block or use controlled state move operations so the existing remote ID retains the new address. Confirm whether terraform recognizes the same managed server at the new address without recreation.
Question 673
A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. If this behavior continues without correction, which specific risk is most closely supported by the facts, without assuming harm has already occurred?
- Committing state can expose sensitive identifiers and credentials through history.
- Unmapped address renames can cause unnecessary downtime.
- Starting with empty state can cause duplicate resource create plans.
- Uninitialized backend changes can target the wrong infrastructure.
Explanation
Correct Answer
B:The reported condition creates the specific potential exposure: Unmapped address renames can cause unnecessary downtime. A risk is not evidence that every adverse outcome already occurred. Two independent checks can corroborate the assessment. First diagnostic: Inspect old and new configuration resource addresses. Second diagnostic: Review planned actions before and after the state address migration.
Incorrect Answers
A:“Committing state can expose sensitive identifiers and credentials through history” would address a different Terraform configuration concern; the source instead describes A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. The appropriate design is to add a moved block or use controlled state move operations so the existing remote ID retains the new address. Confirm whether terraform recognizes the same managed server at the new address without recreation.
C:“Starting with empty state can cause duplicate resource create plans” would address a different Terraform configuration concern; the source instead describes A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. The appropriate design is to add a moved block or use controlled state move operations so the existing remote ID retains the new address. Confirm whether terraform recognizes the same managed server at the new address without recreation.
D:“Uninitialized backend changes can target the wrong infrastructure” would address a different Terraform configuration concern; the source instead describes A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. The appropriate design is to add a moved block or use controlled state move operations so the existing remote ID retains the new address. Confirm whether terraform recognizes the same managed server at the new address without recreation.
Question 674
A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. A reviewer asks for BOTH a targeted technical response and a corresponding change-control safeguard. Which TWO actions together meet that requirement? (Select TWO.)
- Use separate backends or managed workspace permissions as appropriate instead of treating CLI workspace names as security isolation.
- Add a moved block or use controlled state move operations so the existing remote ID retains the new address.
- Preserve backups and test the refactor against actual current state.
- Coordinate network owner review and preserve the incident change record.
- Review key management and rotate compromised credentials.
Explanation
Correct Answers
B:This is one of the two necessary decisions for a safe design: Add a moved block or use controlled state move operations so the existing remote ID retains the new address. Together the corrective action and its implementation safeguard need to address the recorded condition: A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. Acceptance requires Terraform recognizes the same managed server at the new address without recreation.
C:This is one of the two necessary decisions for a safe design: Preserve backups and test the refactor against actual current state. Together the corrective action and its implementation safeguard need to address the recorded condition: A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. Acceptance requires Terraform recognizes the same managed server at the new address without recreation.
Incorrect Answers
A:“Use separate backends or managed workspace permissions as appropriate instead of treating CLI workspace names as security isolation” would address a different Terraform configuration concern; the source instead describes A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. The appropriate design is to add a moved block or use controlled state move operations so the existing remote ID retains the new address. Confirm whether terraform recognizes the same managed server at the new address without recreation.
D:“Coordinate network owner review and preserve the incident change record” would address a different Terraform configuration concern; the source instead describes A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. The appropriate design is to add a moved block or use controlled state move operations so the existing remote ID retains the new address. Confirm whether terraform recognizes the same managed server at the new address without recreation.
E:“Review key management and rotate compromised credentials” would address a different Terraform configuration concern; the source instead describes A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. The appropriate design is to add a moved block or use controlled state move operations so the existing remote ID retains the new address. Confirm whether terraform recognizes the same managed server at the new address without recreation.
Question 675
A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. The team has implemented an approved Terraform change. Which observed result most directly confirms that the original requirement is now met, beyond a successful command exit code?
- Only approved operators and deployment identities can retrieve state.
- State correctly associates the existing database with its declared address.
- State remains structurally valid and accurately represents intended objects.
- Terraform recognizes the same managed server at the new address without recreation.
Explanation
Correct Answer
D:This is the appropriate measurable post-change acceptance criterion: Terraform recognizes the same managed server at the new address without recreation. A successful Terraform command or a completed change request alone would not demonstrate that outcome. Preserve this control during validation: Preserve backups and test the refactor against actual current state.
Incorrect Answers
A:“Only approved operators and deployment identities can retrieve state” would address a different Terraform configuration concern; the source instead describes A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. The appropriate design is to add a moved block or use controlled state move operations so the existing remote ID retains the new address. Confirm whether terraform recognizes the same managed server at the new address without recreation.
B:“State correctly associates the existing database with its declared address” would address a different Terraform configuration concern; the source instead describes A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. The appropriate design is to add a moved block or use controlled state move operations so the existing remote ID retains the new address. Confirm whether terraform recognizes the same managed server at the new address without recreation.
C:“State remains structurally valid and accurately represents intended objects” would address a different Terraform configuration concern; the source instead describes A company renames aws_instance.web to aws_instance.frontend in configuration and Terraform plans to destroy and recreate the same functioning server. The appropriate design is to add a moved block or use controlled state move operations so the existing remote ID retains the new address. Confirm whether terraform recognizes the same managed server at the new address without recreation.
Question 676
An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. The infrastructure review requires a supported, least-disruptive Terraform solution. Which proposed change most directly addresses this specific situation?
- Use an appropriate refresh-only plan/apply after reviewing what state values would be updated.
- Use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership.
- Verify that no active operation owns the lock before using the supported force-unlock workflow.
- Add a moved block or use controlled state move operations so the existing remote ID retains the new address.
Explanation
Correct Answer
B:The proposed intervention addresses the reported Terraform engineering failure: An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. It applies the design choice Use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. Review the primary diagnostic: Inspect state binding for the legacy database. The expected outcome is: The database persists but no longer appears as Terraform-managed in that root. The rollout safeguard is: Record the new operational owner and protect backups.
Incorrect Answers
A:“Use an appropriate refresh-only plan/apply after reviewing what state values would be updated” would address a different Terraform configuration concern; the source instead describes An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. The appropriate design is to use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. Confirm whether the database persists but no longer appears as Terraform-managed in that root.
C:“Verify that no active operation owns the lock before using the supported force-unlock workflow” would address a different Terraform configuration concern; the source instead describes An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. The appropriate design is to use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. Confirm whether the database persists but no longer appears as Terraform-managed in that root.
D:“Add a moved block or use controlled state move operations so the existing remote ID retains the new address” would address a different Terraform configuration concern; the source instead describes An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. The appropriate design is to use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. Confirm whether the database persists but no longer appears as Terraform-managed in that root.
Question 677
An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. Before choosing a remedy, the team needs independent evidence of the actual root cause. Which TWO checks most directly test this case? (Select TWO.)
- Inspect old and new configuration resource addresses.
- Inspect state binding for the legacy database.
- Inspect repository commits for state snapshots and accidental secrets.
- Inspect backend location changes and current .terraform initialization metadata.
- Review plan showing removal from state ownership without provider deletion.
Explanation
Correct Answers
B:This is directly relevant evidence for the reported behavior: Inspect state binding for the legacy database. Pair it with a separate check from the same case rather than assuming one finding proves the cause. The evidence supports or refutes the change proposal: Use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. The expected confirmation is The database persists but no longer appears as Terraform-managed in that root.
E:This is directly relevant evidence for the reported behavior: Review plan showing removal from state ownership without provider deletion. Pair it with a separate check from the same case rather than assuming one finding proves the cause. The evidence supports or refutes the change proposal: Use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. The expected confirmation is The database persists but no longer appears as Terraform-managed in that root.
Incorrect Answers
A:“Inspect old and new configuration resource addresses” would address a different Terraform configuration concern; the source instead describes An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. The appropriate design is to use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. Confirm whether the database persists but no longer appears as Terraform-managed in that root.
C:“Inspect repository commits for state snapshots and accidental secrets” would address a different Terraform configuration concern; the source instead describes An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. The appropriate design is to use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. Confirm whether the database persists but no longer appears as Terraform-managed in that root.
D:“Inspect backend location changes and current .terraform initialization metadata” would address a different Terraform configuration concern; the source instead describes An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. The appropriate design is to use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. Confirm whether the database persists but no longer appears as Terraform-managed in that root.
Question 678
An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. If this behavior continues without correction, which specific risk is most closely supported by the facts, without assuming harm has already occurred?
- CLI workspaces alone may share credentials and insufficient isolation.
- State can contain sensitive attributes even if configuration does not.
- Deleting the resource block alone normally proposes destruction.
- Using the wrong address may lead to misdiagnosis or disclosure of secrets.
Explanation
Correct Answer
C:The reported condition creates the specific potential exposure: Deleting the resource block alone normally proposes destruction. A risk is not evidence that every adverse outcome already occurred. Two independent checks can corroborate the assessment. First diagnostic: Inspect state binding for the legacy database. Second diagnostic: Review plan showing removal from state ownership without provider deletion.
Incorrect Answers
A:“CLI workspaces alone may share credentials and insufficient isolation” would address a different Terraform configuration concern; the source instead describes An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. The appropriate design is to use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. Confirm whether the database persists but no longer appears as Terraform-managed in that root.
B:“State can contain sensitive attributes even if configuration does not” would address a different Terraform configuration concern; the source instead describes An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. The appropriate design is to use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. Confirm whether the database persists but no longer appears as Terraform-managed in that root.
D:“Using the wrong address may lead to misdiagnosis or disclosure of secrets” would address a different Terraform configuration concern; the source instead describes An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. The appropriate design is to use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. Confirm whether the database persists but no longer appears as Terraform-managed in that root.
Question 679
An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. A reviewer asks for BOTH a targeted technical response and a corresponding change-control safeguard. Which TWO actions together meet that requirement? (Select TWO.)
- Use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership.
- Record the new operational owner and protect backups.
- Provide sanitized reports rather than unrestricted state snapshots.
- Use explicit outputs only when access scope is justified.
- Use terraform state show for the known managed resource address and review its stored values securely.
Explanation
Correct Answers
A:This is one of the two necessary decisions for a safe design: Use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. Together the corrective action and its implementation safeguard need to address the recorded condition: An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. Acceptance requires The database persists but no longer appears as Terraform-managed in that root.
B:This is one of the two necessary decisions for a safe design: Record the new operational owner and protect backups. Together the corrective action and its implementation safeguard need to address the recorded condition: An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. Acceptance requires The database persists but no longer appears as Terraform-managed in that root.
Incorrect Answers
C:“Provide sanitized reports rather than unrestricted state snapshots” would address a different Terraform configuration concern; the source instead describes An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. The appropriate design is to use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. Confirm whether the database persists but no longer appears as Terraform-managed in that root.
D:“Use explicit outputs only when access scope is justified” would address a different Terraform configuration concern; the source instead describes An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. The appropriate design is to use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. Confirm whether the database persists but no longer appears as Terraform-managed in that root.
E:“Use terraform state show for the known managed resource address and review its stored values securely” would address a different Terraform configuration concern; the source instead describes An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. The appropriate design is to use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. Confirm whether the database persists but no longer appears as Terraform-managed in that root.
Question 680
An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. The team has implemented an approved Terraform change. Which observed result most directly confirms that the original requirement is now met, beyond a successful command exit code?
- The database persists but no longer appears as Terraform-managed in that root.
- State correctly associates the existing database with its declared address.
- Source code remains reviewable while state is securely stored separately.
- Recorded state reflects the accepted external attribute without rewriting resources.
Explanation
Correct Answer
A:This is the appropriate measurable post-change acceptance criterion: The database persists but no longer appears as Terraform-managed in that root. A successful Terraform command or a completed change request alone would not demonstrate that outcome. Preserve this control during validation: Record the new operational owner and protect backups.
Incorrect Answers
B:“State correctly associates the existing database with its declared address” would address a different Terraform configuration concern; the source instead describes An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. The appropriate design is to use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. Confirm whether the database persists but no longer appears as Terraform-managed in that root.
C:“Source code remains reviewable while state is securely stored separately” would address a different Terraform configuration concern; the source instead describes An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. The appropriate design is to use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. Confirm whether the database persists but no longer appears as Terraform-managed in that root.
D:“Recorded state reflects the accepted external attribute without rewriting resources” would address a different Terraform configuration concern; the source instead describes An application team wants Terraform to stop managing an existing legacy database but insists the database remain running for historical reports. The appropriate design is to use an appropriate removed block with destroy=false or a controlled state removal, documenting the change in ownership. Confirm whether the database persists but no longer appears as Terraform-managed in that root.