logo资料库

Smokeping For Windows 详细安装文档.docx

第1页 / 共13页
第2页 / 共13页
第3页 / 共13页
第4页 / 共13页
第5页 / 共13页
第6页 / 共13页
第7页 / 共13页
第8页 / 共13页
资料共13页,剩余部分请下载后查看
Smokeping2.6.8 For Windows With IIS FCGI
Smokeping的使用
出现的一些问题解决方法
Smokeping2.6.8 For Windows With IIS FCGI 一、 软件准备 Perl (choose Perl 5.8.xxx MSI package for Windows) ActivePerl-5.8.7.815-MSWin32-x86-211909.msi 下载地址:http://download.csdn.net/detail/xxh2002/2395097 115 网盘地址 http://115.com/file/bed1wl9l RRDS module for Perl rrdtool-1.2.10-win32-perl58.zip 下载地址: http://oss.oetiker.ch/rrdtool/pub/rrdtool-1.2.10-win32-perl58.zip 115 网盘下载地址 http://115.com/file/an7pjgn9 fping for windows 下载地址:http://dev.pulsed.net/misc/fping.zip 115 网盘下载地址 http://115.com/file/e7kcs6fe Smokeping smokeping-2.6.8.tar.gz 下载地址:http://oss.oetiker.ch/smokeping/pub/smokeping-2.6.8.tar.gz 115 网盘下载地址 http://115.com/file/an7pjipq Notepad++ 当然也可以用自己使用顺手的文本编辑器 Web Server IIS6.0(之前用 Apach+FCGI 做 web,偶尔未知情况会出现 500 错误,找不到原因, 所以在这里修改为 IIS+FCGI 做 web 服务器) 二、 软件安装 1.安装 Activestate Perl,运行 ActivePerl-5.8.7.815-MSWin32-x86-211909.msi,默认路径为 c:/Perl , 安装完成后重启系统. PS:Other Way 添加系统变量 perl 路径为 c:/perl/bin/perl.exe 2.安装 RRDtool 3.解压 smokeping 到 c:\smokeping 4.解压 Fping (cygwin1.dll 和 fping.exe)到 C:\smokeping\fping 5.IIS for windows ,解压后运行 install.cmd 默认安装就行. 三、 软件配置 1.Activestate Perl 首先要安装两个扩展插件 Grammar、 FCGI 方法: 命令提示符窗口输入 cmd #ppm #search grammar #install 1
#search fcgi Install 3 2) C:\smokeping\bin\smokeping 改名为 smokeping.pl C:\smokeping\bin\tSmoke 改名为 tSmoke.pl 复制 C:\cmokeping\etc\config.dist 并改名为 config 3) 编辑 C:\smokeping\bin\smokeping.pl 第 10 行下面添加 use lib qw(C:\smokeping\lib); 第 14 行 Smokeping::main("etc/config.dist"); 改为 Smokeping::main("C:/smokeping/etc/config"); C:\smokeping\bin\tSmoke.pl 第 66 行 my $cfgfile = "etc/config.dist"; 改为 my $cfgfile = "C:\smokeping\etc\config "; C:\smokeping-\lib\Smokeping.pm 注释以下几行 (line 16): use Sys::Syslog qw(:DEFAULT setlogsock); into #use Sys::Syslog qw(:DEFAULT setlogsock); (line 31): $ENV{LC_NUMERIC}='C'; into #$ENV{LC_NUMERIC}='C'; (line 32-61): 注释掉程序 if (setlocale(LC_NUMERIC,"") ne "C") (line 4211): daemonize_me $cfg->{General}{piddir}."/smokeping.pid"; into #daemonize_me $cfg->{General}{piddir}."/smokeping.pid"; (line 4117-4118)注释掉对 secret.txt 访问权限的判断
4) 创建文件夹 c:\smokeping\cgi 并赋予 user 组“完全控制权限” 复制 C:\smokeping\bin\smokeping_cgi 到 c:\smokeping\cgi 并且改名为 smokeping.pl 5) 编辑 c:\smokeping\cgi\smokeping.pl 第一行修改为 #! C:\perl\bin\perl.exe –w 第 11 行添加 use lib qw(C:\smokeping\lib); 第 21 行 my $cfg = (shift @ARGV) || "$FindBin::Bin/../etc/config"; 修改为 my $cfg = (shift @ARGV) || "c:/smokeping/etc/config.dist";(这 里跟 c:/smokeping/bin/smokeping.pl 里面的使用的不是同一个 config 文件) E) 创建文件夹 c:\smokeping\www\simg F) 编辑 C:\smokeping\etc\config(For c:/smokeping/bin/smokeping.pl) 和 C:\smokeping\etc\config.dist(for c:/wamp/cgi/smokeping.pl) 以下内容红色部分为修改的内容,需要注意路径 c:\smokeping\var *** General *** owner = tingshow contact = tingshow@vip.qq.com mailhost = smtp.qq.com #sendmail = /usr/sbin/sendmail # NOTE: do not put the Image Cache below cgi-bin # since all files under cgi-bin will be executed ... this is not # good for images. imgcache = c:/smokeping/www/simg imgurl = ../simg datadir = \smokeping/var # designate implicitly c:\smokeping\var (for c:/smokeping/bin/smokeping.pl )
datadir = c:/smokeping/var # designate implicitly c:\smokeping\var (For c:/wamp/cgi/smokeping.pl) piddir = C:/smokeping/var cgiurl = http://127.0.0.1/cgi-bin/smokeping.pl smokemail = C:/smokeping/etc/smokemail.dist tmail = C:/smokeping/etc/tmail.dist # specify this to get syslog logging #syslogfacility = local0 # each probe is now run in its own process # disable this to revert to the old behaviour # concurrentprobes = no *** Alerts *** to = alertee@address.somewhere from = smokealert@company.xy +someloss type = loss # in percent pattern = >0%,*12*,>0%,*12*,>0% comment = loss 3 times in a row
*** Database *** step = 300 pings = 20 # consfn mrhb steps total AVERAGE 0.5 1 1008 AVERAGE 0.5 12 4320 MIN 0.5 12 4320 MAX 0.5 12 4320 AVERAGE 0.5 144 MAX 0.5 144 MIN 0.5 144 720 720 720 *** Presentation *** charset = gb2312 template = C:/smokeping/etc/basepage.html.dist + charts menu = Charts
title = The most interesting destinations ++ stddev sorter = StdDev(entries=>4) title = Top Standard Deviation menu = Std Deviation format = Standard Deviation %f ++ max sorter = Max(entries=>5) title = Top Max Roundtrip Time menu = by Max format = Max Roundtrip Time %f seconds ++ loss sorter = Loss(entries=>5) title = Top Packet Loss menu = Loss format = Packets Lost %f ++ median sorter = Median(entries=>5)
title = Top Median Roundtrip Time menu = by Median format = Median RTT %f seconds + overview width = 600 height = 50 range = 10h + detail width = 600 height = 200 unison_tolerance = 2 "Last 3 Hours" "Last 30 Hours" "Last 10 Days" 3h 30h 10d "Last 400 Days" 400d #+ hierarchies
#++ owner #title = Host Owner #++ location #title = Location *** Probes *** + FPing binary = c:/smokeping/fping/fping.exe #*** Slaves *** #secrets=c:/smokeping/etc/smokeping_secrets.dist #+boomer #display_name=boomer #color=0000ff #+slave2 #display_name=another #color=00ff00 *** Targets ***
分享到:
收藏