Skip to Content.
Sympa Menu

en - RE: [sympa-users] Issues connecting to Oracle for subscriber query

Subject: The mailing list for listmasters using Sympa

List archive

Chronological Thread  
  • From: "Philip A. Erb" <address@concealed>
  • To: "address@concealed" <address@concealed>
  • Subject: RE: [sympa-users] Issues connecting to Oracle for subscriber query
  • Date: Mon, 25 Apr 2016 17:10:43 +0000

Hey folks,

 

Here’s an update on my issue. Any input is greatly appreciated.

 

I failed to mention previously that I’m running Sympa 6.2.14 on RHEL 6.7. Sympa was installed using the yum repository at sympa-ja.org. For Sympa itself, we’re using a MySQL database on another server, which is all working properly. What’s still failing is using an Oracle query to another database to include list members for certain lists.

 

After checking and re-check (and re-re-checking) that all prereqs are installed and configured properly (to the best of my knowledge - so let’s be honest, I may have missed something), I decided to dig into the Sympa code a little to see exactly where things are failing. This led me to Database.pm. Based on the messages I was receiving in the log (see my previous message, below), I ended up at the “unless ($self->ping)” statement that starts at line 153. On a whim, I commented out that entire block of code. When I ran the subscriber synchronization … it worked!

 

So now I need to figure out why my connection to Oracle is failing the $self-ping test, but I’m still able to query it when I comment out that check.

 

In all honesty, Oracle is not one of my primary responsibilities, but we need to query it in this case. It’s very possible that I’m missing something incredibly obvious here.

 

 

 

 

From: address@concealed [mailto:address@concealed] On Behalf Of "Philip A. Erb"
Sent: Monday, April 18, 2016 10:37 AM
To: address@concealed
Subject: [sympa-users] Issues connecting to Oracle for subscriber query

 

I’m working on setting up a new Sympa server. Our main Sympa database is MySQL and that is working fine. I am able to create lists, manually add/update/remove subscribers, send emails, and interact with the web interface.

 

The problem that I’m running into is with querying an Oracle database for list subscribers. This was working on our very old installation and was setup by a SysAdmin who is no longer with us, nor documented.

 

My DBAs have installed the full Oracle client, as is their preference, on the Sympa server and configured TNSNames. I’ve installed the DBD::Oracle Perl module and I can query the database using a simple Perl script (using the exact query that I would use in Sympa). However, when I setup include_sql_query for the list in Sympa, sync_include throws an internal server error that it failed to include members. Below are the (redacted) relevant log lines:

 

Apr 18 10:23:03 sympa wwsympa[2949]: notice Sympa::List::on_the_fly_sync_include() Synchronizing list members...

Apr 18 10:23:03 sympa wwsympa[2949]: err main::#1647 > main::do_edit_list#12661 > Sympa::List::on_the_fly_sync_include#7003 > Sympa::List::sync_include#6702 > Sympa::List::_load_list_members_from_include#5928 > Sympa::List::_include_users_sql#5716 > Sympa::DatabaseDriver::Oracle::connect#68 > Sympa::Database::connect#155 Can't connect to Database Sympa::DatabaseDriver::Oracle <db_host=***;db_name=***;db_port=1533;db_user=***>

Apr 18 10:23:03 sympa wwsympa[2949]: err main::#1647 > main::do_edit_list#12661 > Sympa::List::on_the_fly_sync_include#7003 > Sympa::List::sync_include#6702 > Sympa::List::_load_list_members_from_include#5928 > Sympa::List::_include_users_sql#5719 Unable to connect to SQL datasource with parameters host: ***, database: ***

Apr 18 10:23:03 sympa wwsympa[2949]: err main::#1647 > main::do_edit_list#12661 > Sympa::List::on_the_fly_sync_include#7003 > Sympa::List::sync_include#6712 Errors occurred while synchronizing datasources for list Sympa::List <test1@***>

Apr 18 10:23:03 sympa wwsympa[2949]: err main::#1647 > main::do_edit_list#12661 > Sympa::List::on_the_fly_sync_include#7003 > Sympa::List::sync_include#6702 > Sympa::List::_load_list_members_from_include#6059 Inclusion include_sql_query failed in list Sympa::List <test1@***>

 

I’ve verified that I can ping the database server, telnet to the database port, and to a tnsping to the appropriate database. And, as I said earlier, I’ve written a simple Perl script that runs the same query (and I’m running it as the Sympa user) with no problems.

 

So, I’m a little confused and frustrated! Probably overlooking something simple. Any thoughts are GREATLY appreciated!

 

 

Philip Erb, MCSA
Systems Administrator & Programmer
University of Scranton
Office:  570.941.4012

 




Archive powered by MHonArc 2.6.19+.

Top of Page