Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the DBD-Oracle CPAN distribution.

Report information
The Basics
Id: 6245
Status: resolved
Priority: 0/
Queue: DBD-Oracle

People
Owner: Nobody in particular
Requestors: stevef [...] pcbi.upenn.edu
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 1.14
Fixed in: 1.12



Subject: Confirmed memory leak
We have found a memory leak in DBD::Oracle. Under our conditions it seems to be leaking about 1 meg/second. We are running: - DBD::Oracle 1.15 or 1.14 - DBI 1.30 or 1.42 - Perl 5.8.0 or 5.8.3 - Redhat Enterprise Advance Server 3.0 Here is a script that reproduces the bug: use DBI; my $dsn = "your_dsn_here"; my $user = "your_user_name_here"; my $password = "your_password_here"; my $query = "select count(*) from your_table_here"; my $dbh = DBI->connect($dsn, $user, $password, 0); $stmt = $dbh->prepare($query); while(1) { $stmt->execute(); my ($result) = $stmt->fetchrow_array(); $stmt->finish(); }
I can't duplicate this using DBD::Oracle 1.15 or 1.14 on Solaris using Oracle 9.0.1 If I can't duplicate it I can't fix it. It also implies that the problem is within Oracle OCI libs. Tim. p.s. "1 meg/second" isn't very meaningful. The amount leaked per loop would be more useful. [guest - Thu May 6 11:24:57 2004]: Show quoted text
> We have found a memory leak in DBD::Oracle. > > Under our conditions it seems to be leaking about 1 meg/second. > > We are running: > - DBD::Oracle 1.15 or 1.14 > - DBI 1.30 or 1.42 > - Perl 5.8.0 or 5.8.3 > - Redhat Enterprise Advance Server 3.0 > > Here is a script that reproduces the bug: > > use DBI; > my $dsn = "your_dsn_here"; > my $user = "your_user_name_here"; > my $password = "your_password_here"; > my $query = "select count(*) from your_table_here"; > > my $dbh = DBI->connect($dsn, $user, $password, 0); > $stmt = $dbh->prepare($query); > > while(1) { > $stmt->execute(); > my ($result) = $stmt->fetchrow_array(); > $stmt->finish(); > } > >
From: aldo
I Using : 1. SunOS 5.6 Generic_105181-33 sun4u sparc SUNW,Ultra-Enterprise Perl 5.005_03 DBI 1.37 DBD-Oracle 1.14 Oracle Release 8.1.5.0.0 2. Linux 2.4.18-17.7.xsmp #1 SMP i686 Perl 5.6.1 DBI 1.41 DBD-Oracle 1.16 Oracle Release 8.1.6.0.0 II The following code: use strict; use DBI; foreach ( 1 .. 100 ) { my $dbh = DBI->connect( 'dbi:Oracle:host=****', '***', '***' ); $dbh->disconnect(); sleep(1) } III Leak about 4K every 10 seconds PID USER PRI NI SIZE RSS SHARE STAT %CPU %MEM TIME COMMAND 24927 aldo 15 0 8724 8720 2760 S 1.3 3.4 0:01 perl PID USER PRI NI SIZE RSS SHARE STAT %CPU %MEM TIME COMMAND 24927 aldo 15 0 8736 8732 2760 S 0.7 3.4 0:01 perl
From: sebastiani [...] nergal.it
I confirm this bug in the following configuration: # cat /etc/redhat-release Fedora Core release 3 (Heidelberg) # uname -a Linux xxxxxx 2.6.9-1.667smp #1 SMP Tue Nov 2 14:59:52 EST 2004 i686 i686 i386 GNU/Linux # perl -v This is perl, v5.8.5 built for i386-linux-thread-multi .... with my $dsn = "dbi:Oracle:yyyyyyyyy"; $DBI::VERSION = "1.46";
From: Fabrizio Sebastiani <sebastiani [...] nergal.it>
[guest - Thu Aug 25 09:58:03 2005]: Show quoted text
> I confirm this bug in the following configuration: > > # cat /etc/redhat-release > Fedora Core release 3 (Heidelberg) > # uname -a > Linux xxxxxx 2.6.9-1.667smp #1 SMP Tue Nov 2 14:59:52 EST 2004 i686 > i686 > i386 GNU/Linux > # perl -v > This is perl, v5.8.5 built for i386-linux-thread-multi > .... > > with > my $dsn = "dbi:Oracle:yyyyyyyyy"; > > $DBI::VERSION = "1.46"; > > >
I work more and more against this problem: I successfully solved it recompiling perl without thread support: 1) get perl source from CPAN 2) compile it with no thread support. "Configure.sh" script can be launched with no options: threads are disabled by default. 3) make && make test && make install and that's all!
Thanks. Please email a summary of that to dbi-users@perl.org so it'll be archived and help others experiencing the same problems.