sábado, 31 de março de 2012

greygraph on CentOS

Today I gave a look at greygraph, a mailgraph-based tool for displaying sqlgrey graphs.

Here are the adaptations to run it in CentOS. Have a look at the README inside the distribution, anyway, After unpacking the distribution tarball:

[code]
mkdir -p /var/cache/greygraph
chgrp apache /var/cache/greygraph/
chmod g+w /var/cache/greygraph/
[/code]


Review etc/default/greygraph and copy it to /etc/sysconfig/greygraph:
[code]
mv etc/default/greygraph /etc/sysconfig/greygraph
[/code]

Place files and directories directories:
[code]
mkdir -p /usr/share/greygraph
mv usr/lib/cgi-bin/greygraph.cgi /usr/share/greygraph/
mv var/www/css/greygraph.css /usr/share/greygraph/
mv usr/sbin/greygraph /usr/sbin
mkdir -p /var/lib/greygraph
[/code]

As for the SysV script, I've adapted mailgrah's. Download the script greygraph (remove .txt extension).

In the meantime, I'll try to add the generated RRDs to cacti [1, 2], let me know if you managed to do so.