http://qs321.pair.com?node_id=405788


in reply to mldbm ndbm sdbm gdbm db :: what differences

Aside from those listed in the table, there's an alternative to DB_File (DBM) in BerkelyDB.

Both DB_File and BerkeleyDB link to the libraries from Sleepycat, but the latter links to a newer version with better support for different table types, internal locking etc.

I've been playing around with it lateley, and a table of 12 million records can be about 3 times faster then a regular mysql-isam table.

The difference in speeds across the different versions mostly comes from the way the data is stored and the way data is retrieved from the table using sequential lookup, hashed lookup, tree-based indexing and how it reads from the database.

I don't know enough about those modules other than DB_File and BerkeleyDB, but the the table in the link you provided shows most implementations use custom block-sizes, whereas BerkeleyDB uses the block-size of the underlying IO system, so a diskread fetches a full with 1 read. When I changed this to a custom value performance dropped significantly

Hth,
Deliria

  • Comment on Re: mldbm ndbm sdbm gdbm db :: what differences