<DIV>Your mrtg is probably not working correctly, check you <FONT size=2>mrtg.cfg and /var/spool/mail/root to see what's going on with mrtg.</FONT></DIV>
<DIV> </DIV>
<DIV><sign signid="1">
<DIV style="FONT-FAMILY: Arial Narrow; COLOR: #909090; FONT-SIZE: 12px">------------------</DIV>
<DIV style="FONT-FAMILY: Verdana; COLOR: #000; FONT-SIZE: 14px">
<DIV>AJay</DIV></DIV></sign></DIV>
<DIV><qzone signid=""></qzone></DIV>
<DIV><taotao signid=""></taotao></DIV>
<DIV> </DIV>
<DIV><includetail>
<DIV> </DIV>
<DIV> </DIV>
<DIV style="COLOR: #000">
<DIV style="PADDING-BOTTOM: 2px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: Arial Narrow; FONT-SIZE: 12px; PADDING-TOP: 2px">------------------ Original ------------------</DIV>
<DIV style="FONT-SIZE: 12px">
<DIV id=menu_sender><B>From: </B> "xmanhosting"<anthony@xmanhosting.com.au>;</DIV>
<DIV><B>Date: </B> Sat, Nov 14, 2009 12:27 PM</DIV>
<DIV><B>To: </B> "nagios-users"<nagios-users@lists.sourceforge.net>; </DIV>
<DIV></DIV>
<DIV><B>Subject: </B> [Nagios-users] Final stage of getting MRTG working with Nagios v2</DIV></DIV>
<DIV> </DIV>
<DIV><SPAN class=140001104-14112009><SPAN class=593432404-14112009><FONT size=2>Hello,</FONT></SPAN></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><SPAN class=593432404-14112009><FONT size=2></FONT></SPAN></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2>I have been fluffing around with Nagios for a couple of weeks, and have nearly finally nailed it.</FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2>I just have one thing to go.</FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2>I am trying to get MRTG to work with Nagios.</FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2>I have got MRGT working locally on my machine<SPAN class=593432404-14112009> , and can see it working by</SPAN> going to these 2 sites <SPAN class=593432404-14112009> (locally)  </SPAN>in a browser:</FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2><A href="http://m33.mail.qq.com/cgi-bin/frame_html?sid=6AuAxsNrmrW1bmsg&r=31ef6d4e0997510a3066d059ab83e370#">file:///usr/local/mrtg-2/share/mrtg2/icons/index.html</A> and </FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2><A href="http://m33.mail.qq.com/cgi-bin/frame_html?sid=6AuAxsNrmrW1bmsg&r=31ef6d4e0997510a3066d059ab83e370#">file:///usr/local/mrtg-2/share/mrtg2/icons/localhost_2.html</A></FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2>I followed the tutorial below to set up my router with Nagios:</FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2><A href="http://www.thegeekstuff.com/2008/11/how-to-monitor-network-switch-and-ports-using-nagios/">http://www.thegeekstuff.com/2008/11/how-to-monitor-network-switch-and-ports-using-nagios/</A></FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2>however I am yet to get MRTG working with Nagios:</FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><FONT color=#ff0000 size=2>PING OK 11-14-2009 13:13:56 21d 16h 10m 13s 1/3 PING OK - Packet loss = 0%, RTA = 1.38 ms  </FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT color=#ff0000 size=2>Port 1 Bandwidth Usage UNKNOWN 11-14-2009 13:09:49 21d 16h 8m 43s 3/3 <STRONG><FONT color=#000000>check_mrtgtraf: Unable to open MRTG log file</FONT></STRONG>  </FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT color=#ff0000 size=2>Port 1 Link Status OK 11-14-2009 13:11:29 12d 22h 37m 5s 1/3 SNMP OK - up(1)  </FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT color=#ff0000 size=2>Uptime OK 11-14-2009 13:10:29 12d 22h 27m 57s 1/3 SNMP OK - Timeticks: (152738042) 17 days, 16:16:20.42</FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2>My switch.cfg currently has the following:</FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><SPAN lang=EN-AU><FONT size=2></FONT></SPAN></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><SPAN lang=EN-AU><FONT color=#ff0000 size=2># Monitor bandwidth via MRTG logs</FONT></SPAN></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><SPAN lang=EN-AU><FONT size=2><FONT color=#ff0000>define service{<BR>use     generic-service ; Inherit values from a template<BR>host_name    Billion<BR>service_description   Port 1 Bandwidth Usage<BR>check_command    </FONT><FONT color=#000000><STRONG>check_local_mrtgtraf!/usr/local/mrtg-2/share/mrtg2/icons/localhost2.log!AVG!1000000,1000000!5000000,5000000!10</STRONG></FONT></FONT></SPAN></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><SPAN lang=EN-AU><FONT color=#ff0000 size=2>}</FONT></DIV></SPAN></SPAN>
<DIV><SPAN class=140001104-14112009><FONT size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><TR><TD class=statusEven></TD></TR></SPAN><SPAN class=140001104-14112009><FONT size=2>My localhost2.log is at the location above: <STRONG>/usr/local/mrtg-2/share/mrtg2/icons/localhost2.log</STRONG> ,however I still must have something wrong for it to not work.</FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2>When I run: /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg , it says: "<STRONG>Things look okay - No serious problems were detected during the pre-flight check</STRONG>"</FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2>When I run: /usr/local/mrtg-2/bin/mrtg /home/mrtg/cfg/mrtg.cfg , it says: </FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2>-----------------------------------------------------------------------<BR>ERROR: Mrtg will most likely not work properly when the environment<BR>       variable LANG is set to UTF-8. Please run mrtg in an environment<BR>       where this is not the case. Try the following command to start:</FONT></SPAN></DIV>
<DIV> </DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2>       env LANG=C /usr/local/mrtg-2/bin/mrtg /home/mrtg/cfg/mrtg.cfg <BR>-----------------------------------------------------------------------<SPAN class=593432404-14112009> </SPAN></FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2><SPAN class=593432404-14112009></SPAN></FONT></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2><SPAN class=593432404-14112009>When I run: env LANG=C /usr/local/mrtg-2/bin/mrtg /home/mrtg/cfg/mrtg.cfg  , there are no errors. </SPAN><BR><SPAN class=593432404-14112009> </SPAN></FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2><SPAN class=593432404-14112009>Does anyone know what I am still doing wrong</SPAN></FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2><SPAN class=593432404-14112009></SPAN></FONT></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2><SPAN class=593432404-14112009>Thanks for any help,</SPAN></FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2><SPAN class=593432404-14112009></SPAN></FONT></SPAN> </DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2><SPAN class=593432404-14112009>Kind regards,</SPAN></FONT></SPAN></DIV>
<DIV><SPAN class=140001104-14112009><FONT size=2><SPAN class=593432404-14112009>Anthony </SPAN></FONT></DIV></SPAN></DIV></includetail></DIV>