Page 1 of 1

how to use plugins: loadlogs.pl

Posted: Wed Dec 26, 2012 12:08 am
by jcnb
what do I do with the files and loadconfig.pl loadlogs.pl? I need a tip on how to use these plugins.

Re: how to use plugins: loadlogs.pl

Posted: Wed Dec 26, 2012 10:45 am
by slansing
Where did you get these plugins from? From what I know loadconfig.pl is a SQL loader. But you should check with whoever created the plugin, alternatively they may have a help flag on the plugin, try running the plugin with --help at the end.

Re: how to use plugins: loadlogs.pl

Posted: Wed Dec 26, 2012 12:16 pm
by jcnb
The plugin loads the configuration information and the state in a database. There are two scripts: loadconfig.pl and loadlogs.pl. But I have not found enough information to configure them.

Re: how to use plugins: loadlogs.pl

Posted: Wed Dec 26, 2012 2:06 pm
by sreinhardt
As slansing mentioned, could you link to where you found loadlogs.pl or is this a part of nagDB per your other post? Have you tried executing them with a -h or --help flag?

Re: how to use plugins: loadlogs.pl

Posted: Wed Dec 26, 2012 2:48 pm
by jcnb
Thanks sreinhardt,

In the case of NAGDB plugin, I put the script nagcgi.py into the directory /nagios/libexec and my dificudade is on how to create a schema for use nagdb. Regarding the scripts loadconfig.pl and loadlogs.pl, command line options (- help) are very vague.
http://exchange.nagios.org/directory/Ad ... er/details.

Re: how to use plugins: loadlogs.pl

Posted: Wed Dec 26, 2012 3:14 pm
by slansing
The following is a quote from the exchange page:
This is a first version, so no instructions other than the built-in help text. Set up a mysql database and user, configure the scripts, and it should be clear.
Beyond what is in the help file more information could possibly be found on the creators forum located at:

http://exchange.nagios.org/directory/Ad ... er/details

Have you installed the cpan perl module:

Code: Select all

Nagios::Config
as noted in the exchange post?

Re: how to use plugins: loadlogs.pl

Posted: Fri Jan 04, 2013 4:50 pm
by jcnb
Thank you!

I had problem trying to install Perl modules (DBI, DBD :: mysql and Nagios::Config) on a 32bit architecture, but I was able to install Perl modules in a 64bit architecture.

The plugin is fairly simple. I downloaded it and applied chmod +x to make it executable. So I went to the forum Steve Shipway (creator of the plugin) and obtained the necessary tips.

What I did:

1. I created a database called Nagios.
2. Loadlog.pl configured with the credentials of the database (address of the Nagios server, DB, password, etc).
3. Ran the loadlog.pl pointing to the log files. The pluging created the following tables: loaded, logs, recordtype, logsummary, LogEvents).
4.At the command line:

Code: Select all

#loadlolgs.pl -T /usr/local/nagios/var/archive/*.log
5. Then again ran loadlogs.pl used the-t option (load all kinds of information) with the-f option to force reload the same log file.

However, the information provided by the plugin loadlog.pl does not meet my needs. I am interested in putting state information and performance of hosts and services in a database. I would like to manipulate the information provided by reporting option Nagios (event start time, end time event, event durantion, event/state type, event/state information) in a different way. Do you have any idea how I can do this?


The forum Steve: http://www.steveshipway.org/forum/viewforum.php?f=20

Re: how to use plugins: loadlogs.pl

Posted: Mon Jan 07, 2013 2:50 pm
by sreinhardt
It sounds like you should be looking at something like Nagios XI, with the performance counters and statistics built in, as well as report generation and state change consideration. Otherwise this might be something that you end up having to write if there is nothing else out there.