Page 1 of 1

Windows 2019 Server OS Check

Posted: Mon Jun 08, 2020 4:42 pm
by kwhogster
Hello
Using Nagios 4.3.4 Core
I have many VM's running Using NSCLIENT 5.2.35
My OS Levels are Windows 10 , Windows 2012 R2, Windows 2016 and Windows 2019.

I have a check

Code: Select all

define service {
        host_name               SERV030
        service_description     Check OS Version
        check_command           check_nrpe!Check_OS_Version! -a "perf-config=*(ignored:true)"
        servicegroups           OSVersion
        check_interval          10080
        notification_interval   10080
        check_period            backup_WIN19
        notification_period     backup_WIN19
        use                     generic-service
        }
On all my computers this checks reports the correct OS except for the Windows 2019 Server it reports them as 2016 Servers.

I posted on the NSClient forum but I have yet to receive a response.

I have sent emails to the author and have not heard back.

I look on the nsclient site and files are dated back in 2018 and I see no information or updates in 2019 or 2020.

Is any one else having this same issue?

Also been thinking of trying Nagios ncpa agent any one have any experience with NCPA? Do my existing NRPE checks work with NCPA?

Thank you

Tom

Re: Windows 2019 Server OS Check

Posted: Tue Jun 09, 2020 4:49 pm
by kwhogster
Guys,

I wrote a PowerShell script to get the OS Version of the computer.

Changed my check to use the PowerShell script and now it reports the correct OS Version.

If anyone would like a copy of the script let me know.

This issue can be locked as self resolved.

Thank you

Tom

Re: Windows 2019 Server OS Check

Posted: Wed Jun 10, 2020 9:43 am
by scottwilkerson
kwhogster wrote:Guys,

I wrote a PowerShell script to get the OS Version of the computer.

Changed my check to use the PowerShell script and now it reports the correct OS Version.

If anyone would like a copy of the script let me know.

This issue can be locked as self resolved.

Thank you

Tom
Ok, Marking resolved and locking. It would be great if you could add the script to the community exchange
https://exchange.nagios.org/