We seem to have hit a version incompatibility in BerkeleyDB between our perl scripts and our PHP scripts. Our perl scripts generate BDB and our php scripts merely read them.
Our perl scripts use DB_File to create a BDB file:
use DB_File;
$DBFILE="output.db";
tie(%db, "DB_File", $DBFILE, O_RDWR | O_CREAT, 0644)
or warning("Could not open db file '$DBFILE'");
This previously created a file of type:
$ file output.db
output.db: Berkeley DB (Hash, version 9, native byte-order)
But, after an upgrade of sys-libs/db and DB_File, now creates a file of type:
$ file output.db
output.db: Berkeley DB (Hash, version 10, native byte-order)
At the other of the system we have a PHP script. When the upgrade occurred, our PHP code (based on dba_open()) started complaining about the version:
Notice: dba_open(): output.db: unsupported hash version: 10 in dbread.php on line 16
I have tried upgrading PHP, but version 10 doesn't seem to be supported yet.
Is there a way to tell perl's DB_File to create a specific version when creating the DB?