Search K
Appearance
Appearance
Dovecot has a lot of timeouts in various components. Most of them have hardcoded values, because there's normally no need to change them.
Dovecot proxy handles IMAP, POP3 and Submission pre-login timeouts and invalid error command handling the same as Dovecot backend.
After login the proxy will continue proxying until the client or the backend disconnects.
Connect timeout to backend is governed by login_proxy_timeout
, which is 30 seconds by default.
Can be overridden by proxy_timeout
passdb extra field.
After connection has been established, there's still a login timeout CLIENT_LOGIN_TIMEOUT_MSECS = MASTER_LOGIN_TIMEOUT_SECS*1000
= 3 minutes (login-common/client-common.h
and lib-master/master-interface.h
).
Before login: CLIENT_LOGIN_TIMEOUT_MSECS = MASTER_LOGIN_TIMEOUT_SECS*1000
= 3 minutes (the same as proxies).
[[link,service_configuration,service imap-login { client_limit * process_limit }]]
. In that case the oldest non-logged in connection is disconnected.After login: CLIENT_IDLE_TIMEOUT_MSECS
= 30 minutes (minimum required by RFC 2060 (section 5.4))
If IDLE command is started, Dovecot never disconnects. Only if the connection is lost there will be a disconnection. A dead connection is detected by Dovecot periodically sending "I'm still here" notifications to client (imap_idle_notify_interval
, default every 2 minutes).
Dovecot also disconnects an IMAP client that sends too many invalid commands:
Before login: Disconnect on 3rd invalid command (CLIENT_MAX_BAD_COMMANDS
in imap-login/imap-login-client.c
.
After login: Disconnect on 20th invalid command (CLIENT_MAX_BAD_COMMANDS
in imap/imap-common.h
.
Before login: CLIENT_LOGIN_TIMEOUT_MSECS = MASTER_LOGIN_TIMEOUT_SECS*1000
= 3 minutes (same as proxies).
service pop3-login { client_limit * process_limit }
). In that case the oldest non-logged in connection is disconnected.After login: CLIENT_IDLE_TIMEOUT_MSECS
= 10 minutes (pop3/pop3-client.c
.
Dovecot also disconnects an POP3 client that sends too many invalid commands:
Before login: Disconnect on 3rd invalid command (CLIENT_MAX_BAD_COMMANDS
in pop3-login/client.c
.
After login: Disconnect on 20th invalid command (CLIENT_MAX_BAD_COMMANDS
in pop3/pop3-client.c
.
Before login: CLIENT_LOGIN_TIMEOUT_MSECS = MASTER_LOGIN_TIMEOUT_SECS*1000
= 3 minutes (submission, same as proxies).
service submission-login { client_limit * process_limit }
). In that case the oldest non-logged in connection is disconnected.After login: CLIENT_IDLE_TIMEOUT_MSECS
= 5 minutes for LMTP and 10 minutes for Submission. lmtp/lmtp-client.c
and submission/submission-client.c
.
Dovecot also disconnects an SMTP client that sends too many invalid commands:
Before login: Disconnect on 10th invalid command. (CLIENT_MAX_BAD_COMMANDS
in submission-login/client.c
.
After login: Disconnect on 20th invalid command (CLIENT_MAX_BAD_COMMANDS
in submission/submission-client.c
.