in reply to Dump In-memory DB_File to disk

My suggestion is avoid in-memory database from beginning.

Writing In-Memory Berkeley DB Applications