NCPA Windows Service Monitoring with regex Filtering

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
onegative
Posts: 175
Joined: Tue Feb 17, 2015 12:06 pm

NCPA Windows Service Monitoring with regex Filtering

Post by onegative »

G 'Day Nagios Support,

So I have recently discovered that if you attempt to monitor Windows Services using a regex Filter services that are disabled within Windows are still identified and alarmed upon...this really makes the regex Filter useless when trying to monitor something like MSSQL services because those services are not always utilized together.

Case in point...since the services SQLSERVERAGENT and SQLBrowser are Disabled, they should be dropped from the regex Filter before processing for Status. Otherwise what good is using the regex Filter unless all matching services are running even though you do not want them to be. This really should have been caught in QA from the beginning of the release. Looking at the recent ChangeLog for versions 2.1.7, 2.1.8 and/or 2.1.9 there is no mention of this fix being addressed. Please test my assertion to verify my findings and then please submit a bugfix for Jake if you confirm.

Many Thanks,
Danny

NCPA AGENT VERSION
ncpa_version.png
Windows Service Configuration
service_configuration.png
Run as Nagios Check in API
service_api_endpoint.png
You do not have the required permissions to view the files attached to this post.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: NCPA Windows Service Monitoring with regex Filtering

Post by lmiltchev »

This is not a bug... NCPA checks if ALL of the services that match the regex query are running. If some if them are NOT running, you would get a non-ok state, regardless of whether they are disabled or stopped. You could add a feature request for removing disabled services from the query here:

https://github.com/NagiosEnterprises/ncpa/issues

As a "workaround", you could search for SQLWriter and MSSQLSERVER in the service filters with exact match.

Hope this helps.
Be sure to check out our Knowledgebase for helpful articles and solutions!
onegative
Posts: 175
Joined: Tue Feb 17, 2015 12:06 pm

Re: NCPA Windows Service Monitoring with regex Filtering

Post by onegative »

I understand that I can specify each and every service independently...that is not my problem.

Using a regex filter allows for less work...but not filtering out Disable Services completely breaks the point of having the regex option in the first place.

I DO NOT agree with your assessment, and I think if the developers really think about it they would agree with my thinking...

Anyway, you can lock this thread.

And as always thanks for your help,
Danny
jomann
Development Lead
Posts: 611
Joined: Mon Apr 22, 2013 10:06 am
Location: Nagios Enterprises

Re: NCPA Windows Service Monitoring with regex Filtering

Post by jomann »

I understand your argument here but the reason that we allow showing all the services (including those disabled) is in order for people to monitor services that are disabled and may be enabled by someone, etc. This just makes sense that we list them all by default. I've added an issue you can follow here: https://github.com/NagiosEnterprises/ncpa/issues/593 on github as a feature/enhancement to allow checks to specifically not show disabled services.

I'll go ahead and lock the thread.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Locked