Applications commonly wish to store some form of binary data in a file. Storing such data for efficient retrieval is tricky and error-prone. There are a number of libraries that provide simple APIs for storing information in files. The dbm library was an early part of Unix systems (and was later reimplemented as ndbm), which led later to the the Berkeley db library and the gdbm library from the GNU Project. All of these libraries provide easy access to files that are set up as hash tables, with a binary key providing access to a binary data region.
 The Berkeley db library has been greatly extended, and now includes a B-Tree implementation and full transaction capabilities.
While gdbm and Berkeley db are both widely available on Linux systems, the licenses for each of them make them unsuitable for commercial development. The qdbm library is quite similar to those other choices, but is licensed under the LGPL, making it more attractive to many developers. The basic API for each of these libraries is quite similar to the others, however, and porting code between the libraries is straightforward.
 Berkeley db is now developed by a for-profit organization, and they sell alternative licenses for their library that are attractive for certain applications.
Full source code and documentation for qdbm are available from the http://qdbm.sourceforge.net Web site. This chapter describes all of the functions most applications need to use qdbm (all of which have close analogues in Berkeley db, gdbm, and ndbm). There are other API functions available, all of which are documented at the qdbm Web site.