Automation · Drift Management
Actual State
Cheat sheet · https://pcornel.dk/topic.php?topic=6007
Answer
Actual state is the real, current configuration of a system as observed by reading it, which drift management compares with the desired state to find differences.
Remember
- Actual state is what the system reports now.
- Read it, don't assume it.
- Collect it the same way every time.
First checks
- Facts/state collection — actual
- Fresh reads, not cache — accuracy
- Normalised representation — comparable
Verify in this order
systems → collection → actual state
Where it usually breaks
Configuration/input → graph/state refresh → plan → provider API request → provider terminal result → resource read-back → effective service state → workload.
Drift Management → Actual State · operational reference
| Layer | Drift Management → Actual State operational reference |
|---|---|
| Runtime/ownership | Drift management / Terraform actual-state reconciliation · identify controller/parser, durable intent, identity and target ownership before mutation |
| Persistent intent | Versioned definition/configuration with explicit dependencies, scope and credential boundary |
| Verification | terraform plan -refresh-only -detailed-exitcode; compare configuration, stored state and provider-read remote object before deciding reconciliation. |
| Expected interpretation | The process distinguishes desired configuration, tool state and remote actual state, identifies external change without mutating blindly, and records the chosen reconcile direction. |
| Recovery boundary | Preserve correlation IDs + pre-state, repair first failing boundary, then verify the target independently |
Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=6007