Page 1 of 1

Nagios WSUS Check

Posted: Tue Feb 02, 2016 8:44 am
by HaschkeD
Hello,
we have included the following WSUS plugin in Nagios:
https://outsideit.net/check-ms-win-updates/

A PS script checks some Reg Keys .....
On some servers, we get the following messages in Nagios:
Install key not found in the registry. This server which probably never updated or your Custom WSUS update solution does not create this key.

The script checks this Key:

HKLM: \ SOFTWARE \ Microsoft \ Windows \ CurrentVersion \ WindowsUpdate \ AutoUpdate \ Results \ Install


On the systems where these messages come the key does not exist. If i check for new updates on my WSUS there are no ones
If i check online for update the are some updates....if i install These then the key exiists and all is fine.
But why is the key missing when i search my wsus for updates?

Greeting
Dennis

Re: Nagios WSUS Check

Posted: Tue Feb 02, 2016 10:59 am
by rkennedy
What version of Windows are the machines running that you get the error? I imagine the key location may have changed based on version.

Tagging @WillemDH as it's his script too.

Re: Nagios WSUS Check

Posted: Wed Feb 03, 2016 5:29 am
by HaschkeD
Server 2008 R2 and Server 2012 R2 (x64).

But if i do an online update and install all updates the key is creating and all works fine.

Re: Nagios WSUS Check

Posted: Wed Feb 03, 2016 11:10 am
by rkennedy
Ah - I missed the part where you mentioned it's working normally, but not with WSUS.

Are both the 2008 R2 and 2012 R2 machine behaving this way, or is one working?

Re: Nagios WSUS Check

Posted: Thu Feb 04, 2016 3:12 am
by HaschkeD
Yes, both OS have the same problem, but not all machines.........
Some working with WSUS and the key exists.

Re: Nagios WSUS Check

Posted: Thu Feb 04, 2016 5:46 pm
by hsmith
It sounds like it's something finnicky with the way that Windows handles this. I'm trying to look around, but I'm not finding too much information. I don't want to send you away, as we try to help with everything we can, but it's looking like this question would be better answered on the Microsoft website.

Re: Nagios WSUS Check

Posted: Fri Feb 05, 2016 6:11 am
by HaschkeD
OK, yes, i posted this in the MS TechNet Forum, but i can't get an answer......

Re: Nagios WSUS Check

Posted: Fri Feb 05, 2016 12:11 pm
by hsmith
We primarily deal with Linux at our company, so we don't have a ton of great answers when it comes to Windows questions. You can reach out to the author of this script, but be warned that he is not under any sort of obligation to respond.

Re: Nagios WSUS Check

Posted: Wed Apr 20, 2016 2:34 pm
by WillemDH
For me servers updated with WSUS have that key. Except Windows 10 and Server 16, where MS has decided to no longer use that case. The last version of the plugin has an alternate way to detect the last update installation date, but it needs the PSWindowsUpdate PS module. Check my GitHub.
Add -M PSWindowsUpdate as an argument and the script will try to use PSWindowsUpdate. Make sure it's installed... Let us know if you get it working.

Re: Nagios WSUS Check

Posted: Wed Apr 20, 2016 4:57 pm
by hsmith
Thanks for the update, Willem. :)