github.com/muratcelep/terraform@v1.1.0-beta2-not-internal-4/website/docs/cli/state/taint.html.md (about)

     1  ---
     2  layout: "docs"
     3  page_title: "Forcing Re-creation of Resources (Tainting) - Terraform CLI"
     4  description: "Commands that allow you to destroy and re-create resources manually."
     5  ---
     6  
     7  # Forcing Re-creation of Resources (Tainting)
     8  
     9  When a resource declaration is modified, Terraform usually attempts to update
    10  the existing resource in place (although some changes can require destruction
    11  and re-creation, usually due to upstream API limitations).
    12  
    13  In some cases, you might want a resource to be destroyed and re-created even
    14  when Terraform doesn't think it's necessary. This is usually for objects that
    15  aren't fully described by their resource arguments due to side-effects that
    16  happen during creation; for example, a virtual machine that configures itself
    17  with `cloud-init` on startup might no longer meet your needs if the cloud-init
    18  configuration changes.
    19  
    20  - [The `terraform taint` command](/docs/cli/commands/taint.html) tells Terraform to
    21    destroy and re-create a particular resource during the next apply, regardless
    22    of whether its resource arguments would normally require that.
    23  
    24  - [The `terraform untaint` command](/docs/cli/commands/untaint.html) undoes a
    25    previous taint, or can preserve a resource that was automatically tainted due
    26    to failed [provisioners](/docs/language/resources/provisioners/syntax.html).