Microsoft DS Tools – part 1



Many people afraid of using Microsoft DS Tools. They think that those command-line tools are very complicated and difficult to understand and use. This can be true but (in my opinion) only for couple of minutes. After some short time of using them, everything becomes more clear.

I’m big fan of these tools and I will try to explain, how to use them painless πŸ™‚

First of all, to be able to use Microsoft DS Tools, you need to log on into Domain Controller or install Administrative/RSAT Tools on a workstation or a member server from which you want touse them. To install the tools, you need local administrative privileges on a client machine but to use them, you need to be only “Authenticated User” in a domain in which you want to run a query.

DS Tools can cooperate together. That means, you can pipe the output of one command into another. To use pipe, you have to separate two commands with pipe “|” character. Basically, input of one command can be output for another one.

Microsoft DS Tools contain these commands:

  • dsquery (to query for existing objects in a domain)
  • dsget (to get attributes from existing objects in a domain)
  • dsadd (to add new object in a domain)
  • dsmod (to modify existing objects in a domain)
  • dsmove ( to move existing objects in a domain)
  • dsrm (to remove existing objects in a domain)

above commands are available in all editions of Windows Server 2003 and Windows Server 2008/2008 R2.

From Windows Server 2008 we have also few more tools in a package:

  • dsac (Active Directory Administrative Center)
  • dsacls (to display/modify ACL of existing objects in a domain)
  • dsamain (to review AD database backup)
  • dsdbutil (to perform AD database management)
  • dsmgmt (to manage AD application partitions, FSMO management and metadata cleanup)

For more detailed help of particular command, run

<DS-Tool> /?

i.e. -> dsquery /?

You will see all available contexts for that command microsoft project online alternative. To get more detailed help for a context, you need to run

<DS-Tool> <context> /?

i.e. -> dsquery user /?

So, you can ask yourself “What are they purpose of usage?

When you need to get some object details that is difficult to get using standard GUI tools, you can use them, or if you need to get attributes, create/modify many objects in very few steps, then DS Tools come with their help.

So, try to practice with getting help for these commmands and their context, now. We will discuss DS Tools usage in next posts.

Let’s start new frendship, frendship with Microsoft DS Tools! πŸ˜€


Next part >>>

Author: Krzysztof Pytko


3 responses to “Microsoft DS Tools – part 1”

  1. kflabs says :

    So far, so good! I hope you will become next polish (in pair with Tomasz Onyszko’s AD blogging guru if you will keep that level of continuity knowledge in future. Hi five!

    • iSiek says :

      Thank’s a lot! πŸ™‚
      I will try to keep posting new articles regularly. Many ideas much less time to write :/
      Anyway, thank you for reading my blog


Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.