All,
I've been using Rose::DB 0.753 for the past month and have never faced
issues on my dev box.
My Dev machine had Perl 5.10.0 and Rose::DB 0.753, DBI 1.602,
DBD::Oracle 1.20
Now I'm deploying the new scripts to production setup and installed
perl 5.8.8, DBI 1.609, DBD::Oracle 1.23 and Rose::DB 0.754.
I have updated by Rose class with DB parameters, but I'm not able to
connect to the database.
I get the below error when I execute the Perl script:
DBI connect('sid=A2p300;host=
A2p300.abc.com','fake!2',...) failed:
ORA-12541: TNS:no listener (DBD ERROR: OCIServerAttach) at /willows/
sac/software/perl/lib/site_perl/5.8.8/Rose/DB.pm line 898.
To confirm the above error, I wrote a simple script using DBI and
DBD::Oracle and was able to
successfully connect and insert data into the database. Looks like an
issue on the Rose::DB side or any other DBI/DBD modules ?
Below is the entry in tnsnames.ora for the database:
A2p300 =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (COMMUNITY = A2p300)(PROTOCOL = TCP)(HOST =
A2p300.abc.com)(PORT = 7100))
)
(CONNECT_DATA =
(SID = A2p300)
(GLOBAL_NAME =
A2p300.abc.com)
)
)
Below is by RDB class with connection parameters:
package ABC::RDBO::RDB;
use warnings;
use strict;
use base 'Rose::DB';
__PACKAGE__->use_private_registry;
__PACKAGE__->register_db(
domain => 'production',
type=> 'main',
driver => 'Oracle',
database => 'A2p300',
host => '
A2p300.abc.com',
username => 'fake!2',
password => 'fake!2',
port => 7100,
connect_options =>
{
FetchHashKeyName => 'NAME_lc',
RaiseError => 1,
AutoCommit => 1,
ChopBlanks => 1,
}
);
__PACKAGE__->default_domain('production');
__PACKAGE__->default_type('main');
1;
Please help me in fixing this issue, I have very much less time, to
set this up on our production servers.
Thank you for your help.