2. RRD - Introduction
RRD aims to handle time-series data like network bandwidth,
temperatures, CPU load, etc.
The data which are stored in a RRD (circular buffer), thus the
system storage footprint remains constant over time.
Provides graphing capabilities
Framework for storing measurement averages, min, max,
derivatives.
Data does not expand in size with time
3. RRD Working
In case of linear databases, new data gets appended at the
bottom of the database table.
Thus its size keeps on increasing, whereas size of an RRDTool
database is determined at creation time. Imagine an RRDTool
database as the perimeter of a circle.
Data is added along the perimeter. When new data reaches the
starting point, it overwrites existing data. This way, the size of an
RRDTool database always remains constant. The name ``Round
Robin'' stems from this attribute.
5. Why RRD?
RRD take care of Time and Space complexity than other linear
databases.
Other databases define tables with columns, and many other
parameters. These definitions sometime are very complex,
especially in large databases.
RRD Tool databases are primarily used for monitoring purposes
and hence are very simple in structure.
The parameters that need to be defined are variables that hold
values and archives of those values.
6. Comparision (RRD with other DB)
Structure
Performance
Configuration
String rrdPath = ... ;
long timestamp = ... ; //Example Date
RrdDb rrd = new RrdDb(rrdPath);
for(int i = 0; i < 10000; i++)
{
Sample sample = rrd.createSample(timestamp);
sample.setValue("input", ...); // 5 Secs
sample.update();
timestamp += ... ;
} rrd.close();
7. RRD Applications
Real Time Application
Temperature Monitoring & Rain Fall
CPU Perfomence
Trafic on LAN per minute
Total minutes of Down Time.
Who Using RRD
Munin
Monitorix
Observium
BackupPC