Wednesday, July 8, 2020

Puppet Tutorial

Puppet Tutorial Puppet Tutorial One Stop Solution For Configuration Management Back Home Categories Online Courses Mock Interviews Webinars NEW Community Write for Us Categories Artificial Intelligence AI vs Machine Learning vs Deep LearningMachine Learning AlgorithmsArtificial Intelligence TutorialWhat is Deep LearningDeep Learning TutorialInstall TensorFlowDeep Learning with PythonBackpropagationTensorFlow TutorialConvolutional Neural Network TutorialVIEW ALL BI and Visualization What is TableauTableau TutorialTableau Interview QuestionsWhat is InformaticaInformatica Interview QuestionsPower BI TutorialPower BI Interview QuestionsOLTP vs OLAPQlikView TutorialAdvanced Excel Formulas TutorialVIEW ALL Big Data What is HadoopHadoop ArchitectureHadoop TutorialHadoop Interview QuestionsHadoop EcosystemData Science vs Big Data vs Data AnalyticsWhat is Big DataMapReduce TutorialPig TutorialSpark TutorialSpark Interview QuestionsBig Data TutorialHive TutorialVIEW ALL Blockchain Blockchain TutorialWhat is BlockchainHyperledger FabricWhat Is EthereumEthereum TutorialB lockchain ApplicationsSolidity TutorialBlockchain ProgrammingHow Blockchain WorksVIEW ALL Cloud Computing What is AWSAWS TutorialAWS CertificationAzure Interview QuestionsAzure TutorialWhat Is Cloud ComputingWhat Is SalesforceIoT TutorialSalesforce TutorialSalesforce Interview QuestionsVIEW ALL Cyber Security Cloud SecurityWhat is CryptographyNmap TutorialSQL Injection AttacksHow To Install Kali LinuxHow to become an Ethical Hacker?Footprinting in Ethical HackingNetwork Scanning for Ethical HackingARP SpoofingApplication SecurityVIEW ALL Data Science Python Pandas TutorialWhat is Machine LearningMachine Learning TutorialMachine Learning ProjectsMachine Learning Interview QuestionsWhat Is Data ScienceSAS TutorialR TutorialData Science ProjectsHow to become a data scientistData Science Interview QuestionsData Scientist SalaryVIEW ALL Data Warehousing and ETL What is Data WarehouseDimension Table in Data WarehousingData Warehousing Interview QuestionsData warehouse architectureTalend T utorialTalend ETL ToolTalend Interview QuestionsFact Table and its TypesInformatica TransformationsInformatica TutorialVIEW ALL Databases What is MySQLMySQL Data TypesSQL JoinsSQL Data TypesWhat is MongoDBMongoDB Interview QuestionsMySQL TutorialSQL Interview QuestionsSQL CommandsMySQL Interview QuestionsVIEW ALL DevOps What is DevOpsDevOps vs AgileDevOps ToolsDevOps TutorialHow To Become A DevOps EngineerDevOps Interview QuestionsWhat Is DockerDocker TutorialDocker Interview QuestionsWhat Is ChefWhat Is KubernetesKubernetes TutorialVIEW ALL Front End Web Development What is JavaScript â€" All You Need To Know About JavaScriptJavaScript TutorialJavaScript Interview QuestionsJavaScript FrameworksAngular TutorialAngular Interview QuestionsWhat is REST API?React TutorialReact vs AngularjQuery TutorialNode TutorialReact Interview QuestionsVIEW ALL Mobile Development Android TutorialAndroid Interview QuestionsAndroid ArchitectureAndroid SQLite DatabaseProgramming One St... DevOps (84 B logs) Become a Certified Professional AWS Global Infrastructure Introduction To DevOps What is DevOps? A Beginner's Guide To Understanding DevOps And Its EvolutionWhat Are Important Pre-Requisites For DevOps Professionals?DevOps in various domains â€" How DevOps solves the problem?DevOps Real Time Scenarios â€" Know What Happens Real TimeWaterfall vs Agile: Which Is Better For You And Why?DevOps vs Agile! Everything You Need To KnowMystery of DevOpsInfrastructure as Code â€" What is it and Why is it it important?Linux commands in DevOps: Must Know For Every DevOps ProfessionalDevOps Tutorial : Introduction To DevOpsTop 10 DevOps Tools You Must Know In 2020Understanding DevOps Tools Development, Testing Deployment Technologies Involved In DevOps Git One Stop Solution For Configuration Management Last updated on May 22,2019 34.5K Views Saurabh Saurabh is a technology enthusiast working as a Research Analyst at Edureka.... Saurabh is a technology enthusiast working as a Res earch Analyst at Edureka. His areas of interest are - DevOps, Artificial Intelligence, Big Data and...1 Comments Bookmark 3 / 4 Blog from Puppet Become a Certified Professional Puppet TutorialPuppet Tutorial is the second blog of Puppet blog series. I hope you have read my previous blog on What is Puppet that explains Configuration Management and why it is important with the help of use-cases.In this Puppet Tutorial following topics will be covered:What is Configuration Management?Puppet Architecture Puppet Master Slave Communication Puppet ComponentsHands-OnWhat is Configuration Management?In my previous blog,I have given an introduction to Configuration Management and what challenges it helps us to overcome. In this Puppet Tutorial, I will explain you about different interdependent activitiesof Configuration Management. But before that, let us understand what is Configuration Item (CI).A Configuration Item is any service component, infrastructure element, or other item that nee ds to be managed in order to ensure the successful delivery of services.Examples of CI include individual requirements documents, software, models, and plans.Configuration Management consists of the following elements:Configuration IdentificationChange ManagementConfiguration Status AccountingConfiguration AuditsThe diagram below explains these components:Configuration Identification: It is the process of:Labeling software and hardware configuration items with unique identifiersIdentifying the documentation that describes a configuration itemGrouping related configuration items into baselinesLabeling revisions to configuration items and baselines.Change Management: It is a systematic approach to dealing with change both from the perspective of an organization and the individual.Configuration Status Accounting: It includes the process of recording and reporting configuration item descriptions (e.g., hardware, software, firmware, etc.) and all departures from the baseline during desig n and production. In the event of suspected problems, the verification of baseline configuration and approved modifications can be quickly determined.Configuration Audits: Configuration audits provide a mechanism for determining the degree to which the current state of the system is consistent with the latest baseline and documentation. Basically, it is a formal review to verify that the product being delivered will work as advertised, promoted or in any way promised to the customers. Ituses the information available as an outcome of the quality audits and testing along with the configuration status accounting information, to provide assurance that what was required has been build. Let us understand Configuration Managementwith a use-case. Suppose if you have to update a particular software or you want to replace it, In that case the below flowchart should be followed for successful Configuration Management:Now is the correct time to understand Puppet Architecture.Puppet Tutorial A rchitecture ofPuppet Puppet uses a Master-Slave architecture. The diagram below depicts the same:The following functions are performed in the above image:The Puppet Agent sends the Facts to the Puppet Master. Facts are basically key/value data pair that represents some aspect of Slavestate, such as its IP address, up-time, operating system, or whether its a virtual machine. I will explain Facts in detail later in the blog.Puppet Master uses the facts to compile a Catalog that defines how the Slaveshould be configured. Catalog is a document that describes the desired state for each resource that Puppet Master manages on a Slave. I will explain catalogs and resources in detail later.Puppet Slave reports back to Master indicating that Configuration is complete, which is visible in the Puppet dashboard.Check out this Puppet tutorial video for deep understanding of Puppet.Puppet Tutorial for Beginners | DevOps Training | EdurekaPuppet Tutorial Puppet Master and Slave CommunicationPuppet Master and Slave communicates through a secure encrypted channel with the help of SSL. The diagram below depicts the same:As you can see from the above Image: Puppet Slave asks for Puppet Master certificate.After receiving Puppet Master certificate, Master requests for Slave certificate.Once Master has signed the Slave certificate, Slave requests for configuration/data.Finally, Puppet Master will send the configuration to Puppet Slave. Let us now have a look at various Puppet components.Puppet Tutorial Components ofPuppet Manifests: Every Slave has got its configuration details in Puppet Master, written in the native Puppet language. These details are written in the language which Puppet can understand and are termed as Manifests. They are composed of Puppet code and their filenames use the .pp extension. These are basically Puppet programs. For example: You can write a Manifest in Puppet Master that creates a file and installs Apache server on all Puppet Slaves connected to the Puppet Master.Module: A Puppet Module is a collection of Manifests and data (such as facts, files, and templates), and they have a specific directory structure. Modules are useful for organizing your Puppet code, because they allow you to split your code into multiple Manifests. Modules are self-contained bundles of code and data.Resource: Resources are the fundamental unit for modeling system configurations. Each Resource describes some aspect of a system, like a specific service or package.Facter: Facter gathers basic information (facts) about Puppet Slavesuch as hardware details, network settings, OS type and version, IP addresses, MAC addresses, SSH keys, and more. These facts are then made available in Puppet Masters Manifests as variables.Mcollective: It is a framework that allows several jobs to be executed in parallelon multiple Slaves. It performs various functions like:Interact with clusters of Slaves, whether in small groups or very large deployments.Use a broadcast parad igm to distribute requests. All Slaves receive all requests at the same time, requests have filters attached, and only Slaves matching the filter will act on requests.Use simple command-line tools to call remote Slaves.Write custom reports about your infrastructure.Catalogs: A Catalog describes the desired state of each managed resource on a Slave. It is a compilation of all the resources that the Puppet Master applies to a given Slave, as well as the relationships between those resources.Catalogs are compiled by a Puppet Master from Manifests and Slave-provided data (such as facts, certificates, and an environment if one is provided), as well as an optional external data (such as data from an external Slave classifier, exported resources, and functions). The Master then serves the compiled Catalog to the Slave when requested.Now in this Puppet Tutorial my next section will focus on Hands-On.Puppet Tutorial Hands-OnI will show you how to deploy MySQL and PHP from Puppet Master to P uppet Slave. I am using only one Slave for demonstration purpose there can be hundreds of Slaves connected to one Master. To deploy PHP and MySQL I will use predefined modules available at forge.puppet.com. You can create your own modules as well.Step 1: In Puppet Masterinstall MySQL and PHP modules.Execute this:1) puppet module install puppetlabs-mysql version 3.10.0This MySQL module installs, configures, and manages the MySQL service. This module manages both the installation and configuration of MySQL, as well as extending Puppet to allow management of MySQL resources, such as databases, users, and grants.2) puppet module install mayflower-php version 4.0.0-beta1This module is used for managing PHP, in particular php-fpm. PHP-FPM (FastCGI Process Manager) is an alternative PHP FastCGI implementation with some additional features useful for sites of any size, especially busier sites.Step 2:In Puppet Manifests include MySQL server and PHP.Execute this: vi /etc/puppet/manifests/site .ppYou can use any other editor as well like vim, gedit etc. In this site.pp file add the following: include '::mysql::server' include '::php' Save and quit.Step 3:Puppet Slaves pulls its configuration from the Master periodically (after every 30 minutes). It will evaluate the main manifest and apply the module that specifies MySQL and PHP setup. If you want to try it out immediately, you need to run the following command on every Slave node:Execute this: puppet agent -tSo MySQL and PHP is installed successfully on the Slave node.Step 4:To check the version of MySQL and PHP installed:Execute this: 1) mysql-v2) php -versionCongratulations! MySQl and PHP is up and running in your Puppet Slave. Here I have shown you only one Slave but imagine if there are hundreds of Slaves. In that scenario your work becomes so easy, Just specify the configurations in Puppet Master and Puppet Slaves will automatically evaluate the main manifest and apply the module that specifies MySQL and PHP setup.If you found this Puppet Tutorialrelevant,check out theDevOps trainingby Edureka,a trusted online learning companywith a network of more than250, 000satisfied learnersspread acrossthe globe. The Edureka DevOps Certification Training coursehelps learners gain expertise in various DevOps processes and tools such asPuppet, Jenkins, Nagios and GIT for automating multiple steps in SDLC.Recommended videos for you What is Docker DevOps Tool For Containerization Watch Now Devops : Automate Your Infrastructure With Puppet Watch Now What is DevOps A Beginners Guide To DevOps Watch Now What is Git A Complete Git Tutorial For Beginners Watch Now DevOps Tutorial For Beginners Watch Now DevOps-Redefining your IT Strategy Watch Now Continuous Integration With Jenkins Watch Now Puppet Tutorial DevOps Tool For Configuration Management Watch Now What is Jenkins? Continuous Integration With Jenkins Watch Now Ansible Tutorial For Beginners Ansible Playbook Watch Now 5 Best Practices In DevOps Culture Watch Now DevOps is Going to Replace SDLC! Learn Why Watch Now Top DevOps Interview Questions And Answers Watch NowRecommended blogs for you W hat Are Important Pre-Requisites For DevOps Professionals? Read Article Who Is A DevOps Engineer? DevOps Engineer Roles And Responsibilities Read Article Understanding Kubernetes Architecture Read Article What is Continuous Integration? Read Article Ansible Tutorial Learn To Write Ansible Playbooks Read Article Top 20 Git Commands with Example Read Article What Is Ansible? Configuration Management And Automation With Ansible Read Article Git bisect: How to identify a bug in your code? Read Article All You Need To Know About Continuous Integration With Jenkins Read Article Ansible Provisioning: Smarter and Effortless way of Provisioning Read Article Git Submodules vs. Google’s Repo Tool Read Article DevOps Engineer Career Path: Your Guide To Bagging Top DevOps Jobs Read Article What Is Docker Docker Container ? A Deep Dive Into Docker ! Read Article Top DevOps Interview Questions You Must Prepare In 2020 Read Article What Is Agile Methodology Know the What and How? Read Articl e CI CD Pipeline Learn how to Setup a CI CD Pipeline from Scratch Read Article Pokemon Go â€" a perfect use-case of DevOps principles Read Article Continuous Deployment A Comprehensive Guide With An Example Read Article Ansible for AWS Managing Cloud Made Easy Read Article Gitting Ahead: Hacking Git and GitHub Part 2 Read Article Comments 1 Comment Trending Courses in DevOps DevOps Certification Training72k Enrolled LearnersWeekend/WeekdayLive Class Reviews 5 (28700)

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.