Git Product home page Git Product logo

sensu-plugins-puppet's Introduction

Sensu-Plugins-puppet

Sensu Bonsai Asset Build Status Gem Version Code Climate Test Coverage Dependency Status

Functionality

check-puppet-last-run.rb

Validates Puppet last run. Alerts if last Puppet run was later than threshold or it has errors

Usage: ./bin/check-puppet-last-run.rb (options)
    -a, --agent-disabled-file PATH   Path to agent disabled lock file
    -c, --crit-age SECONDS           Age in seconds to be a critical
    -C, --crit-age-disabled SECONDS  Age in seconds to crit when agent is disabled
    -d, --disabled-age-limits        Consider disabled age limits, otherwise use main limits
    -i, --ignore-failures            Ignore Puppet failures
    -r, --report-restart-failures    Raise alerts if restart failures have happened
    -s, --summary-file PATH          Location of last_run_summary.yaml file
    -w, --warn-age SECONDS           Age in seconds to be a warning
    -W, --warn-age-disabled SECONDS  Age in seconds to warn when agent is disabled

check-puppet-last-run-report.rb

Validates Puppet last run report. Alerts if last Puppet run was later than threshold or it has errors

Usage: ./bin/check-puppet-last-run-report.rb (options)
    -a, --agent-disabled-file PATH   Path to agent disabled lock file
    -c, --crit-age SECONDS           Age in seconds to be a critical
    -C, --crit-age-disabled SECONDS  Age in seconds to crit when agent is disabled
    -d, --disabled-age-limits        Consider disabled age limits, otherwise use main limits
    -i, --ignore-failures            Ignore Puppet failures
    -r, --report-restart-failures    Raise alerts if restart failures have happened
    -f, --report-file PATH           Location of last_run_report.yaml file
    -w, --warn-age SECONDS           Age in seconds to be a warning
    -W, --warn-age-disabled SECONDS  Age in seconds to warn when agent is disabled

check-puppet-errors.rb

Validates only Puppet run errors regardless of the execution time

Usage: ./bin/check-puppet-errors.rb (options)
    -a, --agent-disabled-file PATH   Path to agent disabled lock file
    -s, --summary-file PATH          Location of last_run_summary.yaml file

metrics-puppet-run.rb

Provides metrics from Puppet last run in graphite format.

Usage: ./bin/metrics-puppet-run.rb (options)
    -s, --scheme SCHEME              Metric naming scheme
    -p, --summary-file PATH          Location of last_run_summary.yaml file

Files

  • /bin/checkpuppet-last-run.rb
  • /bin/metrics-puppet-run.rb
  • /bin/check-puppet-errors.rb

Installation Options

Asset registration

Assets are the best way to make use of this plugin in Sensu Go. If you're not using an asset, please consider doing so! If you're using sensuctl 5.13 or later, you can use the following command to add the latest version of this asset:

sensuctl asset add sensu-plugins/sensu-plugins-puppet

If you're using an earlier version of sensuctl, you can download the asset definition from this project's Bonsai Asset Index page.

Gem Installation

Installation and Setup

Notes

As the sensu user doesn't have read access to /opt/puppetlabs/puppet/cache/state/last_run_summary.yaml it is necessary to create an appropriate entry in /etc/sudoers.d and call check-puppet-last-run.rb or metrics-puppet-run.rb using sudo.

sensu-plugins-puppet's People

Contributors

analytically avatar antonidabek avatar bleuchtang avatar bodgit avatar bovy89 avatar bradmcnay avatar cwjohnston avatar dalesit avatar dependabot-preview[bot] avatar dependabot-support avatar eheydrick avatar esa-a avatar grem11n avatar jaredledvina avatar jlambert121 avatar jspaleta avatar kindred avatar majormoses avatar mjulian avatar roobert avatar sstarcher avatar thomasriley avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

sensu-plugins-puppet's Issues

check-puppet-last-run crash with -i option

Check-puppet-last-run.rb with -i option is not working

Check failed to run: undefined method >' for nil:NilClass, ["/opt/sensu/embedded/lib/ruby/gems/2.3.0/gems/sensu-plugins-puppet-2.1.0/bin/check-puppet-last-run.rb:138:in run'", "/opt/sensu/embedded/lib/ruby/gems/2.3.0/gems/sensu-plugin-1.2.0/lib/sensu-plugin/cli.rb:56:in `block in class:CLI'"]

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.