Memory Leak in DBD::Mysql

Bug #51746 reported by nil
4
Affects Status Importance Assigned to Milestone
libdbd-mysql-perl (Ubuntu)
Fix Released
Undecided
Dave Morley

Bug Description

Binary package hint: libdbd-mysql-perl

I think I found a memory leak in some point in Perl/Mysql infraestructure. I am not sure that if it is in DBD::mysql, general DBI or possible in libmysql-client, but it's very easy to reproduce the memory leak:

#!/usr/bin/perl
use strict;
use warnings;
use DBI; # DB interface with MySQL

while (1){
        keep_alive_check();
}

sub keep_alive_check {
        my $dbh = DBI->connect("DBI:mysql:pandora:localhost:3306","pandora","pandora",{ RaiseError => 1 });
        $dbh->disconnect;
        undef $dbh;
}

If you run this script, it lost aprox 32bytes per second. I calculated that exactly lost 4 bytes per iteration. My library versions are:

Ubuntu Dapper (also tested with Debian Woody) with the same results.

/usr/local/lib/perl/5.8.7/DBD/mysql.pm
$VERSION = '3.0006';

/usr/lib/perl5/DBD/mysql.pm
$VERSION = '3.0002';

Please, if anybody knows something about this, contact me or post here some light to the problem.

Thanks.

Revision history for this message
nil (slerena) wrote :

Its fixed, at 16th Jun 2006. I found a reference for this leak in a maillist, please fix ASAP.

http://www.nntp.perl.org/group/perl.dbi.dev/4583

Thanks.

Revision history for this message
Dave Morley (davmor2) wrote :

Do you still have an issue with this or can this bug be closed?

Revision history for this message
nil (slerena) wrote : Re: [Bug 51746] Re: Memory Leak in DBD::Mysql

On Wednesday 21 February 2007 20:12:55 davmor2 wrote:
> Do you still have an issue with this or can this bug be closed?

Maintainer of PERL DBI package has launched a workaround and this has been
submitted to debian repositories, so yes, could be closed.

--
Un saludo,

 Sancho Lerena
 http://www.openideas.info

Changed in libdbd-mysql-perl:
assignee: nobody → davmor2-gmail
status: Unconfirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.