[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

AD Pull

Posted on 2009-04-06
5
Medium Priority
?
248 Views
Last Modified: 2013-12-24
I need to pull the following fields out of AD, and I am trying to use csvde.  Not sure if that is the best way to go, but I don't see the fields that I need. Can anyone send me the correct tags to pull the following information?  Or if you have a better option, that would help too.
I need:
First Name, Last Name, Email, ExternalAccountUID,account name, manager name, Department, City, Office, Telephone Number, and Title.  

Thanks.
0
Comment
Question by:norwoodhelpdesk
  • 2
  • 2
5 Comments
 
LVL 57

Accepted Solution

by:
Mike Kline earned 2000 total points
ID: 24081800
I like a tool called adfind by MVP Joe Richards
http://www.joeware.net/freetools/tools/adfind/index.htm
try
adfind -default -f  "&(objectcategory=person)(objectclass=user)" cn sn mail samaccountname manager department L physicaldeliveryofficename telephonenumber title  -nodn -csv > c:\users.csv
That will create the users.csv on your C drive.  Let me know how that works.
On another note I always like the "L" for city (not intuitive), more on that here:  http://msdn.microsoft.com/en-us/library/ms676817(VS.85).aspx
 
Thanks
Mike
0
 

Author Comment

by:norwoodhelpdesk
ID: 24086668
Good tool, that is really close.  I need a few more things from your pull.  it gave me full name, and I need first name for the first column, also I need the ExternalAccountUID (Ex. S-1-5-21-2261097160-2633569310-2490458840-1125).  Can this tool pull those for me?  What would the tags for those fields be?
0
 
LVL 3

Expert Comment

by:qualchoice-it
ID: 24086850
Hi mkline71, that's the exact tool I was looking for as well, but its pulling back EVERYTHING as far as users, even my disabled ones.  I'm trying to get a process put together for our DBA's to publish a phone report to our companies Intranet.  Would you know what the commands are to run a cleaner report?  Basically just pull the information from specific OU's in my AD?  thanks for your valuable input so far.  
0
 

Author Comment

by:norwoodhelpdesk
ID: 24087131
I found the fields and got what I needed.  Thanks so much for the direction to the tool!!!
0
 
LVL 57

Expert Comment

by:Mike Kline
ID: 24089412
Glad to help out
@qualchoice
If you just want to search through an OU you have to specifiy that in base (using the -b switch).  Need to specifiy the DN of the OU.
So lets say my OU= testOU and my domain was MKtest.com
adfind -b OU=testou,DC=mktest,dc=com -f ...rest is the same
Thanks
Mike
0

Featured Post

Simplify Active Directory Administration

Administration of Active Directory does not have to be hard.  Too often what should be a simple task is made more difficult than it needs to be.The solution?  Hyena from SystemTools Software.  With ease-of-use as well as powerful importing and bulk updating capabilities.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Eseutil Hard Recovery is part of exchange tool and ensures Exchange mailbox data recovery when mailbox gets corrupt due to some problem on Exchange server.
Exchange administrators are always vigilant about Exchange crashes and disasters that are possible any time. It is quite essential to identify the symptoms of a possible Exchange issue and be prepared with a proper recovery plan. There are multiple…
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…
This is a high-level webinar that covers the history of enterprise open source database use. It addresses both the advantages companies see in using open source database technologies, as well as the fears and reservations they might have. In this…
Suggested Courses

834 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question