Home » HashiCorp » Terraform Associate » When multiple engineers start deploying infrastructure using the same state file, what is a feature of remote state storage that is critical to ensure the state doesn’t become corrupt?
When multiple engineers start deploying infrastructure using the same state file, what is a feature of remote state storage that is critical to ensure the state doesn’t become corrupt?
A. Object Storage
B. State Locking
C. WorkSpaces
D. Encryption
Correct Answer: B
Explanation/Reference:
Explanation:
If supported by your backend, Terraform will lock your state for all operations that could write state.
This prevents others from acquiring the lock and potentially corrupting your state.
State locking happens automatically on all operations that could write state. You won’t see any message that it is happening. If state locking fails, Terraform will not continue. You can disable state locking for most commands with the -lock flag but it is not recommended.
If acquiring the lock is taking longer than expected, Terraform will output a status message. If Terraform doesn’t output a message, state locking is still occurring if your backend supports it.
Not all backends support locking. Please view the list of backend types for details on whether a backend supports locking or not.
https://www.terraform.io/docs/state/locking.html
Download Printable PDF. VALID exam to help you PASS.
|
|