First, what is MRTG
MRTG (Multi Router Traffic Grapher), usually approximately a monitoring web link traffic load open source software,
Yellow diamond grade changes (Tutorial ), which can run from the SNMP protocol as all devices ( including servers, routers, switches, etc.) to grab information. In fact, it can not merely monitor web devices, any other devices that advocate SNMP protocol can be used as MRTG monitoring of the object, and automatically generate the HTML contains the PNG picture format documents, through HTTP is displayed to the user.
Second, prepare the installation environment
I use the operating system is Windows Server 2003 (SP1), the hardware system CPU Celeron 800MHz, RAM 256MB. Before installation, in increase to MRTG installation, but also download some supporting software. All the software is free.
1. Download MRTG
http://www.mrtg.org
2. Download ActivePerl
; http://www.activestate.com/Products/Download/Download.plex?id=ActivePerl
3. Download the Windows service installation tools: SERANY.exe and INSTSRV.exe
http://www.electrasoft.com/srvany/srvany.htm
Third,
I suggest Hot Mobile in 31 provinces national top- 50 mobile call mathematics, install MRTG
;
of the on software afterward downloading to start the installation. In truth, in Windows is quite uncomplicated to install MRTG, because MRTG namely based aboard Perl language development, so to premier install the operating surroundings of a Perl language out.
1. Install ActivePerl ActivePerl
unzip the pack, ascertain the install.cmd in the installation catalogue of the file, run it can be. In the DOS window, the installer will query some questions, such as the installation way, if to adjust environment variables, etc.,
Have entrepreneurial spirit and ambition have to look at, can entire use the default settings, all the direction to enter on the line. By default, Perl installed in C: Perl directory. After installation, open the Windows environment variables to check whether the boost of the running Perl file path.
2. Installing MRTG MRTG
unzip the package, I use MRTG-2.12.2 version. Will be unpacked directory to C: under on the line.
3. to see what is left out
stands to cause that the above two steps done, MRTG should be competent to run. But the fact is there so entities are never flat, huh ....
then we see by, what areas absence to process it.
(1), SNMP protocol support to the Windows installation
routinely recommended because SNMP is a protocol closure (because of security vulnerabilities ), so no the default installation of Windows 2003. MRTG is to use the SNMP protocol, whatever, can not help it, to install a bar. In the
(2), modify the security settings for SNMP monitoring
whether the machine is too running Windows, then this portion will surely To set (set to be monitored side, MRTG where the server can not set), alternatively not get any SNMP messages. Open the Services window and find
SNMP service, open the context menu, elect Properties. In the window that opens find the In the Options page, set up of two parts, the upper half of which is the SNMP service to adopt Community command, Windows 2003 does not default to any directive feedback. I usually set to You can set the lower half of a trusted host label, IP or IPX label.
(3), modify the firewall
If you install a firewall, memorize to open the UDP 161 wharf, or will a lot of problems .
4, running MRTG
Well, finally finished installation. Now you can run about MRTG, and see if it's true colors.
open the DOS window, first enter the C: mrtg-2.12.2 binary, and then enter the following command:
perl cfgmaker [email = [ ,],[to the MRTG configuration file to create a monitoring, monitoring of the object is localhost, is the local machine. You can also use IP residence instead of localhost, or links to other monitoring hosts.
then type a command:
perl mrtg mrtg.cfg
this directive in the C: Inetpub wwwroot mrtg directory set up some HTML and PNG files,
GHD Precious Gift Set, which is that users constantly see the traffic report was.
five, so that MRTG into Windows services
SERANY.exe and INSTSRV.exe Windows comes with two procedures are the tools of the software. They can be anyone Windows petition to setup a
Windows for a service.
(1), modify the registry
build a txt file, jot the following in the file and retention it as mrtg . reg file:
Windows Registry Editor Version 5.00
; [HKEY_LOCAL_MACHINE SYSTEM CurrentControlSet Services MRTG Parameters]
perl bin wperl.exe mrtg - recording = eventlog c: mrtg bin mrtg.cfg Copy MRTG installation directory, type the following command:
instsrv MRTG c: mrtg bin srvany.exe
; double mrtg.reg documents, the information for registration to the registry. In the
in the MRTG installation documentation, instructions to run the service in the Windows of the process table can be seen SERANY the process, I may be in the Windows 2000 Server watch this process in the Windows 2003 Server not seen. Do not understand what the reason, but my MRTG run as good.
Trackback: http://tb.blog.csdn.net/TrackBack.aspx?PostId=478175