du2rrd - Long Term Disk Space Monitoring

Are you running a big Unix/Linux? file server with many users.? Are you interested in keeping track on how they use up all that space?

Then du2rrd is for you. It visualizes disk space usage in a state of the art Ajax Web GUI. It uses RRDtool for data storage and graphing.

du2rrd takes ouput from du, parses it and adds it to RRD files. A qooxdoo based AJAX Web interface visualizes the diskspace usage.

The best way to understand what this tool can do for you is to take a look at the du2rrd Demo site.


du2rrd is distributed under the Gnu GPL and you can download a copy right here.

Using du2rrd

Before you start setting up du2rrd, a few words about the configuration of the system. du2rrd does not use a configuration file. You have to supply all the relevant configuration information on the command line when calling it.

du -k /home | du2rrd --rrd_root=/var/lib/du2rrd 'Home=/home/{Users}'

In this simple example we track the home directories which all live in the same tree.

du -k /home-* | du2rrd --rrd_root=/var/lib/du2rrd 'Users=/*/{User}' 'Partitions=/{Partition}/{User}'

This second example is for a server where several home partitions exist. du2rrd will create two different views on the data. We create two maps, a global one for all users and a second one where the users are grouped by partition.

Find more details about maps in the du2rrd manual page.

Setup instructions

du2rrd is written in perl and consists of two parts. The du parser called du2rrd and the web interface consisting of a large chunk of Javascript and the du2rrd.cgi rpc service.

To make this system work, you have to run du2rrd once a day, feeding it input from du and setup the CGIs on your web server.

Step by step this means:

  • Make sure perl, rrdtool perl bindings and a web server are installed on your machine.
  • Learn how to configure your web server to execute CGI scripts.
  • Download and upack the du2rrd archive
  • Create a crontab entry to run du2rrd once a day
  • Install the CGI and the javascript onto your web server
  • Edit the du2rrd.cgi to point to the du2rrd data store.

Enjoy !


Initial work on this tool has been sponsored by the Friedrich Miescher Institute for Biomedical Research


2007-12-20, Tobi Oetiker tobi@…

Last modified 14 years ago Last modified on Jan 4, 2008, 11:38:14 AM