Plugin to parse a log file?

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
rpacheco
Posts: 6
Joined: Mon Aug 06, 2012 6:56 am

Plugin to parse a log file?

Post by rpacheco »

I'm looking for some help.

I've been using check_logfiles plugin to check a logfile that collects syslog events. But it is not exactly what I've been asked for, and after looking for it, I found nothing.

The file that collects the syslog events is supposed to receive only errors, so I would like to parse some particular info from every line and show all these lines in a cool way. Is there any plugin or addOn that allows to show, for example, a table with all these lines parsing some selected info?

Thanks in advance.
mguthrie
Posts: 4380
Joined: Mon Jun 14, 2010 10:21 am

Re: Plugin to parse a log file?

Post by mguthrie »

Are you looking to do this on windows or linux?
rpacheco
Posts: 6
Joined: Mon Aug 06, 2012 6:56 am

Re: Plugin to parse a log file?

Post by rpacheco »

I've installed the Nagios demo (so it is Centos OS) and the syslog server is a Windows machine where I've installed de Nagios Client ++
yancy
Posts: 523
Joined: Thu Oct 06, 2011 10:12 am

Re: Plugin to parse a log file?

Post by yancy »

rpacheco,

What Windows application are you using to act as a syslog server?


Regards,

-Yancy
rpacheco
Posts: 6
Joined: Mon Aug 06, 2012 6:56 am

Re: Plugin to parse a log file?

Post by rpacheco »

Right now I'm using kiwisyslog
yancy
Posts: 523
Joined: Thu Oct 06, 2011 10:12 am

Re: Plugin to parse a log file?

Post by yancy »

rpacheco,

Can you be more specific about what data you want check_logsfiles to submit back to Nagios?

As a side note, it looks like Kiwi Syslog could also be integrated with Nagios using SNMP traps.


Regards,

-Yancy
rpacheco
Posts: 6
Joined: Mon Aug 06, 2012 6:56 am

Re: Plugin to parse a log file?

Post by rpacheco »

Thanks yancy.

Every line of my logfile should be an alert. What I really would like is to show a table with this information, so I would like to know if I can handle it and parse the different fields (separated by '#' in plain text in each line) or if I have to define a different service for each possible line in the logfile. So I don't really know if check_logfiles is the best plugin for me or not, or how can I handle it to integrate with Nagios.

Thanks in advance!
yancy
Posts: 523
Joined: Thu Oct 06, 2011 10:12 am

Re: Plugin to parse a log file?

Post by yancy »

rpacheco,
What I really would like is to show a table with this information
Is your goal to show this "table" of information in Nagios?

Regards,

-Yancy
jronin
Posts: 18
Joined: Tue Oct 09, 2012 12:05 pm

Re: Plugin to parse a log file?

Post by jronin »

Yancy:

I have also looked at check_logfiles and was looking for a way to pass syslog data to a table in nagios. Any ideas?
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: Plugin to parse a log file?

Post by slansing »

rpacheco,

It looks like you asked this over at Spiceworks too but I'm afraid the answer will be the same, there is no way to really do this currently short of creating your own component.
Locked