Configuration Drift: When Servers Go Rogue
Configuration drift is when a server's live settings diverge from your version-controlled 'source of truth.' This happens from manual hotfixes or inconsistent deployments, creating snowflake servers that are hard to debug.
WHY IT EXISTS: In complex systems, there's constant pressure to make quick changes, especially to fix urgent production issues. These manual, out-of-band changes accumulate over time, creating a gap between the intended state defined in code and the actual state running on live servers.
THE MENTAL MODEL: Think of your infrastructure-as-code (IaC) files in Git as the architectural blueprint for a building. Configuration drift is like construction workers making undocumented changes on-site—moving a wall, adding a window. The building still stands, but it no longer matches the blueprint, making future renovations risky and unpredictable.
HOW IT WORKS: Drift occurs when the actual state of a system component—like a server, database, or network rule—changes without updating its corresponding definition in a configuration management tool. Common causes include manual SSH commands to apply a hotfix, automated OS updates that aren't part of the main deployment pipeline, or scripts run by different teams. The result is an environment that is inconsistent and no longer reproducible from code, creating 'snowflake servers'.
WHEN TO USE IT: You don't 'use' drift; you fight it. The primary defense is a combination of infrastructure-as-code (Terraform, CloudFormation) and configuration management (Ansible, Puppet, Chef). These tools define the desired state in code. Regularly running them in a check mode (e.g., terraform plan) detects drift, and applying the code can automatically correct it, a process called reconciliation.
WHEN NOT TO USE IT: While the goal is to eliminate drift, enforcing strict configuration control might be overkill for temporary, throwaway experimental environments. However, for any system that requires reliability, security, and scalability—especially production—unmanaged drift is a significant liability that leads to outages and security holes.
ONE CANONICAL EXAMPLE: An engineer gets an alert for a failing web server. To fix it quickly, they SSH into the machine and manually increase the number of worker processes in a config file, then restart the service. The immediate problem is solved. However, the change isn't committed to the Ansible playbook. Weeks later, when a new server is provisioned from that same playbook, it's built with the old, lower worker count, leading to performance issues and confusing debugging sessions. The original server has 'drifted' from its intended configuration.
Read the original → plurilock.com
Get five bites like this every day.
Tezvyn delivers a daily feed of 60-second tech bites with quizzes to lock in what you learn.