Troubleshooting Terraform State Lock Error: ConditionalCheckFailedException
I encountered the following error while running a Terraform plan in my pipeline:
Error: Error locking state: Error acquiring the state lock: ConditionalCheckFailedException: The conditional request failed
Created: 2023-05-29 12:52:25.690864752 +0000 UTC
Terraform acquires a state lock to protect the state from being written
by multiple users at the same time. Please resolve the issue above and try
again. For most commands, you can disable locking with the "-lock=false"
flag, but this is not recommended.
Despite being certain that there are no concurrent plans running, this error occurred. Is there a way to address this issue? How can I release or remove this state lock?
Log in to reply.