Forge Home

amanda

Amanda Module for Puppet

13,081 downloads

1,249 latest version

4.5 quality score

We run a couple of automated
scans to help you access a
module's quality. Each module is
given a score based on how well
the author has formatted their
code and documentation and
modules are also checked for
malware using VirusTotal.

Please note, the information below
is for guidance only and neither of
these methods should be considered
an endorsement by Puppet.

Version information

  • 4.0.0 (latest)
  • 3.2.1
  • 3.2.0
  • 3.1.0
  • 3.0.1
  • 3.0.0
  • 2.1.0
  • 2.0.0
released Nov 15th 2020
This version is compatible with:
  • Puppet Enterprise 2019.8.x, 2019.7.x, 2019.5.x, 2019.4.x, 2019.3.x, 2019.2.x, 2019.1.x, 2019.0.x, 2018.1.x
  • Puppet >= 5.5.8 < 7.0.0

Start using this module

  • r10k or Code Manager
  • Bolt
  • Manual installation
  • Direct download

Add this module to your Puppetfile:

mod 'puppet-amanda', '4.0.0'
Learn more about managing modules with a Puppetfile

Add this module to your Bolt project:

bolt module add puppet-amanda
Learn more about using this module with an existing project

Manually install this module globally with Puppet module tool:

puppet module install puppet-amanda --version 4.0.0

Direct download is not typically how you would use a Puppet module to manage your infrastructure, but you may want to download the module in order to inspect the code.

Download
Tags: backup, amanda

Documentation

puppet/amanda — version 4.0.0 Nov 15th 2020

Amanda module for Puppet

Build Status Code Coverage Puppet Forge Puppet Forge - downloads Puppet Forge - endorsement Puppet Forge - scores

Description

Provides Amanda Network Backup server and client configuration through Puppet

Usage

The amanda module allows specifying parameterized classes that will do most of the heavy lifting in a single definition (relying on sane defaults), or for more custom configuration the utility defines can be used directly. What follows is a minimal-effort configuration that trusts the module to figure out the details.

node 'backup.cat.pdx.edu' {
  class { 'amanda::server':
    configs        => [ 'daily', 'archive' ],
    configs_source => 'modules/data/amanda',
  }
}

node 'client.cat.pdx.edu' {
  class { 'amanda::client':
    server => 'backup.cat.pdx.edu',
  }
}

Of note is the configs_source parameter. While the amanda module will install and configure server and client machines, it does not yet attempt to build amanda configs using puppet code. Rather, that legwork is still left up to the administrator, and the module will only ensure that the files which comprise the config are present on the server.

If you need to create configs from templates or other sources, then by setting manage_configs_source to false will disable extraction via the mechanism below, you are then free to assign puppet file resources as appropriate to create your configs.

Additional parameters are available for both the amanda::server and amanda::client classes which are not documented here. At present the only way to look up how to use them is to read the source.

How Configs Work

Use the following Puppet DSL code to ensure the "daily" and "archive" configs are created on an amanda backup server.

node 'backup.cat.pdx.edu' {
  file { '/etc/amanda':
    ensure => directory;
  }

  amanda::config { 'daily':
    ensure            => present,
    configs_source    => 'modules/data/amanda',
    configs_directory => '/etc/amanda',
  }
  amanda::config { 'archive':
    ensure            => present,
    configs_source    => 'modules/data/amanda',
    configs_directory => '/etc/amanda',
  }
}

Then place your config files in the "files" directory of the module specified with the configs_source parameter. For the code above, files that make up the "archive" and "daily" amanda configs should be placed in the data module as per this example:

data
|-- files
|   `-- amanda
|       |-- daily
|       |   |-- amanda.conf
|       |   |-- chg-multi.conf
|       |   |-- disklist
|       |   `-- label-templates
|       |       |-- 3hole.ps
|       |       |-- 8.5x11.ps
|       |       |-- DIN-A4.ps
|       |       |-- DLT-A4.ps
|       |       |-- DLT.ps
|       |       |-- EXB-8500.ps
|       |       |-- HP-DAT.ps
|       |       `-- tapetypes.conf
|       `-- archive
|           |-- amanda.conf
|           |-- chg-scsi.conf
|           |-- disklist
|           `-- dumptypes.conf
|-- LICENSE
`-- README

The contents of the config directory ("daily" or "archive") will be synced as file resources to the location specified with the configs_directory specified in the amanda::config resource. For the example above, the files will be synced to the agent system as:

/
|-- etc
|   |-- amanda
|   |   |-- daily
.   |   |   |-- amanda.conf
.   .   |   |-- chg-multi.conf
.   .   |   |-- disklist
    .   |   `-- label-templates
        |       |-- 3hole.ps
        |       |-- 8.5x11.ps
        |       |-- DIN-A4.ps
        |       |-- DLT-A4.ps
        |       |-- DLT.ps
        |       |-- EXB-8500.ps
        |       |-- HP-DAT.ps
        |       `-- tapetypes.conf
        `-- archive
            |-- amanda.conf
            |-- chg-scsi.conf
            |-- disklist
            `-- dumptypes.conf

Additional Types

Besides the primary classes amanda::server and amanda::client, three utility defines are included in the module.

Amanda::Amandahosts

The amanda::amandahosts type manages the .amandahosts file, which controls access to amanda services. The important parameter to this resource is content, and the user must specify the full access line to include. For example,

amanda::amandahosts { 'replicator-amdump':
  content => "replicator.cat.pdx.edu backup amdump",
}

Amanda::Config

The amanda::config type synchronizes a directory of files in a given module to a client. A more detailed example is given in the preceding section.

amanda::config { 'daily':
  ensure            => present,
  configs_source    => 'modules/data/amanda',
  configs_directory => '/etc/amanda',
}

Amanda::Ssh_authorized_key

The amanda::ssh_authorized_key type is a convenience define used to install ssh authentication on an amanda client. The important parameter for this type is key.

amanda::ssh_authorized_key { 'replicator':
  key => hiera('pubkey/backup@replicator'),
}

Amanda::Disklist::Dle

The amanda::disklist::dle type is used to add/remove disk list entries from the Amanda disklist(5) file, which is used by Amanda to determine which disks will be backed up.

Requirements:

  • Puppet storeconfigs must be enabled
  • amanda::config must be used to synchronize configuration files with the manage_dle parameter set to true, i.e. manage_dle => true. This must be set for each amanda::config if more than one has been configured.
amanda::disklist::dle { '/etc':
   configs  => 'daily',
   dumptype => 'dumptype',
}

amanda::disklist::dle { '/var':
   configs  => [ 'daily', 'weekly' ],
   dumptype => 'dumptype',
}

Known Issues

  • The module does not include tests

  • The module does not allow overriding of the client/server package name(s)

Contributors