Smokeping安装

2.1 安装环境

总体环境: Centos5.5_64 + rrdtool + smokeping

2.2 安装过程 (1)YUM安装

使用YUM安装以下软件:

freetype freetype-devel libpng libpng-devel gd gd-devel libxml2 libxml2-devel

libiconv libiconv-devel pango pango-devel qpixman qpixman-devel glib glib-devel cairo cairo-devel libart* gettext gettext-devel libjpeg libjpeg-devel perl-XML-Simple.noarch perl-Crypt-SSLeay perl-Digest-HMAC

(2)安装rrdtool

rrdtool出图支持中文方法:

echo 'LANG="zh_CN.UTF-8"' >/etc/sysconfig/i18n

export LANG="zh_CN.UTF-8"

yum -y install fonts-chinese

wget http://oss.oetiker.ch/rrdtool/pub/rrdtool-1.4.3.tar.gz

tar zxvf rrdtool-1.4.3.tar.gz

cd rrdtool-1.4.3

sed -i 's/setlocale(LC_NUMERIC, "C")/setlocale(LC_ALL, "zh_CN.UTF-8")/g' src/rrd_graph.c

sed -i 's/setlocale(LC_NUMERIC, old_locale)/setlocale(LC_ALL, old_locale)/g' src/rrd_graph.c

./configure --prefix=/usr/local/rrdtool

make && make install

(3)安装cgilib

wget http://down1.chinaunix.net/distfiles/cgilib-0.5.tar.gz

tar zxvf cgilib-0.5.tar.gz

cd cgilib-0.5

make

cp libcgi.a /usr/local/lib

cp cgi.h /usr/include

(4)安装fping

wget http://fping.sourceforge.net/download/fping.tar.gz

tar zxvf fping.tar.gz

cd fping-2.4b2_to

修改目录下fping.c文件的源代码,以支持双线服务器线路独立监控

修改fping.c文件中第523行:

while( ( c = getopt( argc, argv, "gedhlmnqusaAvz:t:i:I:p:f:r:c:b:C:Q:B:" ) ) != EOF )

修改为:ile( ( c = getopt( argc, argv, "gedhlmnqusaAvz:t:i:S:p:f:r:c:b:C:Q:B:" ) ) != EOF )

修改fping.c文件中第546行:case 'I':为:case 'S':

修改fping.c文件中第2785行:fprintf( stderr, " -I host select source IP address, hostnames are

为: fprintf( stderr, " -S host select source IP address, hostnames are

编译安装fping

./configure --prefix=/usr/local/fping

make

make check

make install

ln -s /usr/local/fping/sbin/fping /usr/sbin/fping

(5)安装echoping

wget http://jaist.dl.sourceforge.net/project/echoping/echoping/6.0.0/echoping-6.0.0.tar.gz

tar zxvf echoping-6.0.0.tar.gz

cd echoping-6.0.0

./configure

make

make test

make install

(6)安装CGI-SpeedyCGI

wget http://daemoninc.com/SpeedyCGI/CGI-SpeedyCGI-2.22.tar.gz

tar zxvf CGI-SpeedyCGI-2.22.tar.gz

cd CGI-SpeedyCGI-2.22

perl Makefile.PL

wget ftp://195.220.108.108/linux/epel/5/x86_64/mod_speedycgi-2.22-4.el5.x86_64.rpm

wget ftp://fr.rpmfind.net/linux/EPEL/5Server/x86_64/perl-CGI-SpeedyCGI-2.22-4.el5.x86_64.rpm

wget ftp://195.220.108.108/linux/epel/5/i386/mod_speedycgi-2.22-4.el5.i386.rpm

wget ftp://fr.rpmfind.net/linux/EPEL/5Server/i386/perl-CGI-SpeedyCGI-2.22-4.el5.i386.rpm

rpm -ivh --force perl-CGI-SpeedyCGI-2.22-4.el5.x86_64.rpm

rpm -ivh mod_speedycgi-2.22-4.el5.x86_64.rpm

cd CGI-SpeedyCGI-2.22

perl Makefile.PL

make

make test

make install

(7)安装smokeping

wget http://oss.oetiker.ch/smokeping/pub/smokeping-2.4.2.tar.gz

tar zxvf smokeping-2.4.2.tar.gz

mv smokeping-2.4.2 /usr/local/smokeping

你可能感兴趣的:(职场,软件,休闲,blank)