in reply to [OT] How to fix the BerkeleyDB 52G data ?
This doesn't appear to be a Perl issue, but a DB issue.
After a quick Google, I found db_recover. If that, or other Berkeley DB recovery techniques don't work, you may have to restore the DB from a backup.
In Section
Seekers of Perl Wisdom