Recall & Review
beginner
What is Terraform state and why is it important?
Terraform state is a file that keeps track of the resources Terraform manages. It helps Terraform know what exists so it can update or delete resources correctly.
Click to reveal answer
beginner
What is state disaster recovery in Terraform?
State disaster recovery means having a backup plan for your Terraform state file so you can restore it if it gets lost or corrupted.
Click to reveal answer
intermediate
Name one common method to protect Terraform state from loss.
Using remote state storage like AWS S3 with versioning enabled to keep backups of the state file.
Click to reveal answer
intermediate
Why should Terraform state be stored remotely and not locally?
Remote storage allows multiple team members to share the state safely and enables backups and locking to prevent conflicts.
Click to reveal answer
intermediate
What is state locking and how does it help in disaster recovery?
State locking prevents multiple people from changing the state at the same time, reducing the risk of corrupting the state file.
Click to reveal answer
What does Terraform state file track?
✗ Incorrect
Terraform state tracks the current resources it manages to know what to create, update, or delete.
Which of these is a best practice for Terraform state disaster recovery?
✗ Incorrect
Using a remote backend with versioning and locking protects the state file and supports recovery.
What feature helps prevent simultaneous changes to Terraform state?
✗ Incorrect
State locking prevents multiple users from changing the state at the same time, avoiding corruption.
If your Terraform state file is corrupted, what should you do?
✗ Incorrect
Restoring from a backup version of the state file helps recover the infrastructure state safely.
Why is enabling versioning on remote state storage important?
✗ Incorrect
Versioning keeps previous copies of the state file so you can restore if needed.
Explain how you would set up Terraform state disaster recovery for a team project.
Think about storage, backups, and preventing conflicts.
You got /4 concepts.
Describe what happens if Terraform state is lost and how disaster recovery helps.
Consider the role of state in managing infrastructure.
You got /4 concepts.