Adjusting the maximum number of open objects that a MAPI client can use at the same time
Problem:
You experience problems related to Exchange Server limitations. Click the links below to learn more and get solutions.
- You are having problems when synchronizing big sets of changes (>250)
- You are not able to synchronize more than 32 folders
Solution:
Problems when synchronizing big sets of changes (>250)
(MAPI session limits)
In Exchange Server, the number of message objects that can be opened by a single MAPI session is limited to 250. This limitation can cause problems with syncing of folders that contain a large number of elements. Use the links below to learn about the most common problems.
Errors MAPI_E_CALL_FAILED and MAPI_E_TOO_BIG
Problems might occur when there is a large number of elements (> 250) in a synchronized folder. For example, when a user changes the category of e.g. 500 elements in the source folder in one step, part of the changed elements will not be synchronized in the target folder due to the MAPI limitations. The following error(s) will occur in the software's log files:
Error: Failed to open message from table notification. MAPI_E_CALL_FAILED
Error: Failed to open message from table notification. MAPI_E_TOO_BIG
This problem can be solved in the Registry Editor by adding a value that contains a new number of maximum message objects that are allowed to be opened in a single MAPI session. Make sure that your account belongs to the Local Administrators group and follow these steps:
- Go to the Registry Editor (regedit) of each of the MS Exchange Servers where the MS Exchange Information Store service is running (Mailbox role servers).
- Locate the registry key:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\MSExchangeIS\ParametersSystem
- Right-click ParametersSystem, choose New, then click Key.
- Type MaxObjsPerMapiSession and press Enter.
- Now right-click MaxObjsPerMapiSession, choose New > DWORD Value.
- Type the object type (for example objtMessage) and press Enter to name the entry that changes the default maximum number of objects.
- Right-click the entry you created and click Modify.
- Go to the Value data box and type the new maximum number of objects to which you want to limit this entry.
Important
We recommend to set the maximum value, 2500 (decimal), to solve the problem. If necessary, you can type smaller values and see if they work.
- Click OK.
- Apply the changes:
- Exchange Server 2003: reboot the machine.
- Exchange Server 2007: the changes should be recognized automatically after 5 minutes. If not, reboot the machine.
- Exchange Server 2010 and newer: restart the MS Exchange Information Store service, or reboot the machine.
You can learn more from the following Microsoft articles:
Error MAPI_E_FAILONEPROVIDER
Another problem might occur, for example, when the software is processing over 250 mailboxes at the same time. In such a case, you might find the following phrase in the log files of your CodeTwo program:
MAPI_E_FAILONEPROVIDER (0x8004011d)
To solve this problem, you need to reconfigure your Exchange server. Follow the steps below:
- Open the following registry key:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\MSExchangeIS\ParametersSystem
- Add the following DWORD entries with a value greater than 10 000 (which is the default limit):
- Maximum Allowed Exchange Sessions Per Service
- Maximum Allowed Sessions Per User
- Maximum Allowed Service Sessions Per User
Important
We recommend setting the maximum value, 65536 (decimal), to all three entries above. If necessary, you can type smaller values and see if they fix the issue.
- Add a DWORD entry named Maximum Allowed Concurrent Exchange Sessions Per Service with a decimal value higher than 16. We recommend that you set the maximum value, 128 (decimal). If necessary, you can type smaller values and see if they work.
- Add a DWORD entry named Disable Session Limit with the decimal value of 0.
- If you are running Exchange 2007, add an extra new DWORD entry named RPC Throttling Factor with the value 5000 (decimal).
- Apply the changes:
- Exchange Server 2003: reboot the machine.
- Exchange Server 2007: the changes should be recognized automatically after 5 minutes. If not, then reboot the machine.
- Exchange Server 2010 and newer: restart MS Exchange Information Store service, or reboot the machine.
Additionally, if you are running CodeTwo Exchange Sync, configure it to use multiple RPC connections while contacting your Exchange server:
- Go to the Registry Editor (regedit) of the machine where CodeTwo Exchange Sync is installed.
- Locate the following registry key:
- In 32-bit operating systems:
HKEY_LOCAL_MACHINE/Software/CodeTwo/ExchangeSync
- In 64-bit operating systems:
HKEY_LOCAL_MACHINE/Software/Wow6432Node/CodeTwo/ExchangeSync
- In 32-bit operating systems:
- Right-click on it, choose New > DWORD Value.
- Name it UseSeparateRPCConnections and press Enter.
- Once again, right-click on the registry value specified in step 2., and choose Modify:
Change Base to Decimal.
- Modify Value Data to 1.
- Click OK to confirm the changes.
- Restart the synchronization service.
- Go through the service log files and check if you see the following entry:
Profile section set with CONNECT_USE_SEPARATE_CONNECTION flag
You are not able to synchronize more than 32 folders
(Exchange throttling limits)
Regardless of the above-described MAPI limits, MS Exchange Server applies throttling to the synchronization actions of CodeTwo Exchange Sync. If you configure 32 or more folders in your synchronization tasks, the throttling policy may affect the MAPI processing in CodeTwo software. As a result, the following errors appear in the software's log files:
Error: Failed to open message store "<MailboxName>\<FolderName>"/ MAPI_E_FAILONEPROVIDER (0x8004011d). module: FoldersGroupCreator.cpp, line: 259, func: CFoldersGroupCreator::operator ()
To overcome this issue, an administrator has to increase the RcaMaxConcurrency limit. This problem is described in two Microsoft articles: here and here.
Below you can find an example of how to apply unlimited RcaMaxConcurrency settings.
- Log on to your MS Exchange Server machine.
- Run the Exchange Management Shell.
- Execute the cmdlet below to create a new throttling policy. Change YourNewPolicyName to any name of your choice.
- Exchange Server 2010:
New-ThrottlingPolicy -Name YourNewPolicyName -RCAMAXConcurrency $null
- Exchange Server 2013:
New-ThrottlingPolicy -Name YourNewPolicyName -RCAMAXConcurrency Unlimited
- Exchange Server 2010:
- Execute the cmdlet below to assign the newly created throttling policy to the mailbox of the user whose account will be used by the synchronization service. Change MailboxName to the name of the desired mailbox.
Set-Mailbox -identity MailboxName -throttlingpolicy YourNewPolicyName
- Restart the CodeTwo Exchange Sync synchronization service.
See also:
Related products: | CodeTwo Exchange Sync |
Categories: | Troubleshooting |
Last modified: | May 7, 2019 |
Created: | March 18, 2010 |
ID: | 137 |