Page 1 of 1

get more details about an error

Posted: Tue Oct 29, 2019 11:33 am
by Hoygen83
Hello,
I would like to understand what I'm doing wrong.
I have a windows host that is signaled as down.
I followed this guide https://assets.nagios.com/downloads/nag ... ndows.html
the check that's having problems is this one:
CPU Usage
This service has 1 comment associated with it This service is flapping between states
UNKNOWN 10-29-2019 16:27:12 0d 0h 0m 54s 1/5 Incorrect credentials given.

What credentials are given, from who and where?

Re: get more details about an error

Posted: Tue Oct 29, 2019 3:05 pm
by benjaminsmith
Hello,

Did you install and setup the NCPA agent on the Windows system. Do you have the correct password set in the check command in Nagios. Log into the terminal and try running the plugin directly from the shell. Post any errors to the thread. Thanks.

Code: Select all

cd /usr/local/nagios/libexec
check_ncpa.py -H 1<ipaddreess> -t 'password' -P 5693 -M cpu/percent -w 20 -c 40 -q 'aggregate=avg'

Re: get more details about an error

Posted: Wed Oct 30, 2019 9:02 am
by Hoygen83
benjaminsmith wrote:Hello,

Did you install and setup the NCPA agent on the Windows system. Do you have the correct password set in the check command in Nagios. Log into the terminal and try running the plugin directly from the shell. Post any errors to the thread. Thanks.

Code: Select all

cd /usr/local/nagios/libexec
check_ncpa.py -H 1<ipaddreess> -t 'password' -P 5693 -M cpu/percent -w 20 -c 40 -q 'aggregate=avg'
I'm sure I'm missing something.
I installed the ncpa agent version 2.2.0 on the windows machine.
During the installation, since I'm still testing the product I set up a token, I did not set up a bind ip because I don't know what it is, then I clicked next and next and next.

if I give this command:
check_ncpa.py -H 1<10.100.0.8> -t 'password' -P 5693 -M cpu/percent -w 20 -c 40 -q 'aggregate=avg'
I get
-bash: 10.100.0.8: No such file or directory

Now I have even more questions: what is the password and where (in what file on the host and on the nagios server) I define it?

Re: get more details about an error

Posted: Wed Oct 30, 2019 11:34 am
by scottwilkerson
Pardon my colleagues typo error. You would run

Code: Select all

./check_ncpa.py -H 10.100.0.8 -t 'password' -P 5693 -M cpu/percent -w 20 -c 40 -q 'aggregate=avg'

Re: get more details about an error

Posted: Thu Oct 31, 2019 2:59 am
by Hoygen83
Hello,
thank you for clearing it.

if I give

Code: Select all

./check_ncpa.py -H 10.100.0.8 -t 'password' -P 5693 -M cpu/percent -w 20 -c 40 -q 'aggregate=avg'
Incorrect credentials given.
what password should i insert? the one of a local administrator in the windows machine?

Anyway I repeated the procedure following this guide:
https://assets.nagios.com/downloads/nag ... ndows.html
and now I have NO credentials error on nagios.
so as I suspected I was doing something wrong.

Re: get more details about an error

Posted: Thu Oct 31, 2019 9:26 am
by scottwilkerson
Hoygen83 wrote:what password should i insert? the one of a local administrator in the windows machine?
this is the token you setup when installing NCPA