89 — NetworkTimeout

networkingconnectivitytimeout

A network operation timed out while communicating with the server

What is happening?

NetworkTimeout indicates that a network-level operation (connecting, sending, or receiving) did not complete within the configured timeout. This is distinct from MaxTimeMSExpired (50), which is a server-side operation timeout. NetworkTimeout is a client-side or inter-node network issue.

Common causes

  1. Server is overloaded and not responding within the socket timeout
  2. Network latency between client and server is too high
  3. Firewall or load balancer dropping idle connections
  4. MongoDB server process is unresponsive (e.g. during a checkpoint)
  5. DNS resolution is slow

Source code references

ErrorCodes::NetworkTimeout found in 36 locations in the MongoDB server source.

Diagnostic Steps

Related Issues

SERVER-50111Closed
Secondary stuck with old sync source for reporting up to 30 seconds
EDIT: Cancelling the reporter on changing sync source is a more robust solution. syncSourceFeedbackNetworkTimeoutSecs is currently [hardcoded to 30s|https://github.com/mongodb/mongo/blob/eae31861e0f813f0099e1d490c4a622d75cd5a08/src/mongo/db/repl/sync_source_feedback.cpp#L57]. In case of network partition, the sync source feedback report might need to take 30s before timing out on the replSetUpdatePosition remote command against the old sync source even though the node has selected a new sync
SERVER-137322Closed
Disconnecting an LDAP connection after a timed-out SASL bind can deadlock all SASL authentication
h3. Problem SERVER-130785 added a {{disconnect()}} call in {{LDAPRunnerImpl::getConnectionWithOptions}} after any failed bind: If the bind timed out ({{ldapTimeoutMS}}), {{PooledLDAPConnection::runFuncWithTimeout}} has returned {{NetworkTimeout}}, but the bind is still running on an LDAPConnPool thread. {{WrappedConnection::disconnect()}} skips the timeout wrapper and hands the same {{LDAP*}} to the LDAPConnectionReaper, which calls {{ldap_unbind_ext_s}} while the bind is still using it. Wi
NODE-6547Backlog
Flaky: CSOT spec tests - socketTimeoutMS is ignored if timeoutMS is set - MongoNetworkTimeoutError [28]
https://spruce.mongodb.com/task/mongo_node_driver_next_windows_vsCurrent_large_gallium_test_4.2_replica_set_1965ed51296bac9149ecb077b6cafd43150a3a07_24_11_11_17_53_39/logs?execution=0&sortBy=STATUS&sortDir=ASC