Where can I get dsquery and other tools useful for debugging Active Directory issues?

For Windows 7, it's part of the Remote Server Administration Tools (RSAT) feature pack:

http://www.microsoft.com/en-us/download/details.aspx?id=7887

This can be used for W2003 and W2008 servers.
Information on how to install these with the dism command can be found in my blog post.

For Windows 8, it's on:

http://www.microsoft.com/en-us/download/details.aspx?id=28972

This one is for managing W2012 servers:

http://www.microsoft.com/en-us/download/details.aspx?id=7887


Even better than dsquery is the adfind and admod tools from joeware

Much more powerful.


On Win2008 and Win2012:

To install Active Directory Domain Services Tools on a server that runs Windows Server 2008 & 2012

Control Panel | Programs and Features | Add/remove Windows Features

Go through wizard to "Add Roles and Features Wizard"

Dig into Features

Click down to: Remote Server Administration Tools, | Role Administration Tools, | Active Directory Domain Services Tools, and then click Next.

Click Install.