Windows Activation Monitoring
-
kalyanpabolu
- Posts: 246
- Joined: Fri Jul 03, 2020 4:18 am
Windows Activation Monitoring
Hi Team,
Can we monitor Windows Activation using Nagios XI?
We recently faced issue where Windows was not activated on a machine and that created a big problem.
Is there a way in Nagios where we can get alert for Windows systems if in case Windows is not activated for them.
Please suggest.
Thanks in advance!!
Can we monitor Windows Activation using Nagios XI?
We recently faced issue where Windows was not activated on a machine and that created a big problem.
Is there a way in Nagios where we can get alert for Windows systems if in case Windows is not activated for them.
Please suggest.
Thanks in advance!!
Re: Windows Activation Monitoring
Hi,
How are you doing?
I would suggest that you write your own plugin, then calls it using "check_ncpa.py".
Here's an example. Please NOTE I'm not a PowerShell programmer, so you will have to modify or add more to the example below:
Outputs:
If your output of "LicenseStatus" is "1" as above, then your system is activated.
Best Regards,
Vinh
How are you doing?
I would suggest that you write your own plugin, then calls it using "check_ncpa.py".
Here's an example. Please NOTE I'm not a PowerShell programmer, so you will have to modify or add more to the example below:
Code: Select all
(Get-CimInstance SoftwareLicensingProduct -Filter "Name like 'Windows%'" | where { $_.PartialProductKey } | select Description, LicenseStatus)
Code: Select all
Description LicenseStatus
----------- -------------
Windows(R) Operating System, OEM_DM channel 1
Best Regards,
Vinh
Re: Windows Activation Monitoring
Also, please NOTE that the provided PS example command seems to take a few seconds to run, so you might have to set bigger for "timeout".
Vinh
Vinh
-
kalyanpabolu
- Posts: 246
- Joined: Fri Jul 03, 2020 4:18 am
Re: Windows Activation Monitoring
Hello,
thanks for your inputs.
We are not willing to place any script on windows machine.
Is that possible to check it using a shell script or say plugin from Nagios server?
thanks for your inputs.
We are not willing to place any script on windows machine.
Is that possible to check it using a shell script or say plugin from Nagios server?
Re: Windows Activation Monitoring
Hi @kalyanpabolu,
Hope you are having a good day!!
I'm very sorry, but Nagios do not have any module that will check for Windows license activation.
I was suggested as a way to get that in my previous replied but you must come up with your own PowerShell script.
Best Regards,
Vinh
Hope you are having a good day!!
I'm very sorry, but Nagios do not have any module that will check for Windows license activation.
I was suggested as a way to get that in my previous replied but you must come up with your own PowerShell script.
Best Regards,
Vinh
-
kalyanpabolu
- Posts: 246
- Joined: Fri Jul 03, 2020 4:18 am
Re: Windows Activation Monitoring
Hello,
We have run the command "slmgr.vbs -xpr" in one of the servers and we got the pop-up(PFA) in which its is showing volume activation expiration date. Please let us know how we can monitor this pop-up result through Nagios.
We have run the command "slmgr.vbs -xpr" in one of the servers and we got the pop-up(PFA) in which its is showing volume activation expiration date. Please let us know how we can monitor this pop-up result through Nagios.
You do not have the required permissions to view the files attached to this post.
Re: Windows Activation Monitoring
This should be the same process:
https://support.nagios.com/forum/viewto ... 671#p39671
What does this output?
https://support.nagios.com/forum/viewto ... 671#p39671
What does this output?
Code: Select all
cscript //NoLogo c:\windows\system32\slmgr.vbs -xpr | find "expire"-
kalyanpabolu
- Posts: 246
- Joined: Fri Jul 03, 2020 4:18 am
Re: Windows Activation Monitoring
Hello,
Thank you for your reply!!
Please find attached output of the command you gave. Actually we don't have NSClient++ installed on our machines. Can we monitor this with NCPA?
Thank you for your reply!!
Please find attached output of the command you gave. Actually we don't have NSClient++ installed on our machines. Can we monitor this with NCPA?
You do not have the required permissions to view the files attached to this post.
Re: Windows Activation Monitoring
Hi,
Yes, you can us NCPA.
Create a bat file let call it "check_license.bat" and put that under NCPA's plugins folder:
"C:\Program Files (x86)\Nagios\NCPA\plugins\"
Now, open a command prompt from your Nagios XI and run:
Regards,
Vinh
Yes, you can us NCPA.
Create a bat file let call it "check_license.bat" and put that under NCPA's plugins folder:
"C:\Program Files (x86)\Nagios\NCPA\plugins\"
Now, open a command prompt from your Nagios XI and run:
Code: Select all
/usr/local/nagios/libexec/check_ncpa.py -H x.x.x.x -t 'yourNCPAtoken' -M 'plugins/check_license.bat'
Regards,
Vinh
-
kalyanpabolu
- Posts: 246
- Joined: Fri Jul 03, 2020 4:18 am
Re: Windows Activation Monitoring
Hello,
Thank you!!! it is working. We have tested it one of the our machine and it is working fine(PFA).
Can you please help me to monitor this activation date, show it Critical and Warning in Nagios and send an alert when license is about to expire in 30 and 60 days respectively ?
Thanks in advance.
Thank you!!! it is working. We have tested it one of the our machine and it is working fine(PFA).
Can you please help me to monitor this activation date, show it Critical and Warning in Nagios and send an alert when license is about to expire in 30 and 60 days respectively ?
Thanks in advance.
You do not have the required permissions to view the files attached to this post.