nerdexam
HashiCorp

TERRAFORM-ASSOCIATE-004 · Question #200

Using the terraform state rm command against a resource will destroy it.

The correct answer is B. False. The terraform state rm command removes a resource from Terraform's state file but does not destroy the resource in the actual infrastructure. It only removes Terraform's knowledge of the resource, meaning Terraform will no longer manage it. If you run terraform state rm on a…

Submitted by yasin.bd· Apr 18, 2026Manage Terraform State

Question

Using the terraform state rm command against a resource will destroy it.

Options

  • ATrue
  • BFalse

How the community answered

(37 responses)
  • A
    5% (2)
  • B
    95% (35)

Explanation

The terraform state rm command removes a resource from Terraform's state file but does not destroy the resource in the actual infrastructure. It only removes Terraform's knowledge of the resource, meaning Terraform will no longer manage it. If you run terraform state rm on a resource, Terraform will forget that the resource exists. However, the resource will still exist in the cloud or infrastructure provider. If you later run terraform apply, Terraform may try to recreate the resource because it is no longer present in its

Topics

#terraform state rm#Terraform state#Resource lifecycle#CLI operations

Community Discussion

No community discussion yet for this question.

Full TERRAFORM-ASSOCIATE-004 Practice