Speeding LDAP Queries against the GC - 16 Jan 2008

John Savill

January 15, 2008

1 Min Read
ITPro Today logo in a gray background | ITPro Today

We're building some applications that query objects from the domains in our forest. As part of the test process, we noticed that some Lightweight Directory Access Protocol (LDAP) queries against the Global Catalog (GC) take much longer than others. What causes this discrepancy, and can we fix it?

The GC server contains a replica of every object in every domain in the forest but stores only some of the attributes for each of those objects. Think of a phone book: It lists the names and addresses of the people in your city, but it doesn't show their height, weight, or eye color. Many attributes in the GC are indexed to speed up queries against them. If your code is searching for an attribute that isn't in the GC or one that's present but not indexed, the query will take an unusual amount of time. The Microsoft article "Default Global Catalog Attributes in Windows 2000 Active Directory Schema" (http://support.microsoft.com/?kbid=256938) lists the indexed attributes. By querying these attributes (or forcing the GC to index the attributes you do use), you can significantly improve your search performance.

— Paul Robichaux

About the Author

Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.

You May Also Like