What symptoms tell you a state is too large?
IntermediateProductionState and Backends in Production
Answer
Plans taking tens of minutes (thousands of refresh API calls), API throttling errors, 10 MB+ state JSON, lock held for long periods and a diff review that nobody can read. Fix by splitting states, pruning no-longer-needed resources, using modules with for_each sparingly at scale and increasing -parallelism only if the API tolerates it.
More on State and Backends in Production
Why should Terraform state never be committed to Git?BeginnerHow do you bootstrap the remote backend, given the bucket must exist before Terraform can use it?IntermediateWhat does a hardened S3 state bucket look like?IntermediateWhat is the minimum IAM permission set for the S3 backend?IntermediateHow do you move from DynamoDB locking to S3 native locking in a live fleet?IntermediateState was deleted or corrupted. How do you recover?Advanced