UNKNOWN: Error occurred while running the plugin. Use the ve

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
vasilij
Posts: 3
Joined: Wed Mar 06, 2019 7:54 am

UNKNOWN: Error occurred while running the plugin. Use the ve

Post by vasilij »

Hi,

Nagios Agent on Windows7 return an error:
UNKNOWN: Error occurred while running the plugin. Use the verbose flag for more details.
I have that error only with Process Count. CPU Usage and Memory Usage working as well.
Image
NCPA client version is 2.1.6
check_ncpa.py plugin version is 1.1.5
Firewall is also turned off on client PC

Can you help me?

Thanks
Last edited by vasilij on Fri Apr 12, 2019 2:54 am, edited 1 time in total.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: UNKNOWN: Error occurred while running the plugin. Use th

Post by scottwilkerson »

Can you show what command is being run?

Have you tried running the command from the CLI?
Former Nagios employee
Creator:
ahumandesign.com
enneagrams.com
vasilij
Posts: 3
Joined: Wed Mar 06, 2019 7:54 am

Re: UNKNOWN: Error occurred while running the plugin. Use th

Post by vasilij »

HI Scott,

Thanks for fast answer.
Yeap, I have tried:
Image
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: UNKNOWN: Error occurred while running the plugin. Use th

Post by scottwilkerson »

Can you run this from the CLI and show the output

Code: Select all

curl -k "https://172.16.6.56:5693/api/processes?check=true&warning=150&critical=200&token=hibike" -vvv
Also can you attach your ncpa.cfg from the client server, also the logs from

Code: Select all

C:\Program Files (x86)\Nagios\NCPA\var\log
Former Nagios employee
Creator:
ahumandesign.com
enneagrams.com
vasilij
Posts: 3
Joined: Wed Mar 06, 2019 7:54 am

Re: UNKNOWN: Error occurred while running the plugin. Use th

Post by vasilij »

That's the output:

Code: Select all

 curl -k "https://172.16.6.56:5693/api/processes?check=true&warning=150&critical=200&token=hibike" -vvv
*   Trying 172.16.6.56...
* TCP_NODELAY set
* connect to 172.16.6.56 port 5693 failed: Verbindungsaufbau abgelehnt
* Failed to connect to 172.16.6.56 port 5693: Verbindungsaufbau abgelehnt
* Closing connection 0
curl: (7) Failed to connect to 172.16.6.56 port 5693: Verbindungsaufbau abgelehnt
itops@vsr19-003:~$ curl -k "https://172.16.6.56:5693/api/processes?check=true&warning=150&critical=200&token=hibike" -vvv
*   Trying 172.16.6.56...
* TCP_NODELAY set
* Connected to 172.16.6.56 (172.16.6.56) port 5693 (#0)
* ALPN, offering h2
* ALPN, offering http/1.1
* successfully set certificate verify locations:
*   CAfile: /etc/ssl/certs/ca-certificates.crt
  CApath: /etc/ssl/certs
* TLSv1.2 (OUT), TLS handshake, Client hello (1):
* TLSv1.2 (IN), TLS handshake, Server hello (2):
* TLSv1.2 (IN), TLS handshake, Certificate (11):
* TLSv1.2 (IN), TLS handshake, Server key exchange (12):
* TLSv1.2 (IN), TLS handshake, Server finished (14):
* TLSv1.2 (OUT), TLS handshake, Client key exchange (16):
* TLSv1.2 (OUT), TLS change cipher, Client hello (1):
* TLSv1.2 (OUT), TLS handshake, Finished (20):
* TLSv1.2 (IN), TLS handshake, Finished (20):
* SSL connection using TLSv1.2 / ECDHE-RSA-AES256-GCM-SHA384
* ALPN, server did not agree to a protocol
* Server certificate:
*  subject: C=US; ST=Minnesota; L=St. Paul; O=Nagios Enterprises, LLC; OU=Development; CN=PC14-015
*  start date: Apr 12 13:58:31 2019 GMT
*  expire date: Apr  9 13:58:31 2029 GMT
*  issuer: C=US; ST=Minnesota; L=St. Paul; O=Nagios Enterprises, LLC; OU=Development; CN=PC14-015
*  SSL certificate verify result: self signed certificate (18), continuing anyway.
> GET /api/processes?check=true&warning=150&critical=200&token=hibike HTTP/1.1
> Host: 172.16.6.56:5693
> User-Agent: curl/7.58.0
> Accept: */*
>
< HTTP/1.1 500 INTERNAL SERVER ERROR
< Content-Type: text/html; charset=utf-8
< Content-Length: 2225
< Date: Fri, 12 Apr 2019 13:59:55 GMT
<
<!DOCTYPE html>
<html lang='en'>
    <head>
        <title>Page Not Found · NCPA</title>
        <meta name="viewport" content="width=device-width, initial-scale=1.0">
        <meta name="description" content="NCPA Web Interface">
        <meta name="author" content="Nagios Enterprises, LLC">
        <link rel="shortcut icon" type="image/png" href="/static/img/ncpa.png" />
        <link rel="icon" type="image/png" href="/static/img/ncpa.png" />
        <link rel='stylesheet' href='/static/css/bootstrap.min.css'>
        <link rel='stylesheet' href='/static/css/font-awesome.min.css'>
        <link rel='stylesheet' href='/static/css/ncpa.css'>


        <script src='/static/js/jquery.2.2.4.min.js'></script>
        <script src='/static/js/bootstrap.min.js'></script>
        <script src='/static/js/d3.v4.min.js'></script>
        <script src='/static/js/main.js'></script>


    </head>
Attachments
win32service_ncpalistener.log
(65 Bytes) Downloaded 186 times
ncpa_listener.log
(2.49 KiB) Downloaded 204 times
ncpa.cfg
(7.91 KiB) Downloaded 209 times
User avatar
lmiltchev
Former Nagios Staff
Posts: 13587
Joined: Mon May 23, 2011 12:15 pm

Re: UNKNOWN: Error occurred while running the plugin. Use th

Post by lmiltchev »

I think the issue is caused by the non-ascii characters in the process name.
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc4 in position 363: ordinal not in range(128)
Our developers believe that when we switch to Python 3, we should no longer have this issue. For more information on the issue, see this:

https://github.com/NagiosEnterprises/ncpa/issues/439

https://github.com/NagiosEnterprises/ncpa/issues/509

https://github.com/NagiosEnterprises/ncpa/issues/499

You could probably try using some custom powershell script that gives you the desired output, and call it via NCPA.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked