Created
February 1, 2013 18:52
-
-
Save russom-woldezghi/4693240 to your computer and use it in GitHub Desktop.
Export Active Directory users accounts details such as email, username, objectid, etc.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dsquery * domainroot -filter "(&(objectCategory=Person)(objectClass=User))" -attr cn displayName givenName sn userPrincipalName sAMAccountName mail ProfilePath scriptPath homeDrive homeDirectory uniqueMember canonicalName distinguishedName objectSid legacyExchangeDN description -limit 0 > "C:\Path\to\files\All_Users.txt" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment