Active Directory Paging Not Working - Needs to be enabled server side?

Hello, I've been developing a mass password reset application written in Java SE 1.5 ( Desktop ), and it often needs to hit more than 1000 accounts. Early in development, I hit the 1000 returned record limit which is standard with Active Directory, and I got around it using information from this post - http://forum.java.sun.com/thread.jspa?threadID=578347&tstart=0 .

However, after I had fixed that issue, my test set of user accounts was down to 3, as I developed and tested other features of the application. When I was doing the final testing before going live with the application, Active Directory again refused to return more than 1000 records. Instead, it ignores the range I give it and continues to return the same 1000 records over and over ad infinitum.

Again, this happened without my changing a line of the code that queried active directory, so I think something may have been changed by our Windows Administration group. However, I would like to be sure of this before pointing the finger at them, blaming them for causing this issue.

More importantly, if someone here knows if it is possible to disable paging altogether in Active Directory, and what I should ask the Windows Admins to re-enable in order to fix it.

If that will not work, then I am looking at rewriting some or all of the app in CSharp, which will probably let me access Active Directory in a way that bypasses the 1000 result limit without needing to page.

Thank You,

John Gooch

[1517 byte] By [jagoocha] at [2007-11-26 18:41:53]
# 1

I'm a little confused with your error, are you using paged results or range retrieval ?

If you are using range retrieval (for example returning the members of a group via the group's member attribute), are you sure that you are incrementing the range value correctly during each iteration of retrieving the attributes ?

If you are using paged results, are you processing the returned PagedResults control correctly ?

If you can't find any errors in your code, then perhaps your system admins may have made some configuration changes. There is nothing you need to do to enable paged results or range retrieval and to the best of my knowledge, there is no way to turn off either.

However you can change the maximum page size and the maximum range size. These values are the "MaxPageSize" and "MaxValRange" that are set by the LDAP Query Policies that apply to a site, domain or individual server, or if not set, revert to default values.

Your system admins can check these values from either the ntdsutil tool, or the Windows Resource Kit script which IIRC was called ldapmodify.vbs

Good luck.

adler_stevena at 2007-7-9 6:15:53 > top of Java-index,Core,Core APIs...