Skip to content
No description, website, or topics provided.
C++ JavaScript M4 CSS Shell HTML Other
Branch: master
Clone or download

Latest commit

Fetching latest commit…
Cannot retrieve the latest commit at this time.

Files

Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
ahutils Merge commit 'f019652526d12d3c10d2b018d5e3a4dfd2f4f276' as 'ahutils' Apr 6, 2014
builder @ 766857e Add pdns-bulder Aug 27, 2019
builder-support Move packages to built_pkgs after building Aug 28, 2019
examples feeder script for verbose linux statistics - network only for now Apr 20, 2014
html fix url Mar 24, 2020
m4
yahttp Updated yahttp. Aug 29, 2016
.gitignore Move packages to built_pkgs after building Aug 28, 2019
.gitmodules Add pdns-bulder Aug 27, 2019
.travis.yml
LICENSE Initial commit Mar 29, 2014
Makefile.am Add sdist dockerfile Aug 27, 2019
README.md Autotoolize metronome Jan 30, 2016
bootstrap Autotoolize metronome Jan 30, 2016
build-deb Fix the debian build script for ot builder Sep 19, 2016
build-rpm fix typo in build script Jun 9, 2017
configure.ac Add sdist dockerfile Aug 27, 2019
dolog.hh Add a disable-syslog option Sep 19, 2016
interpolate.cc fix crash on duplicate data points, make us crash on *any* fp error n… Apr 10, 2014
interpolate.hh hmm, were these missing? Apr 8, 2014
iputils.cc Found one possible cause for issue #14 and fixed it Jan 10, 2015
iputils.hh move some socket stuff to iputils to slim down metronome.cc Apr 5, 2014
mdump.cc add mdump tool to inspect contents of all metrics files Jun 23, 2016
metromisc.hh actually commit what we described in previous commit message Jan 10, 2015
metronome-upstart.conf Fix Upstart script (it was incomplete) Nov 9, 2016
metronome.cc Merge pull request #48 from pieterlexis/plain-json Jul 3, 2019
metronome.service.in Harden metronome service Nov 6, 2016
mmanage.cc fix dropping off at the end of a week Dec 25, 2014
msubmit.cc actually support ipv6 for msubmit Apr 21, 2014
statstorage.cc Filter the metric name, allowing only alphanum, _, . and - Jan 14, 2016
statstorage.hh Filter the metric name, allowing only alphanum, _, . and - Jan 14, 2016
test-statstorage.cc implement simple unit tests, hook up travis, add getMetrics to statst… Apr 5, 2014
testrunner.cc implement simple unit tests, hook up travis, add getMetrics to statst… Apr 5, 2014

README.md

metronome

Mini-graphite that uses client-side java script to render graphs w/o depending on graphite.

'metronome' implements the carbon protocol, so anything that can feed Graphite can feed metronome. We also accept submissions via POST:

For example, to submit RX bytes for eth0:

while true;
do
    VAL=$(ip -s link ls eth0 | grep RX -A 1 | tail -1 | awk '{print $1}')
    wget -q --post-data="" "http://127.0.0.1:8000/?do=store&name=rxbytes&timestamp=$(date +%s)&value=$VAL" -O /dev/null
    sleep 1
done

To retrieve data:

$ wget http://127.0.0.1:8000/?do=retrieve&name=rxbytes&begin=0&end=$(date +%s)&callback=jsonp

This delivers a JSONP callback with your values in there.

To view, try html/index.html

Installing

Dependencies include a recent g++ (4.7+), Boost and libeigen.

Installing Eigen

Either install libeigen3-dev (Debian, Ubuntu), eigen3-devel (Fedora, EPEL).

To install it manually:

$ wget http://bitbucket.org/eigen/eigen/get/3.2.1.tar.bz2
$ tar xf 3.2.1.tar.bz2

Compiling

$ ./bootstrap
$ ./configure
$ make

If you installed libeigen manually, use ./configure --with-eigen=/path/to/eigen

Running

$ mkdir stats
$ ./metronome --stats-directory=./stats

Next, host the 'html/' directory somewhere on a webserver, and edit 'html/local.js' so it knows the Webserver IP address of metronome (port 8000 on :: by default).

Thanks to

Aki Tuomi for the excellent yahttp, Rickshaw for the graphs. Eigen for the math. And a cast of thousands for C++2011.

status

"Toy" for now - stores all data in flat files, which we read in their entirety to replay data.

But, starting to look nice.

You can’t perform that action at this time.