dumps as binary format, update restore for postgres, fix restore issue