hectcastro / chef-collectd

A Chef cookbook to install collectd.
Apache License 2.0
23 stars 65 forks source link

collectd-ng Build Status

Description

Installs and configures collectd. Much of the work in this cookbook reflects work done by coderanger and realityforge.

Requirements

Platforms

Cookbooks

Attributes

Recipes

Note: You need to include the default recipe[collectd-ng] when using recipe[collectd-ng:attribute_driven] to install collectd.

Usage

By default this cookbook will attempt to download collectd from collectd.org. If your HTTP request includes Chef as the user agent, collectd.org returns an HTTP response with a message asking you to please stop using their downloads via Chef. It is highly recommended that you override node["collectd"]["url"] with your own download location for collectd.

A list of alternative download locations for collectd:

In order to configure collectd via attributes, setup your roles like:

default_attributes(
  "collectd" => {
    "plugins" => {
      "syslog" => {
        "config" => { "LogLevel" => "Info" }
      },
      "disk"      => { },
      "swap"      => { },
      "memory"    => { },
      "cpu"       => { },
      "interface" => {
        "config" => { "Interface" => "lo", "IgnoreSelected" => true }
      },
      "df"        => {
        "config" => {
          "ReportReserved" => false,
          "FSType" => [ "proc", "sysfs", "fusectl", "debugfs", "devtmpfs", "devpts", "tmpfs" ],
          "IgnoreSelected" => true
        }
      },
      "write_graphite" => {
        "config" => {
          "Prefix" => "servers."
        }
      }
    }
  }
)