Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

dsquery tool

Status
Not open for further replies.

SjrH

IS-IT--Management
Jun 24, 2003
747
GB
Is there such a tool that I can use to query a Windows 2000 AD to show me inactive computer accounts within the domain?

I can use dsquery computer -inactive 8 on a 2003 AD which will show my all computer accounts that are inactive for 8 weeks or more, but dsquery isnt part of 2000 :(

I've only a handful of systems still to migrate so not much point in writing a script to do it if theres a handy little tool that I could use.

Thanks
 
A custom LDAP query which enumerates computers that are disabled within Active Directory comes to mind.
1. Go to ADUC -> right-click your domain -> Choose Find...
2. In the Find: Drop down box choose "Custom Search"
3. Click on the Advanced Tab and Paste the following in the LDAP query:
Code:
(&(objectCategory=computer)(objectClass=computer)(userAccountControl:1.2.840.113556.1.4.803:=2))

What the code does is searches for all computers that have the setting of disabled.



Jesse Hamrick
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top