Services returning unknown on windows server 2012

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
SaltyBear
Posts: 20
Joined: Mon Apr 25, 2016 6:32 am

Services returning unknown on windows server 2012

Post by SaltyBear »

Hi

First i'd like to tell you that this is part of a school assignment where I'm studying to be a network engineer so excuse me if I don't understand any terms you might use to help me.

So basic setup is this:
LAN A:
4 servers 3x windows server 2012, 1x windows 7 client, 1 FW and 1 Nagios monitoring server on ubuntu 14.04
http://imgur.com/a/WFBxC

I am currently succesfully monitoring the windows client and the firewall as the screenshot will show
But both of 2 windows server 2012's give me the same "UNKNOWN" output for CPU Load, Disk space and explorer.exe checks.
As these are properly monitored on the client, I already eliminated the fact that it would be a problem with the plugins themselves.
Does anyone here have an idea why my 2012 servers are both failing to return any statusses for these 3 monitoring services?

Please do ask any further info you might need, I hope the screenshots I have provided will be of help to you.

Thanks.
User avatar
hsmith
Agent Smith
Posts: 3539
Joined: Thu Jul 30, 2015 11:09 am
Location: 127.0.0.1
Contact:

Re: Services returning unknown on windows server 2012

Post by hsmith »

Any logs in C:\Program Files\NSClient++ that may be helpful?
Former Nagios Employee.
me.
rkennedy
Posts: 6579
Joined: Mon Oct 05, 2015 11:45 am

Re: Services returning unknown on windows server 2012

Post by rkennedy »

Also, can you post the service definitions for the ones that are failing?
Former Nagios Employee
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: Services returning unknown on windows server 2012

Post by Box293 »

For one of the checks that is not working, what output do you get when you test at the command line?

Code: Select all

check_nt -H 192.168.60.2 -p 12489 -v USEDDISKSPACE -l c -w 80 -c 90
or

Code: Select all

check_nt -H 192.168.60.2 -v USEDDISKSPACE -l c -w 80 -c 90
It would be good to see your check_nt command definition.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
SaltyBear
Posts: 20
Joined: Mon Apr 25, 2016 6:32 am

Re: Services returning unknown on windows server 2012

Post by SaltyBear »

This is how I have my check_nt command defined

Code: Select all

define command{
        command_name check_nrpe
        command_line $USER1$/check_nrpe -H $HOSTADDRESS$ -c $ARG1$
}
And the service definitions I added in the screenshots I provided, the testclient (Win 7 client) is the one where everything works, the other 2 return me a UNKNOWN error on CPU Load, Disk space on C and Explorer.

This is what I get in the details menu for one of the UNKNOWN values.
http://imgur.com/noOX0Eu
User avatar
nozlaf
Posts: 172
Joined: Sun Nov 09, 2014 9:50 pm
Location: Victoria, Australia

Re: Services returning unknown on windows server 2012

Post by nozlaf »

couple of things jump out

testclient - is this your windows 7 machine? its running a much older version of nsclient than the two which have failed

you mention 3 windows servers and 1 windows 7 client but have only shown three things being monitored, is one of your 2012 servers working? if so can you confirm the nsclient version for it?

when you installed nsclient++ on the servers did you do it the same for all three?
Looking forward to seeing you all at #NagiosCon2019?
-Dedicated Lover of Nconf,PNP4Nagios and Nagvis
SaltyBear
Posts: 20
Joined: Mon Apr 25, 2016 6:32 am

Re: Services returning unknown on windows server 2012

Post by SaltyBear »

nozlaf wrote:couple of things jump out

testclient - is this your windows 7 machine? its running a much older version of nsclient than the two which have failed

you mention 3 windows servers and 1 windows 7 client but have only shown three things being monitored, is one of your 2012 servers working? if so can you confirm the nsclient version for it?

when you installed nsclient++ on the servers did you do it the same for all three?
Testclient is indeed the windows 7 client, and I currently only installed nagios on 2 of the 3 windows 2012 servers, that is why 1 is missing.
I never noticed testclient is using an older version, as I did them all on the same day I don't understand how this could've happened.
And I did install them the same way, using the GUI installer I got from the official website and then adding them to my ubuntu 14.04 nagios server.
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: Services returning unknown on windows server 2012

Post by Box293 »

SaltyBear wrote:This is how I have my check_nt command defined

Code: Select all

define command{
        command_name check_nrpe
        command_line $USER1$/check_nrpe -H $HOSTADDRESS$ -c $ARG1$
}
And the service definitions I added in the screenshots I provided, the testclient (Win 7 client) is the one where everything works, the other 2 return me a UNKNOWN error on CPU Load, Disk space on C and Explorer.

This is what I get in the details menu for one of the UNKNOWN values.
http://imgur.com/noOX0Eu
This is your check_nrpe command definition, not your check_nt command definition. Can you please post your check_nt command definition.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
SaltyBear
Posts: 20
Joined: Mon Apr 25, 2016 6:32 am

Re: Services returning unknown on windows server 2012

Post by SaltyBear »

Whoops I'm sorry

Code: Select all

define command{
command_name check_nt
command_line $USER1$/check_nt -H $HOSTADDRESS$ -p 12489 -s Azerty1. -v $ARG1$ $ARG2$
}
Azerty1. being the password I put on the nsclient++ on the client/servers

Edit:
I added an ubuntu host and here the same services also return an unknown status but with the following error which the windows servers do not give
"Check_nt: could not parse arguments"
User avatar
tgriep
Madmin
Posts: 9177
Joined: Thu Oct 30, 2014 9:02 am

Re: Services returning unknown on windows server 2012

Post by tgriep »

It is hard to see your screen captures but it looks like some of the service definitions are using a number 1 instead of a lower case l
Take a look at that and see if that is the case, if so change the 1 to a l and that should fix it for you.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked