<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii">
<META content="MSHTML 6.00.2900.2802" name=GENERATOR></HEAD>
<BODY
style="WORD-WRAP: break-word; khtml-nbsp-mode: space; khtml-line-break: after-white-space">
<DIV dir=ltr align=left><SPAN class=445410223-20022006><FONT face=Arial
color=#0000ff size=2>I have uploaded to <A
href="http://www.nagiosexchange.org">www.nagiosexchange.org</A> a utility (in
Perl) that will regularly eat an archived Nagios log file from Nagios 1.x and
install it into a mysql database for subsequent reporting. We're using it
here in beta. Feel free to download it and try it, or modify for your own
use.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=445410223-20022006><FONT face=Arial
color=#0000ff size=2></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=445410223-20022006><FONT face=Arial
color=#0000ff size=2>You can get the documentation on the fields in the .log
file from the developer section of the nagios website. Note that the .log
file format changes in Nagios 2.0 (an extra field was added)</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=445410223-20022006><FONT face=Arial
color=#0000ff size=2></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=445410223-20022006><FONT face=Arial
color=#0000ff size=2>Steve</FONT></SPAN></DIV><BR>
<BLOCKQUOTE dir=ltr
style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #0000ff 2px solid; MARGIN-RIGHT: 0px">
<DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left>
<HR tabIndex=-1>
<FONT face=Tahoma size=2><B>From:</B> nagios-users-admin@lists.sourceforge.net
[mailto:nagios-users-admin@lists.sourceforge.net] <B>On Behalf Of </B>Stephen
Joy<BR><B>Sent:</B> Tuesday, 21 February 2006 11:46 a.m.<BR><B>To:</B>
nagios-users@lists.sourceforge.net<BR><B>Subject:</B> [Nagios-users] MySql
Status Data<BR></FONT><BR></DIV>
<DIV></DIV>Hello All,
<DIV><BR class=khtml-block-placeholder></DIV>
<DIV>I am trying to get Nagios V1.3 to write its status data to a MySql
database but am not yet quite there.</DIV>
<DIV><BR class=khtml-block-placeholder></DIV>
<DIV>So far i have created the database 'nagios' and understand from the
manual that you must create the <FONT class=Apple-style-span face=Arial
size=3><SPAN class=Apple-style-span style="FONT-SIZE: 13px">three tables
(named </SPAN></FONT><FONT class=Apple-style-span face=Arial size=3><SPAN
class=Apple-style-span
style="FONT-SIZE: 13px"><B>programstatus</B></SPAN></FONT><FONT
class=Apple-style-span face=Arial size=3><SPAN class=Apple-style-span
style="FONT-SIZE: 13px">, </SPAN></FONT><FONT class=Apple-style-span
face=Arial size=3><SPAN class=Apple-style-span
style="FONT-SIZE: 13px"><B>hoststatus</B></SPAN></FONT><FONT
class=Apple-style-span face=Arial size=3><SPAN class=Apple-style-span
style="FONT-SIZE: 13px">, and </SPAN></FONT><FONT class=Apple-style-span
face=Arial size=3><SPAN class=Apple-style-span
style="FONT-SIZE: 13px"><B>servicestatus</B></SPAN></FONT><FONT
class=Apple-style-span face=Arial size=3><SPAN class=Apple-style-span
style="FONT-SIZE: 13px">)</SPAN><FONT class=Apple-style-span
face=Helvetica> but what are the fields?? This does not seem to be
covered in the manual.</FONT></FONT></DIV>
<DIV><BR class=khtml-block-placeholder></DIV>
<DIV>I have created the 3 tables with a single field (testing) in the hope the
nagios would define the tables itself but no luck.</DIV>
<DIV><BR class=khtml-block-placeholder></DIV>
<DIV>At the moment my nagios.log looks like this;</DIV>
<DIV>----------------------------------------------------------------------------------------------------------------------------------------------------------</DIV>
<DIV>[1140474946] Nagios 1.3 starting... (PID=19392)</DIV>
<DIV>[1140474946] Finished daemonizing... (New PID=19393)</DIV>
<DIV>[1140474946] Error: Could not insert/update status record for program in
table 'programstatus' of database 'nagios'</DIV>
<DIV>[1140474961] Error: Could not insert/update status record for program in
table 'programstatus' of database 'nagios'</DIV>
<DIV>----------------------------------------------------------------------------------------------------------------------------------------------------------</DIV>
<DIV><BR class=khtml-block-placeholder></DIV>
<DIV>If anyone knows what the fields should be or what to do next that would
be great.</DIV>
<DIV><BR class=khtml-block-placeholder></DIV>
<DIV>Many Thanks,</DIV>
<DIV><BR class=khtml-block-placeholder></DIV>
<DIV>Stephen Joy.</DIV></BLOCKQUOTE></BODY></HTML>