Giter Club home page Giter Club logo

gnocchi-nagios's Introduction

Gnocchi-nagios

Latest Version

Downloads

image

Gnocchi-nagios allows to push Nagios perfdata to Gnocchi

Installation

At the command line:

$ pip install gnocchi-nagios

Or, if you have virtualenvwrapper installed:

$ mkvirtualenv gnocchi-nagios
$ pip install gnocchi-nagios

Nagios/Icinga configuration

This is example of perfdata configuration for Gnocchi-nagios

Preparing working directories:

$ mkdir -p /var/spool/gnocchi-nagios/{nagios, ready}

In /etc/nagios3/nagios.conf:

host_perfdata_file_mode=a
host_perfdata_file_processing_interval=5
host_perfdata_file_template=DATATYPE::HOSTPERFDATA\tTIMET::$TIMET$\tHOSTNAME::$HOSTNAME$\tHOSTPERFDATA::$HOSTPERFDATA$\t$\tHOSTSTATE::$HOSTSTATE$\tHOSTSTATETYPE::$HOSTSTATETYPE$

service_perfdata_file_mode=a
service_perfdata_file_processing_interval=5
service_perfdata_file_template=DATATYPE::SERVICEPERFDATA\tTIMET::$TIMET$\tHOSTNAME::$HOSTNAME$\tSERVICEDESC::$SERVICEDESC$\tSERVICEPERFDATA::$SERVICEPERFDATA\tHOSTSTATE::$HOSTSTATE$\tHOSTSTATETYPE::$HOSTSTATETYPE$\tSERVICESTATE::$SERVICESTATE$\tSERVICESTATETYPE::$SERVICESTATETYPE$

host_perfdata_file=/var/spool/gnocchi-nagios/nagios/host-perfdata
host_perfdata_file_processing_command=gnocchi-nagios-host

service_perfdata_file=/var/spool/gnocchi-nagios/nagios/service-perfdata
service_perfdata_file_processing_command=gnocchi-nagios-service

In /etc/nagios3/conf.d/gnocchi-nagios.cfg:

define command {
        command_name    gnocchi-nagios-service
        command_line    /bin/mv /var/spool/gnocchi-nagios/nagios/service-perfdata /var/spool/gnocchi-nagios/ready/service-perfdata.$TIMET$
}

define command {
        command_name    gnocchi-nagios-host
        command_line    /bin/mv /var/spool/gnocchi-nagios/nagios/host-perfdata /var/spool/gnocchi-nagios/ready/host-perfdata.$TIMET$
}

Gnocchi Setup

Installation and configuration of Gnocchi can be found here

Don't forget to create archive policies and archive policies rules that match your needs.

Gnocchi-nagios

Once it's setup, you can configure gnocchi-nagios by creating a gnocchi-nagios.conf:

[DEFAULT]
spool_directory = /var/spool/gnocchi-nagios/ready

[gnocchi]
auth_type = gnocchi-noauth
roles = admin
user_id = nagios
project_id = nagios
endpoint = http://localhost:8041

Note: Gnocchi-data assumes nagios TIMET epoch are in UTC

And then run it with:

$ gnocchi-nagios --config-file=gnocchi-nagios.conf

To get all configuration option you can run

$ tox -egenconfig
$ less etc/gnocchi-nagios/gnocchi-nagios.conf

gnocchi-nagios's People

Contributors

sileht avatar

Watchers

James Cloos avatar  avatar

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.