Book Image

Puppet 3: Beginner's Guide

By : John Arundel
Book Image

Puppet 3: Beginner's Guide

By: John Arundel

Overview of this book

<p>Everyone's talking about Puppet, the open-source DevOps technology that lets you automate your server setups and manage websites, databases, and desktops. Puppet can build new servers in seconds, keep your systems constantly up to date, and automate daily maintenance tasks. <br /><br />"Puppet 3 Beginner's Guide" gets you up and running with Puppet straight away, with complete real world examples. Each chapter builds your skills, adding new Puppet features, always with a practical focus. You'll learn everything you need to manage your whole infrastructure with Puppet.<br /><br />"Puppet 3 Beginner’s Guide" takes you from complete beginner to confident Puppet user, through a series of clear, simple examples, with full explanations at every stage.</p> <p>Through a series of worked examples introducing Puppet to a fictional web company, you'll learn how to manage every aspect of your server setup. Switching to Puppet needn't be a big, long-term project; this book will show you how to start by bringing one small part of your systems under Puppet control and, little by little, building to the point where Puppet is managing your whole infrastructure.</p> <p>Presented in an easy-to-read guide to learning Puppet from scratch, this book explains simply and clearly all you need to know to use this essential IT power tool, all the time applying these solutions to real-world scenarios.</p>
Table of Contents (17 chapters)
Puppet 3 Beginner's Guide
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Solving the problem


Most of us have tried to solve these problems of configuration management in various ways. Some write shell scripts to automate builds and installs, some use makefiles to generate configurations, some use templates and disk images, and so on. Often these techniques are combined with version control, to solve the history problem. Systems like these can be quite effective, and even a little bit of automation is much better than none.

Reinventing the wheel

The disadvantage with this kind of home-brewed solution is that each sysadmin has to reinvent the wheel, often many times. The ways in which organizations solve the configuration management problem are usually proprietary and highly site-specific. So for every new place you work, you need to build a new configuration management system (CM system).

Because everyone has his own proprietary, unique system, the skills associated with it aren't transferable. When you get a new job, all the time and effort you spent becoming a wizard on your organization's CM system goes to waste; you have to learn a new one.

A waste of effort

Also, there's a whole lot of duplicated effort. The world really doesn't need more template engines, for example. Once a decent one exists, it would make sense for everybody to use it, and take advantage of ongoing improvements and updates.

It's not just the CM system itself that represents duplicated, wasted effort. The configuration scripts and templates you write could also be shared and improved by others, if only they had access to them. After all, most server software is pretty widely used. A program in configuration language that sets up Apache could be used by everybody who uses Apache—if it were a standard language.

Transferable skills

Once you have a CM system with a critical mass of users, you get a lot of benefits. A new system administrator doesn't have to write his own CM tool, he just grabs one off the shelf. Once he learns to use it, and to write programs in the standard language, he can take that skill with him to other jobs.

He can choose from a large library of existing programs in the standard configuration language, covering most of the popular software in use. These programs are updated and improved to keep up with changes in the software and operating systems they manage.

This kind of beneficial network effect is why we don't have a million different operating systems, or programming languages, or processor chips. There's strong pressure for people to converge on a standard. On the other hand, we don't have just one of each of those things either. There's never just one solution that pleases everybody.

If you're not happy with an existing CM system, and you have the skills, you can write one that works the way you prefer. If enough other people feel the same way, they will form a critical mass of users for the new system. But this won't happen indefinitely; standardization pressure means the market will tend to converge on a small number of competing systems.

Configuration management tools

This is roughly the situation we have now. Several different CM systems have been developed over the years, with new ones coming along all the time, but only a few have achieved significant market share. At the time of writing, at least for UNIX-like systems, these CM systems are Puppet, Chef, and CFEngine.

There really isn't much to choose between these different systems. They all solve more or less the same problems—the ones we saw earlier in this chapter—in more or less the same way. Some people prefer the Puppet way of doing things; some people are more comfortable with Chef, and so on.

But essentially, these, and many other CM systems, are all great solutions to the CM problem, and it's not very important which one you choose as long as you choose one.