Graphical statistics for OpenVZ servers

I’m having a VPS running on OpenVZ that I most of the push to the limit. On usual computers the most significant resource is the memory usage, however on a VPS like this there are a lot of other resources running out.

To get a notion of what happen when the server “crashed”/stopped responding I created a collection of scripts that use the rrdtool to store the statistics and generate nice graphics.

Complete System Monitoring

The program collects all variables found in /proc/user_beancounters and other system parameters.

privvmpagesdcachesizeNetwork trafficCPU usage

Requirements

You will need python and rrdtool before running any programs.

Download and Installation

Download using git:

git clone http://src.endnode.se/git/csm

You will get two runnable files, one updating/collecting the data and another for generating the graphics.

Preferably you should make the update script start at system startup and the graph script should be called regularly by a cron daemon but that is not included here.

You can leave a response, or trackback from your own site.

3 Responses to “Graphical statistics for OpenVZ servers”

  1. christian says:

    Perfect work! Thank you very much!

    Just one thing:
    Would you please advise others that we need a script /root/bin/bean and some sudo-config.

    I guess your script has just one line:

    ———————

    #!/bin/sh
    cat /proc/user_beancounters
    ———————

    Kind Regards
    Christian

  2. phq says:

    Thanks Christian

    The package is now updated with the bean.sh file and the additional installation instructions in the README file.

  3. phq says:

    New update available!

    Now it’s possible to track memory consumption on a per user basis. Users must however be preconfigured.

Leave a Reply