Tuesday 28 May 2013

Installing Puppet Master

This is the first part in a series of yet unknown posts about my experience in attempting to learning Puppet and Razor.  So, exactly what is Puppet and Razor?  The following are paragraphs taken directly from the products homepage:

Puppet Enterprise is IT automation software that gives system administrators the power to easily automate repetitive tasks, quickly deploy critical applications, and proactively manage infrastructure, on-premise or in the cloud.

Project Razor is a power control, provisioning, and management application designed to deploy both bare-metal and virtual computer resources. Razor provides broker plugins for integration with third party such as Puppet.

Before I start I would like to point out that there is a great Quick Start guide provided by Puppet Labs which basically takes you through the entire process.  In my lab I have two newly built Centos 6.2 VM's called puppetmaster.domain.local and puppetagent.domain.local.  Both VM's have static IP addresses and forward / reverse addresses in DNS.  The usual checks have been performed to ensure both hosts can see each other and the internet.  I've also downloaded the latest version of Puppet Enterprise for Centos 6.2 which includes 10 complimentary agent nodes and sftp'd this up to the /tmp directory on both VM's.

We will start by installing the puppet server software and the first step is to extract the puppet installation files (File versions may vary).  CD into the /tmp directory and run the following command:

tar -zxvf /puppet-enterprise-2.8.1-el-6-x86_64.tar.gz

CD into /puppet-enterprise-2.8.1-el-6-x86_64 directory and run:


When asked if you wish to install puppet master enter Y.  If you were only planning on installing the agent software then obviously you would select N:image

When asked about installing the cloud provisioner select Y:

Select Y to install the console:image

Verify the puppet master certificate name and press enter when happy:image

Verify the puppet master certificate DNS aliases and press enter when happy:image

Provide an admin email address for accessing the console:image

Provide an admin password for accessing the console:image

Enter an SMTP server for email notifications:image

Select Y to install the MySQL database server:image

Select Y to install the Puppet Labs public key:image

Select Y to confirm the installation of all the required packages:image

Select Y to create the symbolic links:image

Select Y to perform the installation:image

The installation of the puppet master software took approximately 8 minutes to complete.  Once completed you will be advised of the web interface URL and any firewall ports that are required to be opened:image

You won’t be able to browse to the Web Interface URL just yet as we need to open the required ports.  To do this I simply added the following text into the /etc/sysconfig/iptables file and restart the iptables service with service iptables restart:

-A INPUT -m state --state NEW -m tcp -p tcp --dport 443 -j ACCEPT
-A INPUT -m state --state NEW -m tcp -p tcp --dport 8140 -j ACCEPT
-A INPUT -m state --state NEW -m tcp -p tcp --dport 61613 -j ACCEPT


Browsing to https://puppetmaster.domain.local should display a log in box to the web interface GUI which you should be able to log in with the using the credentials that were configuring during the installation:


Congratulations, the puppet master server is now up and running.  Up next we will install the puppet agent software on both a linux and windows VM.

No comments:

Post a Comment