The Exchange system attendant logs 1031 and 1032 after generating an Offline Address Book

There are times where an Exchange server's system attendant will stop generating an Offline Address Book and the system attendant will log the following errors:

Event Type: Error
Event Source: MSExchangeSA
Event Category: General
Event ID: 1031
Description: One of the System Attendant's task is blocked. Function: COffLineABScanTask::Work
For more information, click https://www.microsoft.com/contentredirect.asp.

Event Type: Information
Event Source: MSExchangeSA
Event Category: General
Event ID: 1032
Description: One of the System Attendant's task has recovered from a long delay. Function: COffLineABScanTask::Work
For more information, click https://www.microsoft.com/contentredirect.asp.

Before I get in to why this happens I want to give you a refresher on how the OAB Generation process works.

  1. An Offline Address Book can be generated either by schedule or manually.
  2. The system attendant will use it's system profile and initialize the address book provider and make a connection to the active directory. This connection is made via the NSPI interface from the Exchange server to the domain controller's LSASS service.
  3. LSASS is responsible for looking at the ACL's and ACE's to verify that we have proper rights to read from the active directory containers (The Global Address List).
  4. All results are returned from the Active Directory domain controller back to the the OAB Generation server.
  5. At the end of the query the OAB Generation server will either post the files to a public folder store and or a public folder store and local distribution point (for Exchange 2007).

Now there are a few reasons why this error can be logged.

  1. In Microsoft Exchange Server 2003 and 2007, the Exchange System Attendant Service generates offline address book files continually. In hosting environments a large amount of organizations can exist and each one needs to be rebuilt. There are often times where this generation runs longer than 24 hrs and we end up queuing the next OAB generation because we are not finished.
  2. You can have a tremendous amount of users in your organization (non hosting). The largest one that I have seen has over 2 million objects in the gal. In this case the OAB Generation process take about 9 - 13 hours per OAB (OAB Version 2, OAB Version 3 and OAB Version 4). This will span longer then 24 hours resulting in the above mentioned errors.
  3. You are having problems with your domain controller which is serving the data request. At this point the system attendant has to wait on the domain controller and this can be logged.

How to fix for non hosting organizations
1. Make sure that if you have a more than 2 million objects in your global address list that you break this down to smaller address lists. Your OAB Generation process time must not exceed 24 hours.

2. Make sure that all of your Outlook clients are on Outlook 2003 SP2. One the exchange server make sure that you change the doOABVersion so you are only building the OAB Version 4. OAB Version 4 has about a 40% reduction in size and this will stop you from building all 3 versions which will cut down on the generation time.

How to change the doOABVersion to specify which OAB Version you want your OAB Generation server to build
Use an Active Directory editor, such as ADSI Edit, to locate the CN=Offline Address Lists object in Active Directory.

The Offline Address Lists object can be found at: CN=Configuration, CN=Services, CN=Microsoft Exchange, CN=<OrganizationName>, CN=Address Lists Container, CN=Offline Address Lists

Under CN=Offline Address Lists, open the properties of the offline address list object for which you want to specify the versions of offline address book to be generated. For example, to specify the versions of offline address book to be generated for the Default Offline Address List using ADSI edit, double-click CN=Default Offline Address List.

Edit the value for the doOABVersion attribute to specify the offline address books that you want to be generated. For example, to edit the value for doAOBVersion of the Default Offline Address List using ADSI Edit, in CN=Default Offline Address List Properties, select doOABVersion, and then click Edit.

Use the following table to help you specify the appropriate value for your organization.

Decimal  Binary  Versions generated 
0 0000       OAB Versions 2, 3a, and 4
6 0110 OAB Version 4
2 0010 OAB Versions 3a and 4
1 0001 OAB Version 1, 2, 3a, and 4 (This is the default)

3. Turn up Active Directory Domain Controller Diagnostic logging to make sure that your domain controllers are not having any problems. For more information you can see this blog: https://blogs.msdn.com/dgoldman/archive/2007/02/02/how-to-configure-active-directory-diagnostic-logging-for-windows-2000-and-windows-2003.aspx

How to fix for a hosting organizations
1. This problem can occur when a Microsoft Solution for Hosted Messaging and Collaboration deployment tool sets an incorrect registry value. By default, Microsoft Solution for Hosted Messaging and Collaboration 3.0, 3.5 and 4.0 run the Heoabupdate.exe tool to generate new offline address book files one time per day.

Additionally, the tool sets a registry value to make sure that the Exchange System Attendant Service generates the offline address book files according to the schedule of the Exchange System Attendant Service. However, if this registry value is set incorrectly, the Exchange System Attendant Service generates offline address book files continually.

You will need to set the following registry key on all servers that are hosting the offline address book files:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\MSExchangeSA\Parameters\Disable OABScanTask

WARNING: Serious problems might occur if you modify the registry incorrectly by using Registry Editor or by using another method. These problems might require that you reinstall the operating system. Microsoft cannot guarantee that these problems can be solved. Modify the registry at your own risk.

1. Click Start, click Run, type regedit, and then click OK. 
2. Locate the following registry subkey:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\MSExchangeSA\Parameters\Disable OABScanTask
3. Locate the DisableOABScanTask registry entry.
4. Right-click DisableOABScanTask, and then click Rename.
5. Type Disable OABScanTask, and then press ENTER.

Important Make sure that there is a space character between "Disable" and "OABScanTask."

6. Right-click Disable OABScanTask, and then click Modify.
7. In the Edit DWORD Value dialog box, click Decimal under Base. 
8. In the Value data box, type 1, and then click OK. 
9. Close Registry Editor.

Note When you set the "Disable OABScanTask" registry value to 1, you disable the OABScan task. If you want to enable the OABScan task, set the "Disable OABScanTask" value to 0 (zero). Alternatively, remove the "Disable OABScanTask" registry value.

Dave