启用验证码功能:
[root@localhost extman]# vim webman.cf
SYS_CAPTCHA_ON = 1 #启用校验码功能
无法正常显示校验码,安装perl-GD模块即可;如果想简单,可以下载适合平台的rpm包,安装即可:
[root@mail ~]# yum install perl-GD.i686 -y
启用图形化日志功能:
点击图形日志出现:
extman-1.1自带了图形化显示日志的功能,此功能需要rrdtool的支持,需要安装此些模块才可能正常显示图形日志。
安装图形日志的运行所需要的软件包Time::HiRes、File::Tail和rrdtool,其中前两个包可以去搜索并下载,后一个包可以到 下载获得;
开始安装:注意安装顺序不能改换。
1.安装Time::HiRes
[root@mail ~]# tar zxvf Time-HiRes-1.9726.tar.gz
[root@mail ~]# cd Time-HiRes-1.9726
[root@mail Time-HiRes-1.9726]# perl Makefile.PL
[root@mail Time-HiRes-1.9726]# make
[root@mail Time-HiRes-1.9726]# make test
[root@mail Time-HiRes-1.9726]# make install
2.安装File::Tail
[root@mail ~]# tar zxvf File-Tail-1.3.tar.gz
[root@mail ~]# cd File-Tail-1.3
[root@mail File-Tail-1.3]# perl Makefile.PL
[root@mail File-Tail-1.3]# make
[root@mail File-Tail-1.3]# make test
[root@mail File-Tail-1.3]# make install
3.安装rrdtool
[root@mail ~]# tar xzvf rrdtool-1.4.5.tar.gz
[root@mail ~]# cd rrdtool-1.4.5
[root@mail rrdtool-1.4.5]# ./configure --prefix=/usr/local/rrdtool(下面会有错误,要重新编译的)
[root@mail rrdtool-1.4.5]# make && make install
4.安装完成后进行相关配置:
4.1.创建必要的符号链接(Extman会到这些路径下找相关的库文件)
[root@mail ~]# ln -sv /usr/local/rrdtool/lib/perl/5.10.1/i386-linux-thread-multi/auto/RRDs/RRDs.so /usr/lib/perl5/5.10.0/i386-linux-thread-multi/
`/usr/lib/perl5/5.10.0/i386-linux-thread-multi/RRDs.so' -> `/usr/local/rrdtool/lib/perl/5.10.1/i386-linux-thread-multi/auto/RRDs/RRDs.so'
[root@mail ~]# ln -sv /usr/local/rrdtool/lib/perl/5.10.1/RRDp.pm /usr/lib/perl5/5.10.0
`/usr/lib/perl5/5.10.0/RRDp.pm' -> `/usr/local/rrdtool/lib/perl/5.10.1/RRDp.pm'
[root@mail ~]# ln -sv /usr/local/rrdtool/lib/perl/5.10.1/i386-linux-thread-multi/RRDs.pm /usr/lib/perl5/5.10.0
`/usr/lib/perl5/5.10.0/RRDs.pm' -> `/usr/local/rrdtool/lib/perl/5.10.1/i386-linux-thread-multi/RRDs.pm'
[root@mail perl5]# ln -sv /usr/local/rrdtool/lib/perl/5.10.1/i386-linux-thread-multi/RRDs.pm /usr/lib/perl5
`/usr/lib/perl5/RRDs.pm' -> `/usr/local/rrdtool/lib/perl/5.10.1/i386-linux-thread-multi/RRDs.pm'
4.2.复制mailgraph_ext到/usr/local,并启动它
[root@mail ~]# cp -r /var/www/extsuite/extman/addon/mailgraph_ext /usr/local
[root@mail ~]# /usr/local/mailgraph_ext/mailgraph-init start(出错了,查资料才知道要在编译时加一项)
而且在创建符号链接时显示:
[root@localhost rrdtool-1.4.5]# ln -sv /usr/local/rrdtool/lib/perl/5.10.1/i386-linux-thread-multi/RRDs.pm /usr/lib/perl5
ln: creating symbolic link `/usr/lib/perl5/RRDs.pm': File exists 这样也省了创建链接步骤了,但是复制那一步不要少;
Starting mail statistics grapher: mailgraph_ext
Can't locate RRDs.pm in @INC (@INC contains: /usr/local/lib/perl5 /usr/local/share/perl5 /usr/lib/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib/perl5 /usr/share/perl5 .) at /usr/local/mailgraph_ext/mailgraph_ext.pl line 292.
BEGIN failed--compilation aborted at /usr/local/mailgraph_ext/mailgraph_ext.pl line 292.
Starting queue statistics grapher: qmonitor
Can't locate RRDs.pm in @INC (@INC contains: /usr/local/lib/perl5 /usr/local/share/perl5 /usr/lib/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib/perl5 /usr/share/perl5 .) at /usr/local/mailgraph_ext/qmonitor.pl line 8.
BEGIN failed--compilation aborted at /usr/local/mailgraph_ext/qmonitor.pl line 8.
4.3正确的编译:
[root@localhost rrdtool-1.4.5]# ./configure --prefix=/usr/local/rrdtool --enable-perl-site-install
[root@localhost rrdtool-1.4.5]# make && make install
4.4重新启动:
[root@localhost rrdtool-1.4.5]# /usr/local/mailgraph_ext/mailgraph-init start
Starting mail statistics grapher: mailgraph_ext
Starting queue statistics grapher: qmonitor
4.5启动cmdserver(在后台显示系统信息)
[root@localhost rrdtool-1.4.5]# /var/www/extsuite/extman/daemon/cmdserver --daemon
loaded ok
4.6添加到自动启动队列
[root@localhost rrdtool-1.4.5]# echo "/usr/local/mailgraph_ext/mailgraph-init start" >> /etc/rc.d/rc.local
[root@localhost rrdtool-1.4.5]# echo "/var/www/extsuite/extman/daemon/cmdserver -v -d" >> /etc/rc.d/rc.local
测试:
发信后登录邮件管理后台,点击图形日志显示:
安装成功!