Check_tasksched Critical Not Found

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
kwhogster
Posts: 644
Joined: Wed Oct 14, 2015 6:51 pm
Location: Wood Ridge NJ USA
Contact:

Check_tasksched Critical Not Found

Post by kwhogster »

Nagios 4.3.4
Nsclient 4.2.3
Windows 2016 DC servers
Exchange 2016 CU10 DAG 2 Node2

So I have two Servers running Exchange and they both have the same scheduled tasks

The check fails Critical Exchange Journal NOT FOUND

I ran from command line with same result.

From Node 2 it fails

Code: Select all

root@serv017:/usr/local/nagios/etc/objects/windowsservers# /usr/lib/nagios/plugins/check_nrpe -t 50 -H SERV021-N2 -c check_tasksched -a "filter=title eq 'Exchange Journal'" 'critical=most_recent_run_time < -1w' empty-state=critical 'empty-syntax=CRITICAL: Exchange Journal NOT found' 'detail-syntax=${title} is stale more than -1w'
CRITICAL: Exchange Journal NOT found

From Node 1 it works.

root@serv017:/usr/local/nagios/etc/objects/windowsservers# /usr/lib/nagios/plugins/check_nrpe -t 50 -H SERV021-N1 -c check_tasksched -a "filter=title eq 'Exchange Journal'" 'critical=most_recent_run_time < -1w' empty-state=critical 'empty-syntax=CRITICAL: Exchange Journal NOT found' 'detail-syntax=${title} is stale more than -1w'
: All tasks are ok|'Exchange Journal_exit_code'=0;0;0 'Exchange Journal_most_recent_run_time'=1539637200;0;1539044570
I attached some images.

The attachment Exchange Journal Task.PNG is no longer available
Powershell view
Powershell view
the task
the task
Exchange Journal Task.PNG (4.91 KiB) Viewed 2595 times


I deleted the task and recreated it no luck

Any ideas

Thank you

Tom
User avatar
tgriep
Madmin
Posts: 9177
Joined: Thu Oct 30, 2014 9:02 am

Re: Check_tasksched Critical Not Found

Post by tgriep »

Can you post your nsclient.ini file from both servers so we can check to see if there are any differences?
Do you see and errors in the nsclient.log file when you are polling the server that is generating the error?
Be sure to check out our Knowledgebase for helpful articles and solutions!
User avatar
cdienger
Support Tech
Posts: 5045
Joined: Tue Feb 07, 2017 11:26 am

Re: Check_tasksched Critical Not Found

Post by cdienger »

I'm not sure how nsclient++ finds the scheduled jobs so it may be more fruitful to pose this to their forums, but make sure that the module is installed and enabled first. On my nsclient++ machine this required running "nscp settings --activate-module CheckTaskSched --add-default" in the c:\program files\nsclient++ directory. Once that was installed and enabled I could see scheduled tasks by running "nscp test" and then "check_tasksched" in the nsclient++ directory.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
kwhogster
Posts: 644
Joined: Wed Oct 14, 2015 6:51 pm
Location: Wood Ridge NJ USA
Contact:

Re: Check_tasksched Critical Not Found

Post by kwhogster »

To CDienger,

Ran the command and still no change I even restarted the NSCP service and ran the check.


TGriep

I am attaching both nsclient.ini for your review.
nsclientnode1.txt
NODE 1 that works
(23.27 KiB) Downloaded 263 times
nsclientnode1.txt
NODE 1 that works
(23.27 KiB) Downloaded 263 times

Thanks to both HTH

Tom
Attachments
nsclientnode2.txt
NODE 2 DOES NOT WORK
(23.27 KiB) Downloaded 239 times
User avatar
cdienger
Support Tech
Posts: 5045
Joined: Tue Feb 07, 2017 11:26 am

Re: Check_tasksched Critical Not Found

Post by cdienger »

The configurations are identical in all the meaningful ways.

To clarify - running "nscp test" and then "check_tasksched" in the nsclient++ directory didn't show the job? If so, then it sounds like something with the nsclient++ module. https://exchange.nagios.org/directory/P ... ks/details looks like it could be an alternative.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
kwhogster
Posts: 644
Joined: Wed Oct 14, 2015 6:51 pm
Location: Wood Ridge NJ USA
Contact:

Re: Check_tasksched Critical Not Found

Post by kwhogster »

Guys

Sorry I did not express this before.

On Both NODES I have Several Task Scheduler checks which all work fine

It is just this one task scheduler check

Any thoughts?
kwhogster
Posts: 644
Joined: Wed Oct 14, 2015 6:51 pm
Location: Wood Ridge NJ USA
Contact:

Re: Check_tasksched Critical Not Found

Post by kwhogster »

Guys

Update.

Problem was on the Schedule Task on the Windows 2016 Server

It was marked as hidden unchecked the box and like that the check is now working.


Please Lock this as resolved.

Thank you for all the help
User avatar
cdienger
Support Tech
Posts: 5045
Joined: Tue Feb 07, 2017 11:26 am

Re: Check_tasksched Critical Not Found

Post by cdienger »

Glad to hear you were able to resolve it and thanks for posting the solution! :)
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Locked