Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re: mldbm ndbm sdbm gdbm db :: what differences

by deliria (Chaplain)
on Nov 06, 2004 at 17:26 UTC ( #405788=note: print w/replies, xml ) Need Help??


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

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://405788]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (2)
As of 2021-11-29 06:33 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?