Check windows time is not listed as a service on nagios gui

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.
Locked
Morello
Posts: 7
Joined: Tue Sep 20, 2016 7:23 am

Check windows time is not listed as a service on nagios gui

Post by Morello »

Hi all,

I used the script below in order to add nagios windows clients ntp check.

https://exchange.nagios.org/directory/P ... 29/details

This script seems to be working okaywhen i check like this from nagios server:
[root@server~]# /usr/lib64/nagios/plugins/check_nrpe -H host -c check_windows_time
OK: Time is -00.5094249s from pool.ntp.org|'Offset'=0s;30;10;0

But i can not see check_time listed as a service on nagios server when i opened up the gui however i should be able to see it as listed services I can only see modules like checkdisk, currentload, check, checkservice, checkprocess etc these are all listed under modules and set to 1 in nsclient.ini file. Any ideas why i can not see the newly added script as a new service on nagios gui? Please see img attached for listed services... Thanks for any help or assistance. Regards, Utku

Here is my nsclient.ini file.

Code: Select all

# If you want to fill this file with all avalible options run the following command:
#   nscp settings --generate --add-defaults --load-all
# If you want to activate a module and bring in all its options use:
#   nscp settings --activate-module <MODULE NAME> --add-defaults
# For details run: nscp settings --help


; Undocumented section
[/settings/default]

; Undocumented key
password = XXXXX

; Undocumented key
allowed hosts = 127.0.0.1,::1

; Undocumented section
[/settings/NRPE/server]
allow arguments = 1
allow nasty characters = 1
allowed hosts = 1.2.3.4
port = XXXX
use SSL = 1

; Undocumented key
verify mode = none

; Undocumented key
insecure = true


; Undocumented section
[/modules]

; Undocumented key
CheckExternalScripts = 1

; Undocumented key
CheckHelpers = 1

; Undocumented key
CheckEventLog = 1

; Undocumented key
CheckNSCP = 1

; Undocumented key
CheckDisk = 1

; Undocumented key
CheckSystem = 1

; Undocumented key
NRPEServer = 1

[/settings/external scripts/wrapped scripts]

; check_windows_time
check_windows_time = check_windows_time.bat pool.ntp.org 30 10
Attachments
nagios.JPG
rkennedy
Posts: 6579
Joined: Mon Oct 05, 2015 11:45 am

Re: Check windows time is not listed as a service on nagios

Post by rkennedy »

You more than likely just need to create a service that is for the check_windows_time check.

For the check command, I believe it would just be -

Code: Select all

   check_command        check_nrpe!check_windows_time
If that doesn't help please post the full configuration file which houses the other services.
Former Nagios Employee
Morello
Posts: 7
Joined: Tue Sep 20, 2016 7:23 am

Re: Check windows time is not listed as a service on nagios

Post by Morello »

Hi,

You mean creating a service by configuring windows.cfg on nagios server?
I did not enable monitoring windows host on nagios server, i am just trying to add this check on all nsclient windows hosts like the other checks you have seen on the picture.
Can you help me out how to get my service shown on nagios server like the other services?
What configuration file you needed?

BR,
Morello
Posts: 7
Joined: Tue Sep 20, 2016 7:23 am

Re: Check windows time is not listed as a service on nagios

Post by Morello »

Never mind, i got this working... Just forgot to add the service on nagios server.

Many thanks...
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: Check windows time is not listed as a service on nagios

Post by tmcdonald »

Great to hear :) I'll be closing this thread now, but feel free to open another if you need anything in the future!
Former Nagios employee
Locked