Setup Puppet Server 6 on CentOS 7

Puppet is a ruby based configuration management tool (IT automation software), licensed under Apache 2.0 designed to help system administrators, automate many repetitive task they regularly perform . It is open-source, flexible, customizable framework for managing the configuratons of computer system. It defines and enforce the state of your infrustructure throughout the software development cycle. Puppet ensures consistency and dependability across your infrustrucutre.

Puppet can be used to manage configuration on Unix, Linux and Microsoft Windows platform. Puppet can manage hosts throughout it’s life cycle: begining from initial builds and installation, to upgrade, maintenance and finally, end-of -life. Puppet is designed to continiously interect with the hosts.

Puppet is an open-source software configuration management tool based on ruby. Puppet is designed to manage the configuration of Unix-like and Microsoft Windows systems declaratively. The user describes system resources and their state, either using Puppet’s declarative language or a Ruby DSL (domain-specific language). This information is stored in files called “Puppet manifests”. Puppet discovers the system information via a utility called Facter, and compiles the Puppet manifests into a system-specific catalog containing resources and resource dependency, which are applied against the target systems. Any actions taken by Puppet are then reported.

Desired State of Puppet Infrastructure

  • Facts: The puppet agent on each node, send data about the node’s state called as facts to the puppet master server.
  • Catalog: The puppet master uses fact to compile detailed data about how the node should be configured, called the catalog and send it back to the puppet agent. The puppet agent makes any changes as per the catalog. The agent can also simulate these changes in –noop mode i.e. dry run.
  • Report: Each puppet agent sends report to the puppet master, indicating any changes made to the configuration.
  • Report Collection: Puppets open API can send data to the third-party tool. So, infrustructure can be shared with other teams.

Configure Hosts

Connect to puppet server and puppet client and add host entry as shown below. Also, verify that each server is accessible using hostname from one another.

[root@puppetserver ~]# cat /etc/hosts
192.168.56.100  puppetserver
192.168.56.101  puppetclient
[root@puppetserver ~]#

[root@puppetclient ~]# cat /etc/hosts
192.168.56.100  puppetserver
192.168.56.101  puppetclient
[root@puppetclient ~]#

System Requirements

Puppet Server is configured to use 2GB of RAM by default. Just to play around with an installation on a Virtual Machine. However, ram can be reduced to minimum of 512MB in test enviornment. Make sure you have good amount of ram when using puppet server in production though to guarantee optimal performance.

Puppet Server: Installing

Enable the puppetlabs package repository i.e. for centos and debian based systems. Check the operating system version and download the compatiable repository package.

[root@puppetserver ~]# rpm -Uvh http://yum.puppet.com/puppet6/puppet6-release-el-7.noarch.rpm
Retrieving http://yum.puppet.com/puppet6/puppet6-release-el-7.noarch.rpm
warning: /var/tmp/rpm-tmp.qjhWxg: Header V4 RSA/SHA256 Signature, key ID ef8d349f: NOKEY
Preparing...                          ################################# [100%]
Updating / installing...
   1:puppet6-release-6.0.0-1.el7      ################################# [100%]
[root@puppetserver ~]#
[root@puppetserver ~]# yum repolist
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirror.nbrc.ac.in
 * extras: mirror.nbrc.ac.in
 * updates: mirror.nbrc.ac.in
puppet6                                                                                                                             | 2.5 kB  00:00:00
puppet6/x86_64/primary_db                                                                                                           |  91 kB  00:00:00
repo id                                                           repo name                                                                          status
base/7/x86_64                                                     CentOS-7 - Base                                                                    10,019
extras/7/x86_64                                                   CentOS-7 - Extras                                                                     382
puppet6/x86_64                                                    Puppet 6 Repository el 7 - x86_64                                                      61
updates/7/x86_64                                                  CentOS-7 - Updates                                                                  1,477
repolist: 11,939
[root@puppetserver ~]#

Install

Install the Puppet Server using the below command. This command will install puppetserver (don’t confuse with puppet-server) along with all it’s dependencies. The dependency packages are listed below as well. This gives an idea of the dependencies.

[root@puppetserver ~]# yum install puppetserver puppetdb puppetdb-termini
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirror.nbrc.ac.in
 * extras: mirror.nbrc.ac.in
 * updates: mirror.nbrc.ac.in
base                                                                                                                                | 3.6 kB  00:00:00
extras                                                                                                                              | 3.4 kB  00:00:00
puppet6                                                                                                                             | 2.5 kB  00:00:00
updates                                                                                                                             | 3.4 kB  00:00:00
Resolving Dependencies
--> Running transaction check
---> Package puppetdb.noarch 0:6.3.0-1.el7 will be installed
--> Processing Dependency: puppet-agent >= 5.99.0 for package: puppetdb-6.3.0-1.el7.noarch
--> Processing Dependency: net-tools for package: puppetdb-6.3.0-1.el7.noarch
--> Processing Dependency: java-1.8.0-openjdk-headless for package: puppetdb-6.3.0-1.el7.noarch
---> Package puppetdb-termini.noarch 0:6.3.0-1.el7 will be installed
---> Package puppetserver.noarch 0:6.3.0-1.el7 will be installed
--> Running transaction check
---> Package java-1.8.0-openjdk-headless.x86_64 1:1.8.0.201.b09-2.el7_6 will be installed
--> Processing Dependency: tzdata-java >= 2015d for package: 1:java-1.8.0-openjdk-headless-1.8.0.201.b09-2.el7_6.x86_64
--> Processing Dependency: copy-jdk-configs >= 3.3 for package: 1:java-1.8.0-openjdk-headless-1.8.0.201.b09-2.el7_6.x86_64
--> Processing Dependency: pcsc-lite-libs(x86-64) for package: 1:java-1.8.0-openjdk-headless-1.8.0.201.b09-2.el7_6.x86_64
--> Processing Dependency: lksctp-tools(x86-64) for package: 1:java-1.8.0-openjdk-headless-1.8.0.201.b09-2.el7_6.x86_64
--> Processing Dependency: libjpeg.so.62(LIBJPEG_6.2)(64bit) for package: 1:java-1.8.0-openjdk-headless-1.8.0.201.b09-2.el7_6.x86_64
--> Processing Dependency: jpackage-utils for package: 1:java-1.8.0-openjdk-headless-1.8.0.201.b09-2.el7_6.x86_64
--> Processing Dependency: cups-libs(x86-64) for package: 1:java-1.8.0-openjdk-headless-1.8.0.201.b09-2.el7_6.x86_64
--> Processing Dependency: libjpeg.so.62()(64bit) for package: 1:java-1.8.0-openjdk-headless-1.8.0.201.b09-2.el7_6.x86_64
---> Package net-tools.x86_64 0:2.0-0.24.20131004git.el7 will be installed
---> Package puppet-agent.x86_64 0:6.4.0-1.el7 will be installed
--> Running transaction check
---> Package copy-jdk-configs.noarch 0:3.3-10.el7_5 will be installed
---> Package cups-libs.x86_64 1:1.6.3-35.el7 will be installed
--> Processing Dependency: libavahi-common.so.3()(64bit) for package: 1:cups-libs-1.6.3-35.el7.x86_64
--> Processing Dependency: libavahi-client.so.3()(64bit) for package: 1:cups-libs-1.6.3-35.el7.x86_64
---> Package javapackages-tools.noarch 0:3.4.1-11.el7 will be installed
--> Processing Dependency: python-javapackages = 3.4.1-11.el7 for package: javapackages-tools-3.4.1-11.el7.noarch
--> Processing Dependency: libxslt for package: javapackages-tools-3.4.1-11.el7.noarch
---> Package libjpeg-turbo.x86_64 0:1.2.90-6.el7 will be installed
---> Package lksctp-tools.x86_64 0:1.0.17-2.el7 will be installed
---> Package pcsc-lite-libs.x86_64 0:1.8.8-8.el7 will be installed
---> Package tzdata-java.noarch 0:2018i-1.el7 will be installed
--> Running transaction check
---> Package avahi-libs.x86_64 0:0.6.31-19.el7 will be installed
---> Package libxslt.x86_64 0:1.1.28-5.el7 will be installed
---> Package python-javapackages.noarch 0:3.4.1-11.el7 will be installed
--> Processing Dependency: python-lxml for package: python-javapackages-3.4.1-11.el7.noarch
--> Running transaction check
---> Package python-lxml.x86_64 0:3.2.1-4.el7 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

===========================================================================================================================================================
 Package                                         Arch                       Version                                      Repository                   Size
===========================================================================================================================================================
Installing:
 puppetdb                                        noarch                     6.3.0-1.el7                                  puppet6                      40 M
 puppetdb-termini                                noarch                     6.3.0-1.el7                                  puppet6                      23 k
 puppetserver                                    noarch                     6.3.0-1.el7                                  puppet6                      74 M
Installing for dependencies:
 avahi-libs                                      x86_64                     0.6.31-19.el7                                base                         61 k
 copy-jdk-configs                                noarch                     3.3-10.el7_5                                 base                         21 k
 cups-libs                                       x86_64                     1:1.6.3-35.el7                               base                        357 k
 java-1.8.0-openjdk-headless                     x86_64                     1:1.8.0.201.b09-2.el7_6                      updates                      32 M
 javapackages-tools                              noarch                     3.4.1-11.el7                                 base                         73 k
 libjpeg-turbo                                   x86_64                     1.2.90-6.el7                                 base                        134 k
 libxslt                                         x86_64                     1.1.28-5.el7                                 base                        242 k
 lksctp-tools                                    x86_64                     1.0.17-2.el7                                 base                         88 k
 net-tools                                       x86_64                     2.0-0.24.20131004git.el7                     base                        306 k
 pcsc-lite-libs                                  x86_64                     1.8.8-8.el7                                  base                         34 k
 puppet-agent                                    x86_64                     6.4.0-1.el7                                  puppet6                      22 M
 python-javapackages                             noarch                     3.4.1-11.el7                                 base                         31 k
 python-lxml                                     x86_64                     3.2.1-4.el7                                  base                        758 k
 tzdata-java                                     noarch                     2018i-1.el7                                  updates                     187 k

Transaction Summary
===========================================================================================================================================================
Install  3 Packages (+14 Dependent packages)

Total download size: 170 M
Installed size: 334 M
Is this ok [y/d/N]: y
Downloading packages:
(1/17): avahi-libs-0.6.31-19.el7.x86_64.rpm                                                                                         |  61 kB  00:00:00
(2/17): libjpeg-turbo-1.2.90-6.el7.x86_64.rpm                                                                                       | 134 kB  00:00:00
(3/17): javapackages-tools-3.4.1-11.el7.noarch.rpm                                                                                  |  73 kB  00:00:00
(4/17): copy-jdk-configs-3.3-10.el7_5.noarch.rpm                                                                                    |  21 kB  00:00:00
(5/17): lksctp-tools-1.0.17-2.el7.x86_64.rpm                                                                                        |  88 kB  00:00:00
(6/17): libxslt-1.1.28-5.el7.x86_64.rpm                                                                                             | 242 kB  00:00:00
(7/17): pcsc-lite-libs-1.8.8-8.el7.x86_64.rpm                                                                                       |  34 kB  00:00:00
(8/17): cups-libs-1.6.3-35.el7.x86_64.rpm                                                                                           | 357 kB  00:00:14
warning: /var/cache/yum/x86_64/7/puppet6/packages/puppet-agent-6.4.0-1.el7.x86_64.rpm: Header V4 RSA/SHA256 Signature, key ID ef8d349f: NOKEY 00:01:07 ETA
Public key for puppet-agent-6.4.0-1.el7.x86_64.rpm is not installed
(9/17): puppet-agent-6.4.0-1.el7.x86_64.rpm                                                                                         |  22 MB  00:00:20
(10/17): puppetdb-termini-6.3.0-1.el7.noarch.rpm                                                                                    |  23 kB  00:00:00
(11/17): python-javapackages-3.4.1-11.el7.noarch.rpm                                                                                |  31 kB  00:00:00
(12/17): net-tools-2.0-0.24.20131004git.el7.x86_64.rpm                                                                              | 306 kB  00:00:23
(13/17): tzdata-java-2018i-1.el7.noarch.rpm                                                                                         | 187 kB  00:00:09
(14/17): python-lxml-3.2.1-4.el7.x86_64.rpm                                                                                         | 758 kB  00:00:16
(15/17): puppetdb-6.3.0-1.el7.noarch.rpm                                                                                            |  40 MB  00:00:40
(16/17): puppetserver-6.3.0-1.el7.noarch.rpm                                                                                        |  74 MB  00:01:00
(17/17): java-1.8.0-openjdk-headless-1.8.0.201.b09-2.el7_6.x86_64.rpm                                                               |  32 MB  00:02:14
-----------------------------------------------------------------------------------------------------------------------------------------------------------
Total                                                                                                                      1.3 MB/s | 170 MB  00:02:15
Retrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-puppet6-release
Importing GPG key 0xEF8D349F:
 Userid     : "Puppet, Inc. Release Key (Puppet, Inc. Release Key) <release@puppet.com>"
 Fingerprint: 6f6b 1550 9cf8 e59e 6e46 9f32 7f43 8280 ef8d 349f
 Package    : puppet6-release-6.0.0-1.el7.noarch (installed)
 From       : /etc/pki/rpm-gpg/RPM-GPG-KEY-puppet6-release
Is this ok [y/N]: y
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Warning: RPMDB altered outside of yum.
  Installing : puppet-agent-6.4.0-1.el7.x86_64                                                                                                        1/17
  Installing : libxslt-1.1.28-5.el7.x86_64                                                                                                            2/17
  Installing : net-tools-2.0-0.24.20131004git.el7.x86_64                                                                                              3/17
  Installing : python-lxml-3.2.1-4.el7.x86_64                                                                                                         4/17
  Installing : python-javapackages-3.4.1-11.el7.noarch                                                                                                5/17
  Installing : javapackages-tools-3.4.1-11.el7.noarch                                                                                                 6/17
  Installing : libjpeg-turbo-1.2.90-6.el7.x86_64                                                                                                      7/17
  Installing : pcsc-lite-libs-1.8.8-8.el7.x86_64                                                                                                      8/17
  Installing : tzdata-java-2018i-1.el7.noarch                                                                                                         9/17
  Installing : copy-jdk-configs-3.3-10.el7_5.noarch                                                                                                  10/17
  Installing : lksctp-tools-1.0.17-2.el7.x86_64                                                                                                      11/17
  Installing : avahi-libs-0.6.31-19.el7.x86_64                                                                                                       12/17
  Installing : 1:cups-libs-1.6.3-35.el7.x86_64                                                                                                       13/17
  Installing : 1:java-1.8.0-openjdk-headless-1.8.0.201.b09-2.el7_6.x86_64                                                                            14/17
  Installing : puppetserver-6.3.0-1.el7.noarch                                                                                                       15/17
usermod: no changes
  Installing : puppetdb-6.3.0-1.el7.noarch                                                                                                           16/17
Config archive not found. Not proceeding with migration
PEM files in /etc/puppetlabs/puppetdb/ssl are missing, we will move them into place for you
Warning: Unable to find all puppet certificates to copy

  This tool requires the following certificates to exist:

  * /etc/puppetlabs/puppet/ssl/certs/ca.pem
  * /etc/puppetlabs/puppet/ssl/private_keys/puppetserver.pem
  * /etc/puppetlabs/puppet/ssl/certs/puppetserver.pem

  These files may be missing due to the fact that your host's Puppet
  certificates may not have been signed yet, probably due to the
  lack of a complete Puppet agent run. Try running puppet first, for
  example:

      puppet agent --test

  Afterwards re-run this tool then restart PuppetDB to complete the SSL
  setup:

      puppetdb ssl-setup -f
  Installing : puppetdb-termini-6.3.0-1.el7.noarch                                                                                                   17/17
  Verifying  : 1:cups-libs-1.6.3-35.el7.x86_64                                                                                                        1/17
  Verifying  : avahi-libs-0.6.31-19.el7.x86_64                                                                                                        2/17
  Verifying  : net-tools-2.0-0.24.20131004git.el7.x86_64                                                                                              3/17
  Verifying  : puppetserver-6.3.0-1.el7.noarch                                                                                                        4/17
  Verifying  : lksctp-tools-1.0.17-2.el7.x86_64                                                                                                       5/17
  Verifying  : copy-jdk-configs-3.3-10.el7_5.noarch                                                                                                   6/17
  Verifying  : python-javapackages-3.4.1-11.el7.noarch                                                                                                7/17
  Verifying  : libxslt-1.1.28-5.el7.x86_64                                                                                                            8/17
  Verifying  : python-lxml-3.2.1-4.el7.x86_64                                                                                                         9/17
  Verifying  : tzdata-java-2018i-1.el7.noarch                                                                                                        10/17
  Verifying  : pcsc-lite-libs-1.8.8-8.el7.x86_64                                                                                                     11/17
  Verifying  : javapackages-tools-3.4.1-11.el7.noarch                                                                                                12/17
  Verifying  : puppet-agent-6.4.0-1.el7.x86_64                                                                                                       13/17
  Verifying  : 1:java-1.8.0-openjdk-headless-1.8.0.201.b09-2.el7_6.x86_64                                                                            14/17
  Verifying  : puppetdb-6.3.0-1.el7.noarch                                                                                                           15/17
  Verifying  : puppetdb-termini-6.3.0-1.el7.noarch                                                                                                   16/17
  Verifying  : libjpeg-turbo-1.2.90-6.el7.x86_64                                                                                                     17/17

Installed:
  puppetdb.noarch 0:6.3.0-1.el7                  puppetdb-termini.noarch 0:6.3.0-1.el7                  puppetserver.noarch 0:6.3.0-1.el7

Dependency Installed:
  avahi-libs.x86_64 0:0.6.31-19.el7                             copy-jdk-configs.noarch 0:3.3-10.el7_5      cups-libs.x86_64 1:1.6.3-35.el7
  java-1.8.0-openjdk-headless.x86_64 1:1.8.0.201.b09-2.el7_6    javapackages-tools.noarch 0:3.4.1-11.el7    libjpeg-turbo.x86_64 0:1.2.90-6.el7
  libxslt.x86_64 0:1.1.28-5.el7                                 lksctp-tools.x86_64 0:1.0.17-2.el7          net-tools.x86_64 0:2.0-0.24.20131004git.el7
  pcsc-lite-libs.x86_64 0:1.8.8-8.el7                           puppet-agent.x86_64 0:6.4.0-1.el7           python-javapackages.noarch 0:3.4.1-11.el7
  python-lxml.x86_64 0:3.2.1-4.el7                              tzdata-java.noarch 0:2018i-1.el7

Complete!
[root@puppetserver ~]#



[root@puppetclient ~]# yum install puppet-agent
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: centos.excellmedia.net
 * extras: centos.excellmedia.net
 * updates: centos.excellmedia.net
base                                                                                                                                | 3.6 kB  00:00:00
extras                                                                                                                              | 3.4 kB  00:00:00
puppet6                                                                                                                             | 2.5 kB  00:00:00
updates                                                                                                                             | 3.4 kB  00:00:00
Resolving Dependencies
--> Running transaction check
---> Package puppet-agent.x86_64 0:6.4.0-1.el7 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

===========================================================================================================================================================
 Package                                 Arch                              Version                                Repository                          Size
===========================================================================================================================================================
Installing:
 puppet-agent                            x86_64                            6.4.0-1.el7                            puppet6                             22 M

Transaction Summary
===========================================================================================================================================================
Install  1 Package

Total download size: 22 M
Installed size: 93 M
Is this ok [y/d/N]: y
Downloading packages:
warning: /var/cache/yum/x86_64/7/puppet6/packages/puppet-agent-6.4.0-1.el7.x86_64.rpm: Header V4 RSA/SHA256 Signature, key ID ef8d349f: NOKEY 00:00:00 ETA
Public key for puppet-agent-6.4.0-1.el7.x86_64.rpm is not installed
puppet-agent-6.4.0-1.el7.x86_64.rpm                                                                                                 |  22 MB  00:00:20
Retrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-puppet6-release
Importing GPG key 0xEF8D349F:
 Userid     : "Puppet, Inc. Release Key (Puppet, Inc. Release Key) "
 Fingerprint: 6f6b 1550 9cf8 e59e 6e46 9f32 7f43 8280 ef8d 349f
 Package    : puppet6-release-6.0.0-1.el7.noarch (installed)
 From       : /etc/pki/rpm-gpg/RPM-GPG-KEY-puppet6-release
Is this ok [y/N]: y
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Warning: RPMDB altered outside of yum.
  Installing : puppet-agent-6.4.0-1.el7.x86_64                                                                                                         1/1
  Verifying  : puppet-agent-6.4.0-1.el7.x86_64                                                                                                         1/1

Installed:
  puppet-agent.x86_64 0:6.4.0-1.el7

Complete!
[root@puppetclient ~]#


Now, Puppet Server has been installed successfully with all the requisite packages. Start the Puppet Server service. Please verify and make sure that enough ram is allocated to the OS and JVM. Centos 7.0 comes with systemd as default i.e. system and service manager for Linux.

[root@puppetserver ~]# systemctl status puppetserver
● puppetserver.service - puppetserver Service
   Loaded: loaded (/usr/lib/systemd/system/puppetserver.service; disabled; vendor preset: disabled)
   Active: active (running) since Fri 2019-03-29 18:05:24 IST; 8min ago
  Process: 6037 ExecStart=/opt/puppetlabs/server/apps/puppetserver/bin/puppetserver start (code=exited, status=0/SUCCESS)
 Main PID: 6113 (java)
    Tasks: 48 (limit: 4915)
   CGroup: /system.slice/puppetserver.service
           └─6113 /usr/bin/java -Xms1g -Xmx1g -Djruby.logger.class=com.puppetlabs.jruby_utils.jruby.Slf4jLogger -Djava.security.egd=/dev/urandom -XX:OnO...

Mar 29 18:02:50 puppetserver systemd[1]: Starting puppetserver Service...
Mar 29 18:05:24 puppetserver systemd[1]: Started puppetserver Service.
[root@puppetserver ~]#

Puppetserver Status

Memory Allocation

Puppet Server will be configured to use 2GB of RAM by default. However, while using puppet server in production you should have a good amount of ram assigned to it for optimal performance. The syntax to change the Puppet Server memory allocation is shown below:

Open /etc/sysconfig/puppetserver and modify these settings

[root@puppetserver ~]# cat /etc/sysconfig/puppetserver 
###########################################
# Init settings for puppetserver
###########################################

# Location of your Java binary (version 7 or higher)
JAVA_BIN="/usr/bin/java"

# Modify this if you'd like to change the memory allocation, enable JMX, etc
JAVA_ARGS="-Xms1g -Xmx1g -Djruby.logger.class=com.puppetlabs.jruby_utils.jruby.Slf4jLogger"

# Modify this if you'd like TrapperKeeper specific arguments
TK_ARGS=""

# These normally shouldn't need to be edited if using OS packages
USER="puppet"
GROUP="puppet"
INSTALL_DIR="/opt/puppetlabs/server/apps/puppetserver"
CONFIG="/etc/puppetlabs/puppetserver/conf.d"

# Bootstrap path
BOOTSTRAP_CONFIG="/etc/puppetlabs/puppetserver/services.d/,/opt/puppetlabs/server/apps/puppetserver/config/services.d/"

# SERVICE_STOP_RETRIES can be set here to alter the default stop timeout in
# seconds.  For systemd, the shorter of this setting or 'TimeoutStopSec' in
# the systemd.service definition will effectively be the timeout which is used.
SERVICE_STOP_RETRIES=60

# START_TIMEOUT can be set here to alter the default startup timeout in
# seconds.  For systemd, the shorter of this setting or 'TimeoutStartSec'
# in the service's systemd.service configuration file will effectively be the
# timeout which is used.
START_TIMEOUT=300

# Maximum number of seconds that can expire for a service reload attempt before
# the result of the attempt is interpreted as a failure.
RELOAD_TIMEOUT=120
[root@puppetserver ~]# 

Puppet config file

[root@puppetserver ~]# cat /etc/puppetlabs/puppet/puppet.conf
# This file can be used to override the default puppet settings.
# See the following links for more details on what settings are available:
# - https://puppet.com/docs/puppet/latest/config_important_settings.html
# - https://puppet.com/docs/puppet/latest/config_about_settings.html
# - https://puppet.com/docs/puppet/latest/config_file_main.html
# - https://puppet.com/docs/puppet/latest/configuration.html
[master]
dns_alt_names = puppetserver, puppet
vardir = /opt/puppetlabs/server/data/puppetserver
logdir = /var/log/puppetlabs/puppetserver
rundir = /var/run/puppetlabs/puppetserver
pidfile = /var/run/puppetlabs/puppetserver/puppetserver.pid
codedir = /etc/puppetlabs/code

[main]
certname = puppetserver
server = puppetserver

[root@puppetserver ~]# puppet agent -t
Info: Using configured environment 'production'
Info: Retrieving pluginfacts
Info: Retrieving plugin
Info: Retrieving locales
Info: Caching catalog for puppetserver
Info: Applying configuration version '1553867654'
Notice: Applied catalog in 0.13 seconds
[root@puppetserver ~]#

Performance

Puppet Server is fast. It has 3x performance improvement over puppet master. It means that an individaul Puppet Server can handle a much larger volume of puppet agent nodes. The performance gain will increase as it becomes more and more mature. Now we have to deal with simplified configuration in Puppet Server, rather than managing several discrete packages (Apache, Passenger, Puppet, etc.) with their separate configuration interfaces (Puppet Master).

Conclusion

Puppet Server is very straight forward to install and setup. Along with ease, it provides a huge performance improvement over the classic puppet master setup. Now, a single command does all the things (yum install puppetserver) for you.

After some hands on with the new Puppet Server, you will really feel the difference. You will enjoy.

One Comment

  1. Krishna Prajapati

    [root@puppet ~]# cat /etc/puppetlabs/puppet/puppet.conf
    # This file can be used to override the default puppet settings.
    # See the following links for more details on what settings are available:
    # – https://puppet.com/docs/puppet/latest/config_important_settings.html
    # – https://puppet.com/docs/puppet/latest/config_about_settings.html
    # – https://puppet.com/docs/puppet/latest/config_file_main.html
    # – https://puppet.com/docs/puppet/latest/configuration.html
    [master]
    vardir = /opt/puppetlabs/server/data/puppetserver
    logdir = /var/log/puppetlabs/puppetserver
    rundir = /var/run/puppetlabs/puppetserver
    pidfile = /var/run/puppetlabs/puppetserver/puppetserver.pid
    codedir = /etc/puppetlabs/code
    hiera_config = $confdir/hiera.yaml
    dns_alt_names = puppet,puppet.exabig.com
    environment_timeout = unlimited
    storeconfigs = true
    storeconfigs_backend = puppetdb
    [main]
    certname = puppet.exabig.com
    server = puppet.exabig.com
    environment = production
    runinterval = 1h
    [root@puppet ~]#
    [root@db01 ~]# cat /etc/puppetlabs/puppet/puppet.conf
    # This file can be used to override the default puppet settings.
    # See the following links for more details on what settings are available:
    # – https://puppet.com/docs/puppet/latest/config_important_settings.html
    # – https://puppet.com/docs/puppet/latest/config_about_settings.html
    # – https://puppet.com/docs/puppet/latest/config_file_main.html
    # – https://puppet.com/docs/puppet/latest/configuration.html
    [main]
    certname = db01.exabig.com
    server = puppet.exabig.com
    environment = production
    runinterval = 1h
    [root@db01 ~]#

Leave a Reply

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