Install Rudder Agent

This chapter gives a general presentation of the Rudder Agent, and describes the different configuration steps to deploy the Rudder agent on the Nodes you wish to manage. Each Operating System has its own set of installation procedures.

The machines managed by Rudder are called Nodes, and can either be physical or virtual. For a machine to become a managed Node, you have to install the Rudder Agent on it. The Node will afterwards register itself on the server. And finally, the Node should be acknowledged in the Rudder Server interface to become a managed Node. For a more detailed description of the workflow, please refer to the Node Management documentation.

[Note]Components

This agent contains the following tools:

  1. The community version of CFEngine, a powerful open source configuration management tool.
  2. FusionInventory, an inventory software.
  3. An initial configuration set for the agent, to bootstrap the Rudder Root Server access.

These components are recognized for their reliability and minimal impact on performances. Our tests showed their memory consumption is usually under 10 MB of RAM during their execution. So you can safely install them on your servers.

We grouped all these tools in one package, to ease the Rudder Agent installation.

To get the list of supported Operating systems, please refer to the list of supported Operating Systems for the Nodes.

Install Rudder Agent on Debian or Ubuntu

The Rudder agent requires that a syslog server is installed on the node. This syslog server can be either:

  • syslogd
  • syslog-ng
  • rsyslog

One of them is generally installed by default, but it may not be the case with minimal images. In this case you should install one of them (preferably syslog-ng or rsyslog).

Each package that is published by Rudder Project is signed with our GPG signature. To ensure the packages you will install are official builds and have not been altered, import our key into apt using the following command:

wget --quiet -O- "https://www.rudder-project.org/apt-repos/rudder_apt_key.pub" | sudo apt-key add -

Our key fingerprint is:

pub  4096R/474A19E8 2011-12-15 Rudder Project (release key) <security@rudder-project.org>
      Key fingerprint = 7C16 9817 7904 212D D58C  B4D1 9322 C330 474A 19E8

Then add Rudder's package repository:

echo "deb http://www.rudder-project.org/apt-4.3/ $(lsb_release -cs) main" > /etc/apt/sources.list.d/rudder.list

Update your local package database to retrieve the list of packages available on our repository:

sudo apt-get update

Install the rudder-agent package:

sudo apt-get install rudder-agent

You can now configure the agent.

Install Rudder Agent on RHEL-like systems

The Rudder agent requires that a syslog server is installed on the node. This syslog server can be either:

  • syslogd
  • syslog-ng
  • rsyslog

One of them is generally installed by default, but it may not be the case with minimal images. In this case you should install one of them (preferably syslog-ng or rsyslog).

Each package that is published by Rudder Project is signed with our GPG signature. To ensure the packages you will install are official builds and have not been altered, import our key into rpm using the following command:

rpm --import https://www.rudder-project.org/rpm-repos/rudder_rpm_key.pub

Our key fingerprint is:

pub  1024R/6F07D355 2012-11-09 Rudder Project (RPM release key) <security@rudder-project.org>
      Key fingerprint = 1141 A947 CDA0 4E83 82C1  B9C4 ADAB 3BD3 6F07 D355

Then define a yum repository for Rudder.

For RHEL/CentOS

echo '[Rudder_4.3]
name=Rudder 4.3 EL repository
baseurl=http://www.rudder-project.org/rpm-4.3/RHEL_$releasever/
gpgcheck=1
gpgkey=https://www.rudder-project.org/rpm-repos/rudder_rpm_key.pub' > /etc/yum.repos.d/rudder.repo

For Amazon Linux

echo '[Rudder_4.1]
name=Rudder 4.1 AL repository
baseurl=http://www.rudder-project.org/rpm-4.1/RHEL_6/
gpgcheck=1
gpgkey=https://www.rudder-project.org/rpm-repos/rudder_rpm_key.pub' > /etc/yum.repos.d/rudder.repo

For Amazon Linux 2

echo '[Rudder_4.1]
name=Rudder 4.1 AL repository
baseurl=http://www.rudder-project.org/rpm-4.1/RHEL_7/
gpgcheck=1
gpgkey=https://www.rudder-project.org/rpm-repos/rudder_rpm_key.pub' > /etc/yum.repos.d/rudder.repo
[Tip]Tip

The RPM can be directly downloaded for a standalone installation, from the following URL: http://www.rudder-project.org/rpm-4.1/RHEL_7/ (or RHEL_6, RHEL_5, etc, depending on your host’s OS version)

Install the package:

yum install rudder-agent

Or:

yum install rudder-agent-4.2.0-1.EL.7.x86_64.rpm

You can now configure the agent.

Install Rudder Agent on SLES

The Rudder agent requires that a syslog server is installed on the node. This syslog server can be either:

  • syslogd
  • syslog-ng
  • rsyslog

One of them is generally installed by default, but it may not be the case with minimal images. In this case you should install one of them (preferably syslog-ng or rsyslog).

Following commands are executed as the root user.

[Warning]Warning

You may encounter a segmentation fault in Zypper in the following cases:

  • On SLES 11 when trying to install Rudder rpm files locally with Zypper (for example with zypper install rudder-agent-version.release-1.SLES.11.x86_64.rpm)
  • On SLES 12 GA when installing Rudder packages, locally or from the repository

This is due to a bug (bnc#929483 on SuSE bugtracker) in Zypper’s RPM headers parsing. You can either:

  • Only for SLES 11, install the packages directly from the repository, as described below
  • Upgrade your libzypp package to a version including the fix provided by SuSE (upgrade for SLES11SP3 and for SLES12)
  • Use the rpm command to install packages locally (for example with rpm -i rudder-agent-version.release-1.SLES.11.x86_64.rpm)

Each package that is published by Rudder Project is signed with our GPG signature. To ensure the packages you will install are official builds and have not been altered, import our key into rpm using the following command:

rpm --import https://www.rudder-project.org/rpm-repos/rudder_rpm_key.pub

Our key fingerprint is:

pub  1024R/6F07D355 2012-11-09 Rudder Project (RPM release key) <security@rudder-project.org>
      Key fingerprint = 1141 A947 CDA0 4E83 82C1  B9C4 ADAB 3BD3 6F07 D355

Then add the Rudder packages repository:

  • on SLES 12:
zypper ar -n 'Rudder SLES 12 repository' http://www.rudder-project.org/rpm-4.3/SLES_12/ Rudder
  • on SLES 11:
zypper ar -n 'Rudder SLES repository' http://www.rudder-project.org/rpm-4.3/SLES_11_SP1/ Rudder
  • on SLES 10:
zypper sa 'http://www.rudder-project.org/rpm-4.3/SLES_10_SP3/' Rudder

Update your local package database to retrieve the list of packages available on our repository:

zypper ref

Install the rudder-agent package:

zypper install rudder-agent
[Tip]Tip

The use the the rug package manager on SLES 10 is strongly discouraged, due to poor performance and possible stability issues.

You can now configure the agent.

Configure and validate

Configure Rudder Agent

Configure the IP address or hostname of the Rudder Root Server in the following file

echo '<rudder server ip or hostname>' > /var/rudder/cfengine-community/policy_server.dat
[Tip]Tip

We advise you to use the IP address of the Rudder Root Server. The DNS name of this server can also be accepted if you have a trusted DNS infrastructure with proper reverse resolutions.

You can now start the Rudder service with:

service rudder-agent start

Validate new Node

Several minutes after the start of the agent, a new Node should be pending in the Rudder web interface. You will be able to browse its inventory, and accept it to manage its configuration with Rudder.

You may force the agent to run and send an inventory by issuing the following command:

rudder agent inventory

You may force the agent execution by issuing the following command:

rudder agent run