add db dump, fix logout bug