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.
check_command check_nrpe!check_iis_conn!-a 'TGCS014-N1' 'Default Web Site' '5' '9'
same results
Current Status:
OK
(for 1d 5h 46m 39s)
Status Information: C:Program FilesNSClient++scriptspowershellcheck_iis_connections.ps1 :
Cannot process argument transformation on parameter 'warning_value'. Cannot
convert value "$" to type "System.Int32". Error: "Input string was not in a
correct format."
At line:1 char:66
+ ... ershell\\check_iis_connections.ps1 "$ARG1$" "$ARG2$" "$ARG3$" "$ARG4$ ...
+ ~~~~~~~~
+ CategoryInfo : InvalidData: (:) [check_iis_connections.ps1], Pa
rameterBindingArgumentTransformationException
+ FullyQualifiedErrorId : ParameterArgumentTransformationError,check_iis_c
onnections.ps1
Performance Data:
Current Attempt: 1/10 (HARD state)
Last Check Time: 06-08-2018 21:52:10
Check Type: ACTIVE
Check Latency / Duration: 0.000 / 0.801 seconds
Next Scheduled Check: 06-08-2018 22:52:10
Last State Change: 06-07-2018 16:52:10
Last Notification: N/A (notification 0)
Is This Service Flapping?
NO
(0.00% state change)
In Scheduled Downtime?
NO
Last Update: 06-08-2018 22:38:46 ( 0d 0h 0m 3s ago)
This is so strange this same check work on several other servers just not this one even NODE2 in the cluster the same check works
Thanks for trying willing to try anything here.
OOOPS
Update
Now it went to Unknown
Current Status:
UNKNOWN
(for 0d 0h 12m 57s)
Status Information: Get-Counter : Unable to access the desired computer or service. Check the
permissions and authentication of the log service or the interactive user
session against those on the computer or service being monitored.
At C:\Program Files\NSClient++\scripts\powershell\check_iis_connections.ps1:40
char:12
+ $counter = Get-Counter "\\$server\Web Service($website)\Current Conne ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidResult: (:) [Get-Counter], Exception
+ FullyQualifiedErrorId : CounterApiError,Microsoft.PowerShell.Commands.Ge
tCounterCommand
CONNECTIONS UNKNOWN Default Web Site not found
Performance Data:
Current Attempt: 10/10 (HARD state)
Last Check Time: 06-08-2018 23:00:56
Check Type: ACTIVE
Check Latency / Duration: 0.000 / 1.995 seconds
Next Scheduled Check: 06-09-2018 00:00:56
Last State Change: 06-08-2018 22:52:10
Last Notification: N/A (notification 0)
Is This Service Flapping?
NO
(6.25% state change)
In Scheduled Downtime?
NO
Last Update: 06-08-2018 23:05:06 ( 0d 0h 0m 1s ago)
check_command check_nrpe!check_iis_conn!-a 'TGCS014-N1 "Default Web Site" 5 9'
This will send over all of the separate arguments as one argument.
Restart nagios and test the command.
If you get an error, post the nsclient.ini file and the nsclient.log file from the Windows system as well as the command definition from the Nagios server.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Save the nsclient.ini file and restart the NSClient++ service.
Check the log file for the unknown command errors and if they are not found, test it and post any errors here.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Made the changes and the same results does not report back correct information
the logfile was small here it is
2018-05-30 18:26:00: error:c:\source\nscp\modules\NRPEServer\NRPEServer.cpp:132: CA not found: C:\Program Files\NSClient++/security/ca.pem (generating a default CA)
2018-05-30 18:26:00: error:c:\source\nscp\modules\WEBServer\WEBServer.cpp:642: Certificate not found: C:\Program Files\NSClient++/security/certificate.pem (generating a default certificate)
2018-05-30 18:31:00: error:c:\source\nscp\service\NSClient++.cpp:216: Failed to register plugin LUAScript: Could not load library: 126: The specified module could not be found.
: LUAScript.dll
2018-05-30 19:28:55: error:c:\source\nscp\service\NSClient++.cpp:216: Failed to register plugin LUAScript: Could not load library: 126: The specified module could not be found.
: LUAScript.dll
2018-05-30 19:31:19: error:c:\source\nscp\service\NSClient++.cpp:216: Failed to register plugin LUAScript: Could not load library: 126: The specified module could not be found.
: LUAScript.dll
2018-05-30 21:30:27: error:c:\source\nscp\service\NSClient++.cpp:484: Module (LUAScript.dll) was not found: Could not load library: 126: The specified module could not be found.
: LUAScript.dll
2018-05-30 21:31:40: error:c:\source\nscp\service\NSClient++.cpp:427: Failed to load C:\Program Files\NSClient++/modules\LUAScript.dll: Could not load library: 126: The specified module could not be found.
: LUAScript.dll
2018-05-30 21:31:40: error:c:\source\nscp\service\NSClient++.cpp:484: Module (LUAScript.dll) was not found: Could not load library: 126: The specified module could not be found.
: LUAScript.dll
2018-06-02 12:32:47: error:c:\source\nscp\service\NSClient++.cpp:427: Failed to load C:\Program Files\NSClient++/modules\LUAScript.dll: Could not load library: 126: The specified module could not be found.
: LUAScript.dll
2018-06-05 20:02:32: error:c:\source\nscp\service\NSClient++.cpp:427: Failed to load C:\Program Files\NSClient++/modules\LUAScript.dll: Could not load library: 126: The specified module could not be found.
: LUAScript.dll
2018-06-06 16:45:17: error:c:\source\nscp\service\NSClient++.cpp:427: Failed to load C:\Program Files\NSClient++/modules\LUAScript.dll: Could not load library: 126: The specified module could not be found.
: LUAScript.dll
2018-06-07 17:15:54: error:c:\source\nscp\service\NSClient++.cpp:427: Failed to load C:\Program Files\NSClient++/modules\LUAScript.dll: Could not load library: 126: The specified module could not be found.
You would have to ask the author of the NSClient++ agent on why it is not loading.
On my Windows system, I do not load that DLL and the external and alias commands load and run.
It almost looks like that entry did not get removed or that the agent did not get restarted.
Be sure to check out our Knowledgebase for helpful articles and solutions!
What versions of NSCLient++ are installed on a working server vs the non working one?
If the versions are close, copy the nsclient.ini file from the working one to the non working one and restart the NSClient++ agent.
Be sure to check out our Knowledgebase for helpful articles and solutions!