Page 2 of 3

Re: stderr:"/usr/local/nagios/libexec/check_nna.py", line 15

Posted: Thu Mar 31, 2022 7:19 am
by bcgriffin90
[~]# /usr/local/nagios/libexec/check_nna.py -H 10.10.7.73 -K <key> -S 8 -m flows -w 10 -c 20 --verbose
File "/usr/local/nagios/libexec/check_nna.py", line 159
print "DOWN - The " + text_type + " you are trying to use doesn't exist"
^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print("DOWN - The " + text_type + " you are trying to use doesn't exist")?
[~]# python2 /usr/local/nagios/libexec/check_nna.py -H 10.10.7.73 -K <key> -S 8 -m flows -w 10 -c 20 --verbose
And error was encountered:
<urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:727)>
[~]# python2 /usr/local/nagios/libexec/check_nna.py -H 10.10.7.73 -K <key> -S 8 -m flows -w 10 -c 20 --verbose --secure
And error was encountered:
<urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:727)>
[~]# python2 /usr/local/nagios/libexec/check_nna.py -H 10.10.7.73 -K <key> -S 8 -m flows -w 10 -c 20 --verbose --secure --ignorecert
And error was encountered:
0

Re: stderr:"/usr/local/nagios/libexec/check_nna.py", line 15

Posted: Thu Mar 31, 2022 7:33 am
by bcgriffin90
I updated the httpd configuration with our certs and re-ran the commands:

[~]# python2 /usr/local/nagios/libexec/check_nna.py -H <url> -K <key> -S 8 -m flows -w 10 -c 20 --verbose --secure
And error was encountered:
0

Re: stderr:"/usr/local/nagios/libexec/check_nna.py", line 15

Posted: Thu Mar 31, 2022 9:08 am
by gsmith
Awesome, that's what we want to see.

How does it look from XI now?

Thanks

Re: stderr:"/usr/local/nagios/libexec/check_nna.py", line 15

Posted: Tue Apr 05, 2022 9:08 am
by bcgriffin90
It is not working. Please see my earlier thread:

Good Morning,

My sym link was already set up the way you described. I updated the command within the gui, applied the configuration, and even rebooted the server. I'm now receiving a different error. Also, navigating to the 'network traffic analysis' tab for a given host results in the page spinning indefinitely.

UNKNOWN - Error occurred while running the plugin.

What's our next steps on this?

Thanks,
Colton

Re: stderr:"/usr/local/nagios/libexec/check_nna.py", line 15

Posted: Tue Apr 05, 2022 10:07 am
by gsmith
Hi

Please run:
python2 /usr/local/nagios/libexec/check_nna.py -H <url> -K <key> -S 8 -m flows -w 10 -c 20 --verbose --secure

Once you have done that please get a System Profile so I can look at the logs:
1. Login to the Nagios XI GUI using a web browser.
2. Click the "Admin" > "System Config" > "System Profile" menu pick
3. Click the "Download Profile" button
4. Save the profile.zip file and share the file in a private message and then reply to this post to bring it up in the queue.

Thanks

Re: stderr:"/usr/local/nagios/libexec/check_nna.py", line 15

Posted: Tue Apr 05, 2022 12:06 pm
by bcgriffin90
I tried sending you the profile.zip via DM, but it just sits in my outbox like the last message I tried to send. So I sent it to your email.

Re: stderr:"/usr/local/nagios/libexec/check_nna.py", line 15

Posted: Thu Apr 07, 2022 11:44 am
by gsmith
Hi

On your NNA server please run the following and send me the output:

Code: Select all

mysql -u root -pnagiosna nagiosna
select * from nagiosna_Sources;
ifmysql -u root -pnagiosna nagiosna doesn't work use: mysql -u root nagiosna

Thanks

Re: stderr:"/usr/local/nagios/libexec/check_nna.py", line 15

Posted: Tue Apr 12, 2022 7:32 am
by bcgriffin90
I sent you the results via email.

Thanks

Re: stderr:"/usr/local/nagios/libexec/check_nna.py", line 15

Posted: Tue Apr 12, 2022 1:24 pm
by gsmith
Hi

In the command:
python2 /usr/local/nagios/libexec/check_nna.py -H <url> -K <key> -S 8 -m flows -w 10 -c 20 --verbose --secure

The S option's value is the SID of the source you are trying to monitor. Upon looking at the results of the database
query I see there is no SID of 8, so please try using a different SID from the query:
netflow.png
Let me know the results.

Thanks

Re: stderr:"/usr/local/nagios/libexec/check_nna.py", line 15

Posted: Wed Apr 13, 2022 7:30 am
by bcgriffin90
[~]# python2 /usr/local/nagios/libexec/check_nna.py -H nagiosna.parts4heat.com -K <api key> -S 2 -m flows -w 10 -c 20 --verbose --secure
CRITICAL - 13359 flows sent/recieved|flows=13359