Which Configuration Management Tool Should I Use? Spotlight on Chef

Aug 21, 2019 7:54:16 PM / by KernelCare Team

The rise of DevOps has necessitated the creation of tools that enable engineers to manage hundreds or even thousands of machines at once. Through a process known as infrastructure as code (IaC) – where an IT environment is declared via a programming language – Configuration Management (CM) tools allow SysAdmins and DevOps teams to maintain visibility over their server infrastructure, and deploy and take action at a mass scale. CM tools facilitate the execution of tasks on multiple servers at once, and one-click app deployment.

When it comes to mass deployment and CM, there are four big software players: Puppet, Ansible, Saltstack, and Chef. KernelCare can be deployed via all four of them. Chef is a popular option, with unique pros and cons. Here is everything you need to know.

 

The Good: The programmer’s choice

Beginning life as an internal end-to-end server deployment tool for OpsCode, Chef was first released as an open source solution in 2009. It stands out as the CM tool built on a  client-server architecture model. Chef uses an imperative programming paradigm, and it utilises the pull-based approach to send configuration information to target nodes (which are installed with agents). This is similar to Puppet’s master-agent model, except that the Chef workstation is needed to control configurations from master to agent.

Chef’s imperative model sees commands execute in sequential order, allowing engineers to pinpoint the individual steps needed to manage each machine. It takes its name from the way its processes are structured: Definition files are called “recipes,” and can be merged with files, attributes, libraries etc. to create “cookbooks.” Although recipes use a domain-specific language unique to Chef, they support scripts written in plain Ruby.

Chef is popular, and with good reason. It is built for programmers. Its code-driven setup offers a great amount of control and flexibility, right up to the creation of modules, making Chef probably the most customizable and adaptable of all the CM solutions. Its configuration, being rooted in Git, means it has strong version control capabilities. 

As well as being deeply programming-based and thus super-flexible, Chef is very reliable. 2009 is ancient in the software world, and this persistence means that Chef is highly stable and mature. The Chef community is active, offering strong documentation and support. There is a rich base of configuration recipes and modules (including more than 900 free modules). Also, the SaaS version of Chef is very useful if you want analytics and reporting.

The Bad: Steep learning curve

Chef was built for programmers. Which is great – if you’re a programmer. But if you’re not, it can be very hard work. If you’re still learning the ropes, or if you’re not a Ruby user, Chef can be daunting. It will take a lot of learning to get comfortable, even with the simple steps of configuring the chef and carrying out the initial setups. The code bases are large, the environments are complex, and the documentation is spread out.

Also, Chef’s pull-based setup means that configurations will only be collected from the server at the next scheduled polling. The lack of push means no immediate action on changes. 

 

Overall 

With Chef, it’s quite simple. If you have the (Ruby) programming nous, then it’s the CM tool for you. It is completely programmable, so the scope of handling and customization is massive. What’s more, Chef is super stable, and great for large-scale deployments across both public and private environments that need a large storage. But if you need something nimbler, more agile, and easy to pick up and use, Chef probably isn’t the best choice. 

KernelCare Team

Written by KernelCare Team