# RRDtool※

RRDTool is Tobi Oetiker's claim to fame - and, by far, the most widely used graphing tool for IP traffic.

### Notes:

#### Compiling RRDTool 1.2.x under Mac OS X:

Make sure you issue:

export LDFLAGS="-framework Carbon"; export CPPFLAGS=\$LDFLAGS

before compiling freetype2 (but only for building this library), otherwise you'll get the following error message when running:

dyld: Symbol not found: _FSPathMakeRef

Also, a nice thing to remember (if you're building without pkgconfig and straight into /usr/local) is issuing this:

export CFLAGS="-I/usr/local/include/libart-2.0 -I/usr/local/include/libpng12/ -I/usr/local/include/freetype2"

#### Compiling RRDTool pre-1.2.x under Cygwin:

Modify the following line in src/Makefile.in and libpngXXX/Makefile.in:

- CFLAGS = @CFLAGS@
+ CFLAGS = @CFLAGS@ -DPNG_STATIC

./configure as usual.

From 1.0.40 onwards, the Perl bindings install out of the box under Cygwin (with Perl 5.8.0).

#### Filtering rollover peaks using RPN:

(dashed line delimits binary and ternary operator scope)

CDEF:new_name=ds_name,UN,0,ds_name,IF,min_peak,max_peak,LIMIT,UN,max_peak,ds_name,IF
+---------+ - if data point is unknown, return 1
+------------+ - if data was unknown, push zero.
+-----------------------+ - unknown if outside
if it was outside - +--+
then replace with upper bound - +------------------+


The boundary coercion to the upper bound is optional, of course. Most of the time it is better to have UNs on the graph (as breaks on the data) rather than have a large peak pushing the scale up.