Enabling Virtual List View

Virtual List View (VLV) allows you as the LDAP application developer to query a very large directory container in efficient and bite-sized chunks. Virtual List View is enabled by default on eDirectory.

Enabling Virtual List View on Active Directory:

  1. Click Start > Run type Adsiedit.msc, and ENTER.

  2. In the ADSI Edit tool, expand the Configuration[DomainController] node.

  3. Expand the CN=Configuration,DC=DomainName container.

  4. Expand the CN=Services object.

  5. Expand the CN=Windows NT object.

  6. Right-click the CN=Directory Service object.

  7. Click Properties.

  8. In the Attributes list, click msds-Other-Settings > Edit.

  9. In the Values list, click any instance of DisableVLVSupport=x where x is not equal to 0, and click Remove.

  10. Click OK twice. Close the ADSI Edit tool.

Installing schema and sort control:

  1. Open a command prompt and type regsvr32 schmmgmt.dll command, and then press ENTER:

  2. Click Start > Run.

  3. Type mmc and then click OK.

  4. On the File menu, click Add/Remove Snap-in.

  5. In the Available snap-ins field, click Active Directory Schema > Add > OK.

  6. Click on the created schema search for cn → properties → enable. Index this attribute for containerized searches.

Enabling Virtual List View on OpenLDAP:

  1. Bind to the server that you want to perform the search on using ldap_bind or ldap_bind_s.

  2. Set the members for LDAPVLVInfo and create the control using ldap_create_vlv_control.

  3. Create a sort control using ldap_create_sort_control and add it to an array with the VLV control.

  4. Perform a search on the server using ldap_search_ext_s or ldap_search_ext.

  5. Parse the results from the server using ldap_parse_result, then parse the vlv results received from the response control (LDAP_CONTROL_VLVRESPONSE) using ldap_parse_vlv_control.

  6. Free the control using ldap_control_free.