🚀 DevOps & SRE Certification Program 📅 Starting: 1st of Every Month 🤝 +91 8409492687 🔍 Contact@DevOpsSchool.com

Upgrade & Secure Your Future with DevOps, SRE, DevSecOps, MLOps!

We spend hours on Instagram and YouTube and waste money on coffee and fast food, but won’t spend 30 minutes a day learning skills to boost our careers.
Master in DevOps, SRE, DevSecOps & MLOps!

Learn from Guru Rajesh Kumar and double your salary in just one year.


Get Started Now!

Puppet Tutorials: Installing and Configure Puppet Server & Agent


Setting up Puppet Server in RHEL 8 / CENTOS 8

Step 1 - Add such entry in /etc/hosts
======================================================
$ hostnamectl set-hostname puppet
$ vim /etc/hosts
20.163.145.158 puppet
172.173.236.231 agent1
172.173.236.232 agent3
Step 2 - Enable the Puppet platform on Yum
======================================================
$ sudo rpm -Uvh https://yum.puppet.com/puppet7-release-el-8.noarch.rpm
$ yum install puppetserver
$ sudo systemctl start puppetserver
Step 3 - Open a new shell, or use exec bash to update your PATH
======================================================
$ exec bash
$ puppetserver -v
$ sudo systemctl status puppetserver

Setting up Puppet Agent in Linux

Step 1 - Add such entry in /etc/hosts
======================================================
$ hostnamectl set-hostname agent1
$ vim /etc/hosts
20.163.145.158 puppet
172.173.236.231 agent1
172.173.236.232 agent3
Step 2 - Enable the Puppet platform repository
=========================================================
# RHEL 8 / CENTOS 8
$ sudo rpm -Uvh https://yum.puppet.com/puppet7-release-el-8.noarch.rpm
# RHEL 7 / CENTOS
$ sudo rpm -Uvh https://yum.puppet.com/puppet6-release-el-7.noarch.rpm
Ubuntu
$ wget https://apt.puppetlabs.com/puppet6-release-bionic.deb
$ sudo dpkg -i puppet6-release-bionic.deb
Step 3 - Install Puppet Agent
=========================================================
# RHEL / Centos
$ sudo yum install puppet-agent
$ systemctl status puppet
$ systemctl start puppet
$ systemctl enable puppet
$ systemctl status puppet
$ source /etc/profile.d/puppet-agent.sh
$ sudo /opt/puppetlabs/bin/puppet resource service puppet ensure=running enable=true
# Ubuntu
$ sudo apt-get install puppet-agent
$ systemctl status puppet
$ systemctl start puppet
$ systemctl enable puppet
$ systemctl status puppet
$ source /etc/profile.d/puppet-agent.sh
$ sudo /opt/puppetlabs/bin/puppet resource service puppet ensure=running enable=true

Configure Puppet Agent with Server

@Puppet Agent
$ puppet config set server puppet --section main
$ puppet ssl bootstrap
@Puppet Server
$ puppetserver ca list
$ sudo puppetserver ca sign --certname <agent-name>
@Puppet Agent
puppet ssl bootstrap
puppet agent -t
puppet agent -t -d --trace > puppet_output.txt 2>&1
# Get a debug-level log from an agent run in PE using the command line and save it to a file.
To get a log for an agent running on Linux and Windows, run:
$ puppet agent -t -d --trace > puppet_output.txt 2>&1
To get a log for agent run times, run:
$ puppet agent -t -d --evaltrace --trace > puppet_output.txt 2>&1
To get a log to troubleshoot connectivity issues with the Puppet Server, run:
$ puppet agent -t -d --http_debug --trace > puppet_output.txt 2>&1
Subscribe
Notify of
guest


0 Comments
Newest
Oldest Most Voted
Inline Feedbacks
View all comments

Certification Courses

DevOpsSchool has introduced a series of professional certification courses designed to enhance your skills and expertise in cutting-edge technologies and methodologies. Whether you are aiming to excel in development, security, or operations, these certifications provide a comprehensive learning experience. Explore the following programs:

DevOps Certification, SRE Certification, and DevSecOps Certification by DevOpsSchool

Explore our DevOps Certification, SRE Certification, and DevSecOps Certification programs at DevOpsSchool. Gain the expertise needed to excel in your career with hands-on training and globally recognized certifications.

0
Would love your thoughts, please comment.x
()
x