refactored maintenance/db, since dbm apparently can't handle slightly bigger data...