Git Product home page Git Product logo

munin-influxdb's Introduction

Munin-influxdb

Munin to InfluxDB+Grafana gateway

Tool to migrate smoothly from Munin (RRD) to InfluxDB and Grafana dashboards.

Provide two commands:

  • import
    • Import existing Munin data to InfluxDB (groups fields in the same series by default).
    • Generate a Grafana dashboard based on the existing Munin configuration.
    • Creates a cronjob to run the fetch command.
  • fetch
    • Update InfluxDB with fresh data from a still running Munin service

Import

InfluxDB storage

Data from Munin RRD databases are combined and imported into an InfluxDB cluster (version 0.10 and later).

Munin fields from a same plugin are grouped as columns of the same InfluxDB time series.

Grafana dashboard

Grafana layout settings are imported from Munin plugin's configuration. Supported elements:

  • Min, max, average and current values in legend table
  • Line, area, stacked metrics
  • Warning, critical thresholds
  • Graph orders
  • Aliases
  • Tooltip overlays
  • Metrics colors
  • Multigraphs (partial support)

Dashboard

Installation & Usage

  1. Via Pypi:

    $ pip install munin-influxdb
    
  2. Or the repository

    $ git clone https://github.com/mvonthron/munin-influxdb.git
    $ sudo python setup.py install
    
  3. Run import command:

$ sudo ./muninflux import
  1. A cron job will be automatically added after installation to refresh data from munin every 5 minutes (Munin default)

Some more details

  • About importing current data

Munin stores data in a number of ways: the main storage is RRD databases, but we also have access to the cache of HTML webpages, config files and fresh data storage (see below). munin-influxdb reads the htmlconf.storable file to discover the plugins to extract and some of their settings (legend, thresholds...). The RRD databases (where the data history is kept) are then extracted to XML (because reading RRD's native format is even worse than parsing XML), parsed, and uploaded to InfluxDB. Then the information extracted from the htmlconf files are used to help generate a Grafana dashboard linked to the new InfluxDB storage.

  • About fetching new data

Fresh data is not obtain from the RRD databases but from Munin's storable files. This is a Perl specific format where Munin stores the two latest values for each metric.

Licensing

This program and its documentation are released under the terms of the BSD license.


2016, Manuel Vonthron [email protected]

munin-influxdb's People

Contributors

mvonthron avatar exhuma avatar clorch avatar kenyon avatar gnuheidix avatar

Watchers

t.junichi avatar James Cloos 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.