Transaction support on command line tools
Fix AttributeError when ldap user not found