Monitoring
258
Collectd Client
1. The collectd client and server both use the same package, so we install the client
in the same way.
sudo apt-get update
sudo apt-get -y install collectd libjson-perl
2. The configuration file for the guest is the same as for the server, but we
specify different options. Edit /etc/collectd/collectd.conf with the
following contents:
FQDNLookup true
Interval 10
ReadThreads 5
LoadPlugin network
Server "172.16.0.253" "12345"
LoadPlugin cpu
LoadPlugin df
LoadPlugin disk
LoadPlugin load
LoadPlugin memory
LoadPlugin processes
LoadPlugin swap
LoadPlugin syslog
LoadPlugin users
LoadPlugin interface
Interface "eth0"
3. Restart the collectd service to pick up this change:
sudo service collectd restart
Collectd-web
1. At this point, data is being sent over to the collectd server (at address
172.16.0.253). To view this data, we install another package that can interpret the
RRD files and present them in an easy-to-use web interface. We first download the
collectd-web tarball from the following URL:
http://collectdweb.appspot.com/download/
2. We then unpack the archive, as follows:
tar zxvf collectd-web_0.4.0.tar.gz
www.it-ebooks.info