What? The way you would treat your dog is very different from how a farmer would treat his cattle. You give your dog a sentimental name, play with him often, and when he gets sick you take him to the vet and spend lots of time and money making him better. On the other hand, a cow is given a generic name, isnâ€™t played with individually but is driven as part of the herd.
Servers for a long time in IT have been dogs, theyâ€™re occasionally even named dog names and thought of fondly (or hatefully). Weâ€™ve cared for them, gave them redundant networking, redundant power supplies, and many, many hard drives. When they fail, we restore them from backups or login and troubleshoot manually for as many hours as it takes to bring our server back online. Cattle servers, on the other hand are cheap, small, and can be replaced. So if one has issues at 3am, itâ€™s much easier to bring up a fully-working replacement. Putting services into virtual machines hosted â€śin the cloudâ€ť turns our dog servers, which are expensive and time-consuming to cattle servers, which are cheap and low-individual-investment.
Why? Many reasons, mainly because infrastructure is cheaper than human time. Youâ€™ll nearly always have more servers than systems administrators, so why does a systems administrator spend many hours on a single broken server, when there are many that could require his attention?
Humans drive cattle as a herd and tend to interact with cattle only rarely one-on-one. As such, weâ€™ll need tools to drive and manage our herd so we donâ€™t need to login and duplicate the same work across all the servers. Thatâ€™s where configuration management software comes into play. We store templates of servers, saved in configuration files using our configuration management software as a central repository; an archive of servers, if you will. From these templates, you can spin up any number of servers with exactly the same software on them. Because we can easily spin up copies, our configuration management software also becomes a backup of all of our servers. While weâ€™ll still need to backup the data, the configurations (as long as they were pulled from the central repository) are safe. This also means that we can make changes to the central repository copies and then push out the changes to our herd, essentially driving them as a group.
How? The magic component here is â€śConfiguration Management Softwareâ€ť. This can show up in many forms. Options for configuration management range from homemade BASH or Python scripts to open source and commercial products like Chef, Puppet, Salt, or even VMWareâ€™s vFabric. In future articles weâ€™ll talk about how SingleHop is making the transition of its own infrastructure from dog servers to cattle servers, what tools weâ€™re using and how itâ€™s coming along.
Next up, weâ€™ll go deeper into why this is helpful for preventing cruft in application environments, easing code deployments, and improving flexibility.