Berkeley DB Library Version Change Log

Changes between and
Changes between and
Changes between and
Changes between and
Changes between and
Changes between and
Database or Log File On-Disk Format Changes
New Features/Improvements
Database Environment Changes
Concurrent Data Store Changes
Access Method Changes
API Changes
SQL-specific API Changes
Tcl-specific API Changes
Java-specific API Changes
C#-specific API Changes
C++-specific API Changes
Replication Changes
Locking Subsystem Changes
Logging Subsystem Changes
Memory Pool Subsystem Changes
Mutex Subsystem Changes
Transaction Subsystem Changes
Test Suite Changes
Utility Changes
Configuration, Documentation, Sample Apps, Portability and Build Changes
Example Changes
Miscellaneous Bug Fixes
Platform Certification Changes
Deprecated Features
Known Bugs

This is the changelog for Berkeley DB 12c Release 1 (library version

Changes between and

  1. Fixed some compiler warnings in db_conv.c. [#25086]

  2. Fixed some null pointer crashes in the Tcl layer. [#26331]

  3. Improved stability with several changes that prevent crashes when running db_verify against corrupt files. [#27088]

Changes between and

  1. Increased the number of instances in which failchk can successfully clean the environment without requiring full recovery after a thread crashes while using Berkeley DB. [#25087]

  2. Improved db_verify's handling of corrupted database files. [#25239]

  3. Fixed configure bug which prevented shared library support on FreeBSD 10. [#25251]

  4. Added PRAGMA statistics, which prints out statistics about the database and its environment. [#25550]

  5. Added PRAGMA statistics_files, which redirects output from the statistics PRAGMA to a file. [#25550]

  6. Internal Berkeley DB messages are now redirected to the same file where internal Berkeley DB error messages are redirected. [#25568]

  7. Fixed a bug that could cause a client undergoing internal initialization to fail to request all the necessary logs for a correct recovery. The major symptom of this bug was that some client database files were left with empty pages that would later cause log sequence errors or other failures. [#25624]

  8. Fixed a blob files related crash in db_verify. [#25920]

  9. When opening a database handle which was created outside of an environment, if the current working directory contains a DB_CONFIG file it will no longer be processed. [#26319]

Changes between and

  1. Fixed a bug where opening or renaming a compressed in-memory database may fail with the error "BDB1565 DB->set_bt_compress: method not permitted after handle's open method". [#22055][#22056]

  2. Fixed a crash when joining compressed databases. [#22058]

  3. Fixed a bug where a join cursor may miss the first matching pair when the database is compressed. [#22062]

  4. Fixed two potential lock leaks in database compaction. [#23725]

  5. Fixed a bug that can cause a DB_PAGE_NOTFOUND error during btree compaction. [#23853]

  6. Fixed a bug where setting DatabaseEnvironmentConfig.Register had no effect. [#24094]

  7. Improved the configure scripts for Mac OS X. [#24139]

  8. The JDBC jar file (sqlite.jar) is now installed in the "lib" directory instead of "jar" on *nix systems. [#24139]

  9. Fixed a bug in BDB SQL where adding a replication site immediately after opening the master environment could cause the add site operation to hang. Also fixed a bug that caused BDB SQL to lose its encryption settings when turning replication on or off on an existing environment. [#24327]

  10. Enhanced the vote comparison routine used to select a new master. [#24433]

  11. Fixed a crash which could occur when maximum count of lockers is reached. [#24470]

  12. Fixed a potential memory error when executing a SQL query. [#24471]

  13. One single transaction is now used to manage blob handles for tables that contain blobs. [#24549]

  14. Fixed a bug that may cause an environment panic when the number of lock table partitions is too large. [#24554]

  15. Fixed a bug where MultipleRecnoDataEntry did not encode record-number-data pairs correctly with append(). [#24555]

  16. Fixed a bug that may cause DBcursor->put to crash when DB_AFTER is set. [#24572]

  17. Fixed a bug where Database.setConfig() may incorrectly throw an exception. [#24585]

  18. Fixed a bug that caused mixed-version replication live upgrades from releases prior to 6.0 to fail with an EEXIST error when in-memory databases are present. [#24597]

  19. Corrected error paths which could cause a spurious panic when attempting to unlock a mutex that was not locked. [#24606]

  20. When an attempt to flush a file from the memory pool fails, add an error message that includes the file name. It is likely that the file was removed or altered outside of the control of Berkeley DB. [#24606]

  21. Removed a potential race condition when three or more threads attempt to split adjacent pages in a btree. [#24733]

  22. Added additional page verifications into db_verify to prevent possible SEGV errors when verifying extremely corrupted database files. [#24754]

  23. Fixed a bug where DB_ENV->open() would fail when DB_ENV->set_memory_max() was called on a 32-bit system. [#24783]

  24. Fixed a bug where an application might hang because it could not obtain a TAS lock when running Linux on the SPARC architecture. [#24805]

  25. Fixed a bug that may cause a crash when working with sequences. [#24826]

  26. Fixed a crash when closing a connection to a database with sequences. [#24827]

  27. BLOB files and encryption can now be enabled together. Note that only the data stored in the database will be encrypted; the data in the BLOB files will remain unencrypted. [#24849]

  28. Fixed a bug that may cause a segmentation fault when multiple database handles are opened on the same database in the same transaction. [#24857]

  29. Fixed the error "BDB0232 Error opening blob file" when using the SQL API with PRAGMA large_record_opt enabled. [#24895]

  30. Added a new utility program db_convert. [#25086]

Changes between and

  1. A 'salvage' (db_dump -r) no longer hangs on a corrupt database which contains a loop in an overflow item's chain of pages. [#18550]

  2. Remove +u1 compiler flag from the HP-UX build and fixed related alignment issue. [#23739]

  3. Fixed DB_RUNRECOVERY errors caused by pthreads-based mutexes. [#23965]

  4. Allow the failchk process to call __env_refresh when necessary. [#24194] ` DB->open() now detects invalid pagesizes sooner, avoiding a potential floating point exception when a purported database file has a pagesize of 0. Added a pre-verify step to the db_dump utility. [#24217]

  5. Fixed a bug that can cause DBcursor->get to return incorrect data when DB_GET_BOTH_RANGE flag is used. [#24220.1]

  6. Added support for Java 8. [#24220.2]

  7. Aborting a transaction no longer panics if a deadlock error occurs while freeing up the transaction's cursors. [#24223]

  8. Fixed a crash which could occur when multiple BDB SQL processes repeatedly open a database file. [#24230]

  9. Fixed a bug where db_printlog improperly handled a "No such file or directory" error condition. [#24265]

  10. Fixed a bug that could cause a master crash in the following cases: an unencrypted client attempts to join an encrypted replication group, or an encrypted client attempts to join an unencrypted replication group. [#24288]

  11. Fixed a bug that can cause a crash when DB_ENV->memp_stat() is called. [#24298]

  12. Added support for arm64. [#24312]

  13. Reduced the minimum hash table size. [#24314].

  14. Fixed a bug where file names were not displayed correctly when a file failed to open during backup. [#24340]

  15. Enabled cross compiling the JDBC driver. [#24347]

  16. Fixed a crash when writing to a SQL BLOB while txn_bulk is enabled. [#24351]

  17. DB->open() now detects invalid bt_minkey better, avoiding a potential floating point excetpion. [#24398]

  18. Removed EnvironmentConfig.setTxnNotDurable() and Environment.getTxnNotDurable() from the Java API. This flag cannot be set on environments. [#24416]

Changes between and

  1. Fixed a bug that was preventing PRAGMA cache_size from changing the size of the cache. [#24206]

  2. Fixed a recovery bug that could cause files to end up in the wrong directory when using logs created in 5.3 or earlier. [#24169]

  3. Creating a table in SQL will no longer fail if the database connection was opened without the SQLITE_OPEN_CREATE flag. [#24115]

  4. Fixed a bug where an error message was not displayed back to the user correctly when sequence creation failed. [#24103]

  5. Fixed a bug where BDB was not handling tables with multiple BLOB columns when using the SQL API. [#24092]

  6. SQL sequence names are now case insensitive except when surrounded by quotation marks. [#23964]

  7. Avoid incrementing the statistic DB_LOG_STAT.st_scount ("Total log file flushes") when DB_LOG_NOSYNC is in effect. [#23945]

  8. Fixed a bug that may lead to crash when opening multiple environments in a multi-threaded program. [#23913]

  9. Improved the way we mark a password as consumed. [#23876]

  10. Fixed the error "BDB2074 No space available in latch table" for configurations using plain pthreads mutexes and DB_ENV->set_thread_count(). Susceptible configurations include the definition of HAVE_MUTEX_PTHREADS in db_config.h but do not define HAVE_MUTEX_HYBRID. [#23831]

  11. Fixed a crash when MVCC and snapshot isolation are used and the system is under heavy load. [#23815]

  12. Fixed a problem with closing a panicked environment, in which an infinite loop was possible. [#23814]

  13. Removed Java 5 targets from Windows builds and javadoc production. [#23811]

  14. Support for client-to-client replication of BLOB data during internal initialization has been disabled. [#23748]

  15. Fixed a bug that may cause self-deadlock during database compaction. [#23725]

  16. Fixed a bug in the recovery of a truncated hash database. [#23772]

Changes between and

  1. Fixed a sqlite3odbc bug which may return an out-of-memory error when calling SQLGetData() on empty long columns. [#22777]

  2. Enabling BLOB support and master leases will no longer result in unexpected DB_REP_LEASE_EXPIRED errors. [#23275]

  3. Fixed a race condition when BLOB support is enabled with replication where message handling could fail with an ENOENT error. [#23275]

  4. Existing SQL databases will have to be reindexed after upgrading to this release. No actions are required for non-SQL databases. Check the upgrade documentation for more details. [#23469]

  5. Fixed a known bug in SQL where ORDER BY could return results out of order if an index is used to answer the query. [#23469]

  6. Fixed a bug that causes a crash when opening a corrupted environment with encryption and DB_REGISTER. [#23643]

  7. Fixed a bug that causes a crash when opening a corrupted environment with DB_FAILCHK using a BDB compiled with DIAGNOSTIC defined. [#23643]

  8. Fixed a bug where closing a panicked environment raised an access violation and crashed the program. [#23679]

  9. Fixed a bug where db_verify did not verify multiple files correctly. [#23692]

  10. Fixed a bug that causes a site joining a replication group to hang or to only partially complete the internal steps necessary to join the replication group. [#23750]

Database or Log File On-Disk Format Changes

  1. The log file format changed in

New Features/Improvements

  1. Demonstrated in a sample app how to use thread-specific structures to associate a DB_EVENT_REP_PERM_FAILED event with the transaction that caused it. [#17686]

  2. Replication Manager Preferred Master is a new option for 2-site replication groups. One site is the preferred master, which assumes the master role as much of the time as its availability permits. A preferred master replication group guarantees that transactions committed on the preferred master site will never be rolled back while also providing client failover. [#20230]

  3. A new flag DB_FORCESYNCENV is provided for DB_ENV->close(), which forces flushing the memory mapped regions before unmapping them. [#21176]

  4. A new API is provided to limit the Replication Manager incoming queue based on the amount of heap memory it uses. [#21481]

  5. BLOB support is now available for environments configured for replication. [#22359]

  6. A new version of DB_ENV->failchk() helps supports multi-process environments which use DB_REGISTER rather than a monitoring process. It is turned on with --enable-failchk_broadcast. [#22419]

  7. Added support for Visual Studio 2012. [#22477]

  8. CPU time needed for database backups is now reduced. [#22967]

  9. Added BDB utilities for the Android platform. [#23079]

  10. Added --enable-error_history support. This diagnostic tool prints a stack trace when a panic occurs. [#23119]

  11. The new log configuration option DB_LOG_NOSYNC has been added to avoid flushing the transaction log in order to stabilize storage. This can be useful when durability across system crashes is unnecessary and all the transactions in the environment specify either the DB_TXN_NOSYNC or DB_TXN_WRITE_NOSYNC flag. This configuration setting may be made by DB_ENV->log_set_config() or a DB_CONFIG line "db_log_nosync [on|off]". [#23191]

Database Environment Changes

  1. Fixed a problem with DB_LOCKDOWN which would cause an mlock error ENOMEM on some operating systems. [#21379]

  2. DB_ENV->close() now detaches from the environment's mmap and shared memory regions even when a panic error (DB_RUNRECOVERY) has been returned. DB_ENV->open(DB_REGISTER) detects whether a panic has occurred in the environment. If so it returns DB_RUNRECOVERY. Prior to this, the panic state was not detected, which might have caused a hang. [#22805]

  3. Ensure that the size of memory mapped backing files are a multiple of the system pagesize. Previously the files were aligned up to 8KB boundaries, which was not adequate for systems with a 64KB pagesize. [#23290]

  4. Improved the sizing of the environment region to better match the needs of thread tracking as specified by DB_ENV->set_thread_count(). [#24314]

  5. Include a new field in the per-thread statistics output: the number of locked mutexes. [#25690]

Concurrent Data Store Changes

  1. -None

Access Method Changes

  1. Fixed a bug that left behind obsolete queue extents. [#21988]

  2. Fixed a bug that occurred if the range keys did not fit within one database page during database partition opening. [#22280]

  3. Corrected a buffer mutex deadlock involving off-page duplicate sets and less than full transactional isolation levels. [#22532]

  4. Fixed a byte swapping bug that could corrupt the header of heap database pages. [#23318]

API Changes

  1. Make flag checking in sequence stat print API consistent with the other stat print APIs. [#22513]

SQL-specific API Changes

  1. Fixed a bug that was preventing old log files from being removed while using the SQL API. [#22521]

  2. Updated SQL API build to be compatible with SQLite [#23178]

  3. Updated ADO.NET API to be compatible with System.Data.SQLite [#23446]

Tcl-specific API Changes

  1. Exposed flag DB_SET_MUTEX_FAILCHK_TIMEOUT in Tcl API. [#23163]

  2. Added msgfile and msgfile_close in the Tcl API. [#31881].

Java-specific API Changes

  1. Exposed DB->set_msgfile(), DB_ENV->set_msgfile() and all xxx_stat_print() in Java API.[#22691]


  3. Exposed new flag DB_LOG_NOSYNC in Java API. [#23191]

  4. Updated DPL changes from BDB JE. [#23251]

  5. Exposed new flag DB_EVENT_REP_INQUEUE_FULL in Java API. [#23280]

  6. Fixed a bug that partition directories could not be set correctly via Java API. [#23410]

C#-specific API Changes

  1. The class LockDetectMode has been removed. It was duplicating functionality provided in other classes and not being used. [#21248]

  2. Exposed DB_STAT_ALLOC in PrintLockingSystemStats(), PrintLoggingSystemStats(), PrintMPoolSystemStats(), PrintMutexSystemStats(), PrintStats() and PrintTransactionSystemStats(). [#22513]

  3. Exposed DB->set_msgcall(), DB->set_msgfile(), DB_ENV->set_msgcall() and DB_ENV->set_msgfile() to C# API. [#22799]


  5. Exposed new flag DB_LOG_NOSYNC in C# API. [#23191]

  6. Exposed new flag DB_EVENT_REP_INQUEUE_FULL in C# API. [#23280]

  7. Changed definition of all structs to make SWIG 2.0.12 can generate code successfully. [#23295]

C++-specific API Changes

  1. Fixed a bug that db_stl library could not build using gcc-4.7 or later versions. [#22615]

Replication Changes

  1. Fixed a bug where, after some rare multiple-site failure scenarios including transaction rollbacks, Replication Manager could have incorrectly determined that new transactions fulfilled the acknowledgement policy. [#16624]

  2. Acknowledgements are counted more precisely when an unelectable client is first joining the replication group and also when a master has been set to be unelectable. [#20825]

  3. If there is already a replication process running, do not require a flag value when calling DB_ENV->repmgr_start() to start a subordinate process. [#20980]

  4. Fixed a bug that a site could not rejoin the replication group on Windows after being removed from the group. [#22460]

  5. When a removed site rejoins a two-site replication group with DB_REPMGR_CONF_2SITE_STRICT turned off, defer its election so that the rejoining site does not prematurely elect itself master with only its own vote when the other site is already master. [#22683]

  6. Fixed a bug where a Replication Manager subordinate process could fail its automatic takeover as the replication process because it is unnecessarily waiting for acknowledgements from other sites before the connections to these sites are properly established. [#22998]

  7. Fixed a bug where a client synchronization could get stuck because certain error paths were failing to release an internal lockout. [#23169]

  8. Fixed a bug where replication group-aware log archiving might have unnecessarily kept log files after certain connection sequences between sites. [#23420]

Locking Subsystem Changes

  1. None

Logging Subsystem Changes

  1. Avoid incrementing the statistic DB_LOG_STAT.st_scount ("Total log file flushes") when DB_LOG_NOSYNC is in effect. [#23945]

Memory Pool Subsystem Changes

  1. None

Mutex Subsystem Changes

  1. Removed an environment handle mutex which was no longer needed. [#23099]

  2. Removed the last source files of the defunct fcntl mutex implementation. [#23119]

  3. Fix a race condition which might allow DB_ENV->failchk() to hang after it had freed a locker ID. [#24194]

Transaction Subsystem Changes

  1. None

Test Suite Changes

  1. None

Utility Changes

  1. None

Configuration, Documentation, Sample Apps, Portability and Build Changes

  1. Fixed a bug that ex_rep_base could not quit gracefully after receiving 'exit' command. [#16871]

  2. Extended the ex_rep_mgr Replication Manager sample application to demonstrate the use of a thread-specific structure to associate a DB_EVENT_REP_PERM_FAILED event with its originating transaction. [#17686]

  3. Parameter "-module" is removed from task libsqilte_jni in JDBC makefile. So libsqlite_jni library could be built in '.dylib' format on Mac OS X. [#22937]

  4. Additional information about the cause of an error may now be displayed by configuring with --enable-error_history. [#23119]

  5. Add one public error code 'DB_META_CHKSUM_FAIL'. [#23304]

  6. Added build support on latest MinGW. [#23332]

  7. A configuration warning 'Ignoring --with-cryptography flag value' is added for the non-crypto package. [#23333]

  8. Parameter LIBSQLSO_LIBS is added to the task libsqlso_target to workaround a linking issue with the gcc 4.8.1 distributed by Ubuntu. [#23372]

  9. Extended the Mac OS X section in the chapter 7 of the installation guide. [#23388]

  10. Fixed PHP module to consistently use the ZEND_REGISTER_RESOURCE macro, preventing a build failure with PHP 5.5. Updated INSTALL file to note the changed location of sample output. [#23391]

  11. Fixed a few typos in the JDBC/ODBC sections of the Windows/Unix installation guide. [#23404]

Example Changes

  1. Added an example using BDB SQL with the JDBC driver and ADF. [#22569]

Miscellaneous Bug Fixes

  1. Fixed a byte swapping bug with log file operations on blob files. [#22215]

  2. Fixed test failures on QNX with small mutex regions. [#22310]

  3. Database containing BLOBS are now portable between machines of opposite endianness. [#22455]

  4. Added a -D option to display output for db_dump and db_printlog. This value takes priority over DB_ENV->set_data_len() if that was called to set the length. [#22485]

  5. Updates to PHP API to handle functional changes in PHP 5.4. [#22549]

  6. Fixed heap databases so they can work on both big and little endian machines. [#22929]

  7. Restructure the blob delete code to improve performance. [#22935]

  8. Properly clean up blob meta database after aborting the creation of its parent database. [#23000]

  9. Fixed memory alignment issues with the DB_MPOOL stats. [#23150]

  10. Fixed a byte swapping bug with heap blob log records. [#23319]

  11. Fixed two race condition bugs with DB_ENV->failchk(). [#23347]

  12. Fixed memory alignment issue on Solaris. [#23571]

  13. Fixed a bug that using Visual Studio 2010 and JDK 1.5 could generate corrupted jar files. [#23574]

  14. Fixed a bug that specifying --with-cryptography=yes did not build the jdbc library correctly. [#23606]

Platform Certification Changes

  1. Berkeley DB no longer tests or certifies Windows XP or Windows 2003.

Deprecated Features

  1. The DB_AUTO_COMMIT flag is present in the DB_SEQUENCE APIs for Java and C#. This flg is no longer meaningful for these APIs and will be deprecated in the next release.

Known Bugs

  1. [#23469] (Fixed in -- see above.) The SQL ORDER BY command on the primary key of a table can in rare cases return the results out of order if an index search is used in executing the query. For example: Create a single column table. Insert two rows with identical values. A query on the row id and the column will produce results in a different order depending on whether an index is used.