I just update this excellent script for Debian Lenny x64 on both (HN and CT) and with the 1.3.1 version of rrdtool, I also did some minor changes in the script.
1. You must have installed Debian Lenny x64 + OpenVZ + rrdtool on your HN:
apt-get install rrdtool
2. Download and create a container using this template:
wget http://www.vazart.net/openvz/Debian-Lenny-x64_bandwidth.tar.gz
mv Debian-Lenny-x64_bandwidth.tar.gz /vz/template/cache/
vzctl create 101 --ostemplate Debian-Lenny-x64_bandwidth --config vps.basic --hostname graphs.yourdomain.com --ipadd xxx.xxx.xxx.xxx --name graphs
vzctl set 101 --onboot yes --nameserver xxx.xxx.xxx.xxx --userpasswd root:xxxxxxx --save
vzctl start 101
2.1. You can errase my old rrd data:
vzctl exec 101 rm /home/bandwidth/*
3. Download the script (Bash) to collecting data:
wget http://www.vazart.net/openvz/bandwidth.sh
** You can open it and change the container number in the BWVE variable. **
4. You can make an crontab to run this script every 5 min:
crontab -e
*/5 * * * * /root/bandwidth.sh 1>/var/log/vz-bandwidth.log 2>&1
5. Wait 5 min then visit: http://xxx.xxx.xxx.xxx/ and happy graphing !