
HashiCorp Certified:Terraform Associate
Domain 7Objective 2
7b Use the CLI to Inspect State TERRAFORM-ASSOCIATE-004 Practice Questions (Page 1)
Part of the Maintain infrastructure with Terraform domain, which makes up ~7% of our current practice bank. HashiCorp does not publish an official question count, but from its 60-minute exam (~25–40 total, ~2–3 in this domain), expect 1–1 from this objective — we provide 13 practice questions to prepare you well beyond it. (estimate)
13questions here
3free pages
8concepts
Questions 1–5
- 1
A resource was accidentally included in the Terraform state, but it is actually managed by another team's separate Terraform configuration. You need to remove this resource from the current state file without destroying the actual infrastructure. Which command should you use?
Select an answer first - 2
You need to view the current attributes of a specific resource, such as an AWS instance, as recorded in the Terraform state. Which command should you use?
Select an answer first - 3
During a refactor, you rename a resource block in your configuration. To avoid destroying and recreating the resource, you need to update the state to reflect the new address. Which command should you use?
Select an answer first - 4
You want to stop managing a resource with Terraform, but you do not want to delete the actual infrastructure. Which command removes the resource from the state file?
Select an answer first - 5
A resource aws_instance.old was renamed to aws_instance.new in the configuration. However, the state still references the old address. You need to update the state to reflect the new address. What is the correct command?
Select an answer first
Finished these 5 questions?
Review the revealed explanations, or continue through the curriculum.
Free Basic Practice is a study aid with revealable answers — not a scored exam. Examers.io is independent and not affiliated with or endorsed by HashiCorp. “TERRAFORM-ASSOCIATE-004” is a trademark of its owner, used for identification only.