PERL Scripts are not working V2

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
absarcompass
Posts: 182
Joined: Thu May 14, 2015 9:57 pm

Re: PERL Scripts are not working V2

Post by absarcompass »

Hi guys,
sorry was away couldn't update you guys
the error messages mentioned above have these two plugins involve.
  • plugin_capture.pl
    ,
    check_database_table_locking.pl
can you please have a look what could have been an issue here

Thanks
You do not have the required permissions to view the files attached to this post.
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: PERL Scripts are not working V2

Post by Box293 »

Try:

Code: Select all

yum install perl-Time-modules perl-MIME-Lite
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
absarcompass
Posts: 182
Joined: Thu May 14, 2015 9:57 pm

Re: PERL Scripts are not working V2

Post by absarcompass »

Thanks Box293,
It has changed the erroneous output.
[root@nagiosxi libexec]# ./plugin_capture.pl /usr/local/nagios/libexec/check_database_table_locking.pl DATABASE
DBI connect('server=localhost;database=sql_jobs','sql_jobs',...) failed: Access denied for user 'sql_jobs'@'localhost' (using password: YES) at /usr/local/nagios/libexec/check_database_table_locking.pl line 271
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: PERL Scripts are not working V2

Post by Box293 »

That no longer looks like a plugin issue but more of some sort of config required for the plugin.

You'll need to refer to the documentation on these plugins to find out what is required. If it's working on your old server, then it should just be a matter of looking at how the plugins run on the old server.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
absarcompass
Posts: 182
Joined: Thu May 14, 2015 9:57 pm

Re: PERL Scripts are not working V2

Post by absarcompass »

Hi Guys,
I am unable to locate the issue.
will try running the tcpdump on both the server to check what the plugin is passing or passing incorrectly.
rkennedy
Posts: 6579
Joined: Mon Oct 05, 2015 11:45 am

Re: PERL Scripts are not working V2

Post by rkennedy »

Is your SQL server only allowing specific IP's? That could be the issue.
Former Nagios Employee
absarcompass
Posts: 182
Joined: Thu May 14, 2015 9:57 pm

Re: PERL Scripts are not working V2

Post by absarcompass »

Yes, I can connect to server via isql and can run queries but same query is only working on old one, not in nagiosXI
although DB connections is established.
Had no luck with tcpdump as of yet, I only get database connection establishment and acknowledgement packets nothing of sort the values being passed within.
will dig more though
rkennedy
Posts: 6579
Joined: Mon Oct 05, 2015 11:45 am

Re: PERL Scripts are not working V2

Post by rkennedy »

From the CLI can you authenticate to the remote SQL server? For example I can run this from the local XI machine and it works. Replace the values as needed for your DB.

Code: Select all

mysql -uroot -pnagiosxi -hlocalhost
Former Nagios Employee
absarcompass
Posts: 182
Joined: Thu May 14, 2015 9:57 pm

Re: PERL Scripts are not working V2

Post by absarcompass »

Hi Guys,
This issue was fixed, and my apologies for not updating this post.
I had to change the version in my freetds.conf to make scripts work.
you helpful guys can lock this thread now :D
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: PERL Scripts are not working V2

Post by tmcdonald »

Thanks for getting back to us!
Former Nagios employee
Locked