syslog
Introduction
Other Services
PHP Manual

# RRDtool

Table of Contents

- Introduction
- Installing/Configuring
  - Requirements
  - Installation
  - Runtime Configuration
  - Resource Types
- Predefined Constants
- Examples
  - Procedural PECL/rrd example
  - OOP PECL/rrd example
- RRD Functions
  - rrd_create — Creates rrd database file
  - rrd_error — Gets latest error message.
  - rrd_fetch — Fetch the data for graph as array.
  - rrd_first — Gets the timestamp of the first sample from rrd file.
  - rrd_graph — Creates image from a data.
  - rrd_info — Gets information about rrd file
  - rrd_last — Gets unix timestamp of the last sample.
  - rrd_lastupdate — Gets information about last updated data.
  - rrd_restore — Restores the RRD file from XML dump.
  - rrd_tune — Tunes some RRD database file header options.
  - rrd_update — Updates the RRD database.
  - rrd_version — Gets information about underlying rrdtool library
  - rrd_xport — Exports the information about RRD database.
  - rrdc_disconnect — Close any outstanding connection to rrd caching daemon
- RRDCreator — The RRDCreator class
  - RRDCreator::addArchive — Adds RRA - archive of data values for each data source.
  - RRDCreator::addDataSource — Adds data source definition for RRD database.
  - RRDCreator::__construct — Creates new RRDCreator instance
  - RRDCreator::save — Saves the RRD database to a file
- RRDGraph — The RRDGraph class
  - RRDGraph::__construct — Creates new RRDGraph instance
  - RRDGraph::save — Saves the result of query into image
  - RRDGraph::saveVerbose — Saves the RRD database query into image and returns the verbose information about generated graph.
  - RRDGraph::setOptions — Sets the options for rrd graph export
- RRDUpdater — The RRDUpdater class
  - RRDUpdater::__construct — Creates new RRDUpdater instance
  - RRDUpdater::update — Update the RRD database file

# The RRDCreator class

## Introduction

Class for creation of RRD database file.

## Class synopsis

RRDCreator
class RRDCreator {
/* Methods */
public void addArchive ( string `$description` )
public void addDataSource ( string `$description` )
public __construct ( string `$path` [, string `$startTime` [, int `$step` = 0 ]] )
public bool save ( void )
}

# The RRDGraph class

## Introduction

Class for exporting data from RRD database to image file.

## Class synopsis

RRDGraph
class RRDGraph {
/* Methods */
public __construct ( string `$path` )
public array save ( void )
public array saveVerbose ( void )
public void setOptions ( array `$options` )
}

# The RRDUpdater class

## Introduction

Class for updating RDD database file.

## Class synopsis

RRDUpdater
class RRDUpdater {
/* Methods */
public __construct ( string `$path` )
public bool update ( array `$values` [, string `$time` = time() ] )
}