Nagios to monitor Event Queue on Web Server

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
nagwindmon
Posts: 92
Joined: Mon Dec 01, 2014 3:39 pm

Nagios to monitor Event Queue on Web Server

Post by nagwindmon »

hello,
Currently working on RESTful API to be available to Client Apps from Web Server.
The idea is to let Client utilize this API to fire event in case of error/issue and log it on Web Server and then have Nagios monitor/check on Event Queue on that Web Server for new Events and send trap/alert to ticketing system. Is there a way how can I accomplish this?

Thanks!
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: Nagios to monitor Event Queue on Web Server

Post by abrist »

What type of web api are we talking about here? check_http can check for strings at a url, which you could then tie into an event handler to run a script that can send a trap.
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
nagwindmon
Posts: 92
Joined: Mon Dec 01, 2014 3:39 pm

Re: Nagios to monitor Event Queue on Web Server

Post by nagwindmon »

abrist,
that would be custom build API exposing certain fields for Client app to fill in case there is an error.

thanks!
Last edited by nagwindmon on Mon Feb 16, 2015 6:10 pm, edited 1 time in total.
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: Nagios to monitor Event Queue on Web Server

Post by abrist »

You could pull from the nagios logs, but do understand that the nagios logs can be *extremely* noisy on large installs. An event handler/check_http would have less impact, but it sounds like you would have to build an api to do that. What would you be looking for in the nagios.log?
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
nagwindmon
Posts: 92
Joined: Mon Dec 01, 2014 3:39 pm

Re: Nagios to monitor Event Queue on Web Server

Post by nagwindmon »

abrist wrote:You could pull from the nagios logs, but do understand that the nagios logs can be *extremely* noisy on large installs. An event handler/check_http would have less impact, but it sounds like you would have to build an api to do that. What would you be looking for in the nagios.log?
no, no, Im not talking about Nagios log files, let me give you an example: customer app experiencing error and reporting it to my Web Sever by utilizing one of my APIs, so now Web server has error info and I need to pass it to Nagios server for alerting. So what would be a best way to establish communication to pass data between my Web server and Nagios one?
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: Nagios to monitor Event Queue on Web Server

Post by Box293 »

This could be done in one of two ways.

Active:
Nagios queries the web server to check the queue
This could be via check_nrpe, check_by_ssh or create your own plugin that talks to your web server.
Nagios is hence the "owner" of the check and it is checked every x minutes etc

Passive:
The web server itself sends passive check information when required
This could be via NSCA, NRDP or SNMP Traps
The web server is responsible for sending passive check results to Nagios

Let us know if you need further information on these methods.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
nagwindmon
Posts: 92
Joined: Mon Dec 01, 2014 3:39 pm

Re: Nagios to monitor Event Queue on Web Server

Post by nagwindmon »

Box293 wrote:This could be done in one of two ways.
Passive:
The web server itself sends passive check information when required
This could be via NSCA, NRDP or SNMP Traps
The web server is responsible for sending passive check results to Nagios

Let us know if you need further information on these methods.
thank you Box! That's what I was looking for: Passive mode, can I have more info on this method please?
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: Nagios to monitor Event Queue on Web Server

Post by Box293 »

Here is a guide on NRDP:
http://assets.nagios.com/downloads/nagi ... erview.pdf

Here's some guides on NSCA:
http://assets.nagios.com/downloads/nagi ... ios-XI.pdf
http://sites.box293.com/nagios/guides/nsca

Have a read of this material and get back to us with any more questions.

SNMP Traps ... lets cross this bridge if you want to go over it as it can get pretty complicated.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Locked