[DBD-SQLite] DBD::SQLite causing memory leak, after upgrade to v1.31, system reboot is required for changes to take effect?

Tee Shuwn Yuan shuwnyuan at regentmarkets.com
Tue Nov 23 06:20:02 GMT 2010

hi all,

I am currently doing development under Perl 5.8.8, with SQLite3 version 3.3.8.

I need to run a perl script that will takes few days to be completed & I use 
DBI and DBD::SQLite to store something into sqlite3 database.

In my perl script, it has 10 child process running concurrently. However, I 
noticed a slow memory leak, and eventually after like 12 hours, the script 
die with "out of memory". I suspected it is due to DBD::SQLite & apparently 
it is. 

From this link:  http://kobesearch.cpan.org/htdocs/DBD-SQLite/Changes.html

I read this:

>1.30_06 Thu 9 Sep 2010
>    * Resolved # 60860: Slow but steady memory leak on last_insert_id calls 

In my script, I did use the method "last_insert_id". So I guess it is the 
problem causing the memory leak.

However, I upgraded the DBD::SQLite to version 1.31 (the latest) and rerun my 
perl script, the leak problem still persist. Until I restart my machine, the 
leak problem has gone away. 

My question is, is that true the upgrading of DBD::SQLite cpan module require 
a system restart to takes affect? Because I can always restart in my 
development environment, but not on live server environment that is already 
running. What can I do for the changes to take effect without rebooting the 
whole system?

Please advise, thanks in advance!

shuwn yuan

More information about the DBD-SQLite mailing list