十一.安装Extman图形化日志
安装所需要的依赖包
apt-get install libxml2-dev sudo apt-get install libpango1.0-dev
wget http://cpan.weepee.org/authors/id/J/JH/JHI/Time-HiRes-1.9721.tar.gz
安装Time::HiRes
tar -zxvf Time-HiRes-1.9721.tar.gz cd Time-HiRes-1.9721 perl Makefile.PL make make test make install
wget http://ftp.belnet.be/mirror/ftp.cpan.org/authors/id/M/MG/MGRABNAR/File-Tail-0.99.3.tar.gz
安装File::Tail
tar -zxvf File-Tail-0.99.3.tar.gz cd File-Tail-0.99.3 perl Makefile.PL make make test make install
wget http://oss.oetiker.ch/rrdtool/pub/rrdtool-1.4.4.tar.gz
安装rrdtool-1.2.23
tar zxvf rrdtool-1.2.23.tar.gz cd rrdtool-1.2.23 ./configure --prefix=/usr/local/rrdtool make make install
如果出现类似这样的错误:
configure: WARNING:
—————————————————————————-
* I could not find a working copy of cairo-png. Check config.log for hints on why
this is the case. Maybe you need to set LDFLAGS and CPPFLAGS appropriately
so that compiler and the linker can find libcairo and its header files. If
you have not installed cairo-png, you can get it either from its original home on
http://cairographics.org/releases/
You can find also find an archive copy on
http://oss.oetiker.ch/rrdtool/pub/libs
The last tested version of cairo-png is 1.4.6.
LIBS=-lm
LDFLAGS=
CPPFLAGS=
—————————————————————————-
configure: error: Please fix the library issues listed above and try again.
请根据提示下载cairo-png并进行安装就可以了
可以参考这个官网的安装方法
———————————————————————————————————————————
http://cairographics.org/download/
For Debian and Debian derivatives including Ubuntu:
sudo apt-get install libcairo2-dev
For Centos:
yum install cairo-devel
———————————————————————————————————————————
复制相关文件,Extman会到以下路径找相关的库文件
cp -r /usr/local/rrdtool/lib/perl/5.8.8/ x86_64-linux-gnu-thread-multi/ /usr/lib/perl5/
———————————————————————————————————————————
复制mailgraph_ext到/usr/local,并启动之
———————————————————————————————————————————
cp -r /var/www/extsuite/extman/addon/mailgraph_ext /usr/local
/usr/local/mailgraph_ext/mailgraph-init start
———————————————————————————————————————————
添加到自动启动队列
———————————————————————————————————————————
echo “/usr/local/mailgraph_ext/mailgraph-init start” >> /etc/rc.local
———————————————————————————————————————————