Microsoft Exchange Transport service stops and returns Event ID 17018
Symptoms
On a server that's running Microsoft Exchange Server and that has a high CPU core count and a high transport load, the Microsoft Exchange Transport service continually stops and restarts. Additionally, the following event is logged in the Application log:
Source: MSExchangeTransport
Event ID: 17018
Transport Mail Database: There are insufficient resources to perform a database operation. The Microsoft Exchange Transport service is shutting down.
Exception details: Microsoft.Isam.Esent.Interop.EsentOutOfSessionsException: Out of sessions at Microsoft.Isam.Esent.Interop.Api.JetBeginSession(JET_INSTANCE instance, JET_SESID& sesid, String username, String password) at Microsoft.Exchange.Transport.Storage.DataConnection..ctor(JET_INSTANCE instance, IDataSource source)
Cause
This issue occurs because a high number of server-to-server connections can exhaust the session limit too quickly.
Resolution
Note
This fix applies to only Microsoft Exchange Server 2019.
To fix this issue, follow these steps:
Install the following security update:
Decrease the
MaxInboundConnection
limit on the Receive connectors of each Exchange server, as follows.Note
To prevent limiting the number of connections from busy sources, such as email gateways, you might have to increase the
MaxInboundConnectionPercentagePerSource
parameter from the default value of 2. We recommend that you also closely monitor the incoming mail flow and gradually increase the value, as necessary.To check the current value of the
MaxInboundConnection
parameter, run the Get-ReceiveConnector cmdlet:Get-ReceiveConnector -Server <Server Name> | Format-Table Identity,MaxInboundConnection -Auto
Note: The default value for this limit is 5,000 concurrent connections.
To set the limit to a value of 1,000 concurrent connections, run the following cmdlets:
Get-ReceiveConnector -Server <Server Name> | Set-ReceiveConnector -MaxInboundConnection 1000
To set each Receive connector limit individually, run the Set-ReceiveConnector cmdlet:
Set-ReceiveConnector -Identity "<Receive Connector Identity>" -MaxInboundConnection 1000
Restart the Transport service.
Override the server-to-server throttle. To set and refresh the override, run the New-SettingOverride and Get-ExchangeDiagnosticInfo cmdlets in Exchange Management Shell:
New-SettingOverride -Name "Throttle server to server inbound calls" -Component TransportConfiguration -Section ThrottleServerToServerInboundConnections -Parameters ("Enabled=True") -Reason "Any Text String " Get-ExchangeDiagnosticInfo -Process Microsoft.Exchange.Directory.TopologyService -Component VariantConfiguration -Argument Refresh
Restart the Transport service.