Overview of Puppet and its components and concept of configuration management

Last updated on Nov 29 2021
Satyen Sahu

Table of Contents

Overview of Puppet and its components and concept of configuration management

Puppet – Overview

Puppet is a configuration management tool developed by Puppet Labs in order to automate infrastructure management and configuration. Puppet is a very powerful tool which helps in the concept of Infrastructure as code. This tool is written in Ruby DSL language that helps in converting a complete infrastructure in code format, which can be easily managed and configured.

Puppet follows the client-server model, where one machine in any cluster acts as the server, known as puppet master and the other acts as a client known as a slave on nodes. Puppet has the capability to manage any system from scratch, starting from initial configuration till the end-of-life of any particular machine.

Features of Puppet System

Following are the most important features of Puppet.

Idempotency

Puppet supports Idempotency which makes it unique. Similar to Chef, in Puppet, one can safely run the same set of configuration multiple times on the same machine. In this flow, Puppet checks for the current status of the target machine and will only make changes when there is any specific change in the configuration.

Idempotency helps in managing any particular machine throughout its lifecycle starting from the creation of machine, configurational changes in the machine, till the end-of-life. Puppet Idempotency feature is very helpful in keeping the machine updated for years rather than rebuilding the same machine multiple times, when there is any configurational change.

Cross-platform

In Puppet, with the help of Resource Abstraction Layer (RAL) which uses Puppet resources, one can target the specified configuration of system without worrying about the implementation details and how the configuration command will work inside the system, which are defined in the underlying configuration file.

Puppet − Workflow

Puppet uses the following workflow to apply configuration on the system.

image1 28

  • In Puppet, the first thing what the Puppet master does is to collect the details of the target machine. Using the factor which is present on all Puppet nodes (similar to Ohai in Chef) it gets all the machine level configuration details. These details are collected and sent back to the Puppet master.
  • Then the puppet master compares the retrieved configuration with defined configuration details, and with the defined configuration it creates a catalog and sends it to the targeted Puppet agents.
  • The Puppet agent then applies those configurations to get the system into a desired state.
  • Finally, once one has the target node in a desired state, it sends a report back to the Puppet master, which helps the Puppet master in understanding where the current state of the system is, as defined in the catalog.

Puppet − Key Components

Following are the key components of Puppet.

image2 25

Puppet Resources

Puppet resources are the key components for modeling any particular machine. These resources have their own implementation model. Puppet uses the same model to get any particular resource in the desired state.

Providers

Providers are basically fulfillers of any particular resource used in Puppet. For example, the package type ‘apt-get’ and ‘yum’ both are valid for package management. Sometimes, more than one provider would be available on a particular platform. Though each platform always have a default provider.

Manifest

Manifest is a collection of resources which are coupled inside the function or classes to configure any target system. They contain a set of Ruby code in order to configure a system.

Modules

Module is the key building block of Puppet, which can be defined as a collection of resources, files, templates, etc. They can be easily distributed among different kinds of OS being defined that they are of the same flavor. As they can be easily distributed, one module can be used multiple times with the same configuration.

Templates

Templates use Ruby expressions to define the customized content and variable input. They are used to develop custom content. Templates are defined in manifests and are copied to a location on the system. For example, if one wants to define httpd with a customizable port, then it can be done using the following expression.

Listen <% = @httpd_port %>

The httpd_port variable in this case is defined in the manifest that references this template.

Static Files

Static files can be defined as a general file which are sometimes required to perform specific tasks. They can be simply copied from one location to another using Puppet. All static files are located inside the files directory of any module. Any manipulation of the file in a manifest is done using the file resource.

Configuration Management

System administrators regularly execute repetitive tasks such as server installation, server configuration, etc. By writing some scripts, they can automate this function, but when you are operating on big infrastructure, it is a very difficult job.

To solve this difficulty, configuration management came into the market. Configuration management is the process of maintaining software and computer systems like networks, servers, storage in configured, desired, and consistent state.

Through configuration management, we can access the exact historical record of system position for project management and audit purposes.

By the help of Configuration Management, we can remove the following challenges:

  • Finding out which components to modify when the needs change.
  • Need for reimplementation because of the requirements changes in the last implementation.
  • If any component is replaced with the new but flawed version, then it needs to revert the previous version.
  • Need to replace the wrong component since the admin was unable to determine which component should be replaced.

Configuration Management Process

A configuration item (CI) is an infrastructure element or any service component or any component that needs to manage in order to ensure the successful delivery of services. Configuration items such as individual documents, model plans, etc.

Configuration management has different interdependent processes or activities. These activities are as follows:

  • Configuration Identification
  • Change Management
  • Configuration Status Accounting
  • Configuration Audits

Let’s see these activities in details:

Configuration Identification

  • It labels h/w and s/w configuration items with a unique identifier.
  • It identifies the documentation that defines a configuration item.
  • It is used to group related configuration items into the baseline.
  • It is used to label revisions to configuration items and baselines.

Change Management

It deals with the changes either at the individual or organization level.

Configuration Status Accounting

It is used to report the configuration item details such as hardware, software, firmware, etc. and all deviations from the baseline during design and development.

Configuration Audits

Configuration Audit helps in identifying the current state of the system. It is a process of reviewing the product and its expected behavior as it is supposed that it should behave as promised to the customer. The outcome information of any quality audit and testing is used along with the configuration status accounting information, and it is done to ensure that all the promised features have been delivered.

image3 21

Configuration Management Tool

There are many configuration management tools existing in the market. Some popular configuration management tools are:

  • Ansible
  • Puppet
  • Chef
  • Microsoft System Center Configuration manager
  • HashiCorp Terraform
  • CFEngine
  • AWS OpsWorks
  • Saltstack

So, this brings us to the end of blog. This Tecklearn ‘Overview of Puppet and its components and concept of configuration management’ blog helps you with commonly asked questions if you are looking out for a job in DevOps. If you wish to learn Puppet and build a career in DevOps domain, then check out our interactive, Continuous Deployment: Configuration Management using Puppet Training, that comes with 24*7 support to guide you throughout your learning period. Please find the link for course details:

https://www.tecklearn.com/course/continuous-deployment-configuration-management-using-puppet/

Continuous Deployment: Configuration Management using Puppet Training

About the Course

Tecklearn has specially designed this Continuous Deployment: Configuration Management using Puppet Training Course to advance your skills for a successful career in this domain. The course will cover different components of Git and GitHub and how they are used in software development operations. The course consists of Configuration Management using Puppet, Puppet Components, important concepts like Puppet Lifecycle, Puppet Language and Puppet Installation. You will get an in-depth knowledge of these concepts and will be able to work on related demos. Upon completion of this online training, you will hold a solid understanding and hands-on experience with Puppet.

Why Should you take Configuration Management using Puppet Training?

  • Average salary of Puppet Professional is $90k – Payscale.com
  • Uber, Salesforce, PayPal, Booking.com, MIT, Starbucks. & many other MNC’s worldwide use Puppet across industries.
  • According to Grand View Research, the DevOps market size is estimated to be worth $12.85 billion by 2025. DevOps professionals are highly paid and in-demand throughout industries including retail, eCommerce, finance, and technology.

What you will Learn in this Course?

Introduction to DevOps

  • What is Software Development
  • Software Development Life Cycle
  • Why DevOps?
  • What is DevOps?
  • DevOps Lifecycle
  • DevOps Tools
  • Benefits of DevOps
  • How DevOps is related to Agile Delivery
  • DevOps Implementation

Continuous Deployment: Configuration Management using Puppet

  • Need of Configuration Management
  • What is Puppet
  • Puppet Architecture
  • Puppet Components
  • Puppet Lifecycle
  • Setting up Master Slave using Puppet
  • Puppet Manifests
  • Puppet Modules
  • Applying configuration using Puppet
  • Puppet File Server
  • Hands On

 

0 responses on "Overview of Puppet and its components and concept of configuration management"

Leave a Message

Your email address will not be published. Required fields are marked *