Installing Graphite


Since Graphite renders graphs using Cairo, it depends on several graphics-related libraries not typically found on a server. If you’re installing from source you can use the script to see if the dependencies have been met or not.

In general, Graphite requires:

  • Python 2.4 or greater (2.6+ recommended)
  • Pycairo
  • Django 1.0 or greater
  • django-tagging 0.3.1
  • A json module, if you’re using Python2.6 this comes standard. With 2.4 you should install simplejson
  • A Django-supported database module (sqlite comes standard with Python 2.6)
  • Twisted 8.0 or greater (10.0+ recommended)

Also both the Graphite webapp and Carbon require the whisper database library.

There are also several optional dependencies, some of which are necessary for high performance.

  • Apache with mod_wsgi or mod_python (mod_wsgi preferred)
  • memcached and python-memcache
  • python-ldap (for LDAP authentication support in the webapp)
  • txamqp (for AMQP support in Carbon)

See also

On some systems it is necessary to install some fonts, if you get the webapp running and only see broken images instead of graphs, this is probably why.

Tips For Fulfilling Dependencies

Usually the hardest dependency to fulfill is Pycairo because it requires Cairo, which in turn requires fontconfig, etc... Often your distribution’s package manager will be able to install cairo and all of its dependencies for you, but in order to build Pycairo (which is often not covered by the package manager) you’ll need the cairo-devel package so C headers are available.

Binary Packages

We are currently working on getting RPMs and DEB packages ready for Graphite. As of this writing, Whisper is available in Ubuntu. To install it you can simply:

apt-get install python-whisper

The Graphite webapp and Carbon do not yet have binary packages available.

Installing From Source

You can download the latest source tarballs for grahite, carbon, and whisper from the Graphite project page,

To install, simply extract the tarball and install like any other python package.

# First we install whisper, as both Carbon and Graphite require it
tar zxf whisper-0.9.8.tgz
cd whisper-0.9.8/
sudo python2.6 install
cd ..
# Now we install carbon
tar zxf carbon-0.9.8.tgz
cd carbon-0.9.8/
sudo python2.6 install
cd ..
# Finally, the graphite webapp
tar zxf graphite-web-0.9.8.tgz
cd graphite-web-0.9.8/
# once all dependencies are met...
sudo python2.6 install

This will install whisper as a site-package, while Carbon and Graphite will be installed in /opt/graphite/.

Help! It didn’t work!

If you run into any issues with Graphite, feel free to post a question to our Questions forum on Launchpad

Post-Install Tasks

Configuring Carbon
Once you’ve installed everything you will need to create some basic configuration. Initially none of the config files are created by the installer but example files are provided. Simply copy the .example files and customize.
Administering Carbon
Once Carbon is configured, you need to start it up.
Feeding In Your Data
Once it’s up and running, you need to feed it some data.
Configuring The Webapp
With data getting into carbon, you probably want to look at graphs of it. So now we turn our attention to the webapp.
Administering The Webapp
Once its configured you’ll need to get it running.
Using the Composer
Now that the webapp is running, you probably want to learn how to use it.

That covers the basics, the next thing you should probably read about is The URL API.

Table Of Contents

Previous topic

5-minute Overview

Next topic

The Carbon Daemons

This Page