Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 278
  • Last Modified:

Query regarding AD import

Hi

We are running a Windows 2003 Active Directory forest, comprising of two domains.

The forest root is kam.com, the domains are uk.kam.com and us.kam.com

We have a new application and we'd like to import a list of users from our AD forest.

Does anyone know how to do this and what sort of permissions the account that runs the query will need?

Thanks!!
0
kam_uk
Asked:
kam_uk
  • 3
  • 2
1 Solution
 
kam_ukAuthor Commented:
...and if we need to import data from the forest, do we need to set the application to query a Global Cat Domain Controller, and why?
0
 
Henrik JohanssonSystems engineerCommented:
Depends of the format of requested data, but you can use csvde, ldifde or dsquery/dsget to export the data.

csvde -f export.csv -d "DC=uk,DC=kam,DC=com" -r "(ldap-filter-criteria)" -l "field list"
csvde -f export.csv -d "DC=uk,DC=kam,DC=com" -r "(ldap-filter-criteria)" -l "field list"
dsquery user DC=uk,DC=kam,DC=com
dsquery user DC=uk,DC=kam,DC=com|dsget user -samid

see 'csvde /?', 'ldifde /?', 'dsquery user /?', 'dsget user /?' for help of the commands
0
 
kam_ukAuthor Commented:
thanks...and what sort of user permissions would the account that pulls this information need?
0
 
Henrik JohanssonSystems engineerCommented:
No special permissions should be necessary. If user has logon access to AD-domain, he has normally also read access to the requested objects/attributes.

I forgot to mention one thing about dsquery command. You may nead to add '-limit 0' as argument to the command or you will by default only get the first 100.

0
 
kam_ukAuthor Commented:
...and if we need info for the entire forest, do we need to query a GC, or will any DC do?
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now