default database clean up and fix