Adoptable Cookbooks List

Looking for a cookbook to adopt? You can now see a list of cookbooks available for adoption!
List of Adoptable Cookbooks

Supermarket Belongs to the Community

Supermarket belongs to the community. While Chef has the responsibility to keep it running and be stewards of its functionality, what it does and how it works is driven by the community. The chef/supermarket repository will continue to be where development of the Supermarket application takes place. Come be part of shaping the direction of Supermarket by opening issues and pull requests or by joining us on the Chef Mailing List.

Select Badges

Select Supported Platforms

RSS

chef_install_configure_collectd (21) Versions 0.1.0

Use this cookbook to install the SignalFx collectd agent and collectd plugins.

Berkshelf/Librarian
Policyfile
Knife
cookbook 'chef_install_configure_collectd', '= 0.1.0'
cookbook 'chef_install_configure_collectd', '= 0.1.0', :supermarket
knife cookbook site install chef_install_configure_collectd
knife cookbook site download chef_install_configure_collectd
README
Dependencies
Quality

chef_install_configure_collectd

DESCRIPTION

  • Install the collectd of SignalFx monitoring daemon.
  • Configure the basic plugins of collected.
  • Configure the write_http plugin of collectd which can send metrics to SignalFx Inc.

REQUIREMENTS

This cookbook has been tested on Centos 5, 6, 7; Amazon Linux 1409, 1503; Ubuntu 1504, 1410, 1404

Attributes

  • attributes/default.rb - Basic attributes for collectd write_http plugin.
  • attributes/SignalFx_rpm_repo.rb - SignalFx rpms names and links for centos and amazon linux.

Templates

  • templates/default/collectd.conf.erb - Template to configure the collectd.conf file.
  • templates/default/10-write_http-plugin.conf.erb - Template to configure the write_http plugin of collectd.
  • templates/default/10-aggregation-cpu.conf.erb - Template to configure the CPU aggregation.

USAGE

Three main recipes are provided:

  • chef_install_configure_collectd - Install the SignalFx.rpm and newest release collectd of SignalFx Inc.
  • chef_install_configure_collectd::config-collectd - Set up collectd.conf file.
  • chef_install_configure_collectd::config-write_http - Configure the write_http plugin for collectd.

Install collectd of SignalFx Inc.

  • Run chef_install_configure_collectd::default recipe which can check the operation system and install collectd packages.

Configure the collectd

  • Run the chef_install_configure_collectd::config-collectd recipe which can set up collectd.conf file.

Configure to send the metrics to SignalFx

  • Run the chef_install_configure_collectd::config-write_http recipe.
  • Users can use the default attributes in attributes/default.rb. The collectd will use the default Ingest_host URL to send metrics to SignalFx Inc, but users have to fill your API TOKEN.
  • If users want use your own ingest host URL or ingest host parameters, you should rewrite attributes/default.rb defines their attributes. Example:
   default["write_http"]["set_aws_instanceId"] = true
   default["write_http"]["Ingest_host"] = "YOUR_INGEST_HOST"
   default["write_http"]["API_TOKEN"] = "YOUR_API_TOKEN"
   default["write_http"]["Ingest_host_parameters"]["YOUR_KEY1"] = "YOUR_VALUE1"
   default["write_http"]["Ingest_host_parameters"]["YOUR_KEY2"] = "YOUR_VALUE2"
  • The attribute default["write_http"]["set_aws_instanceId"] means if user want to integerate by AWS.
  • All of the other attributes are to configure the 10-write_http-plugin.conf file. If you use the attributes above, the configuration file (10-write_http-plugin.conf) is like:
LoadPlugin write_http
<Plugin "write_http">
  <URL "YOUR_INGEST_HOST&sfxdim_InstanceId=YOUR_AWS_INSTANCE_ID&sfxdim_YOUR_KEY1=YOUR_VALUE1&sfxdim_YOUR_KEY2=YOUR_VALUE2">
    User "auth"
    Password "YOUR_API_TOKEN"
    Format "JSON"
  </URL>
</Plugin>

LICENSE & AUTHOR

Author:: Wentao Du (wentao@signalfx.com)

Copyright::2015, SignalFx, Inc.

Dependent cookbooks

This cookbook has no specified dependencies.

Contingent cookbooks

There are no cookbooks that are contingent upon this one.

Foodcritic Metric
            

0.1.0 failed this metric

FC001: Use strings in preference to symbols to access node attributes: /tmp/cook/521cbd782cc61c85289be127/chef_install_configure_collectd/recipes/config-collectd.rb:1
FC001: Use strings in preference to symbols to access node attributes: /tmp/cook/521cbd782cc61c85289be127/chef_install_configure_collectd/recipes/config-collectd.rb:9
FC001: Use strings in preference to symbols to access node attributes: /tmp/cook/521cbd782cc61c85289be127/chef_install_configure_collectd/recipes/default.rb:52
FC002: Avoid string interpolation where not required: /tmp/cook/521cbd782cc61c85289be127/chef_install_configure_collectd/recipes/default.rb:17
FC013: Use file_cache_path rather than hard-coding tmp paths: /tmp/cook/521cbd782cc61c85289be127/chef_install_configure_collectd/recipes/default.rb:13
FC019: Access node attributes in a consistent manner: /tmp/cook/521cbd782cc61c85289be127/chef_install_configure_collectd/recipes/config-collectd.rb:1
FC019: Access node attributes in a consistent manner: /tmp/cook/521cbd782cc61c85289be127/chef_install_configure_collectd/recipes/config-collectd.rb:9
FC019: Access node attributes in a consistent manner: /tmp/cook/521cbd782cc61c85289be127/chef_install_configure_collectd/recipes/default.rb:52