blob: 8eacebaf2708e26cd6443f353c78f2945f817ff3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
|
Timeouts
========
Dovecot has a lot of timeouts in various components. Most of them have
hardcoded values, because there's normally no need to change them. Here are
some of them listed:
IMAP
----
* Before login: CLIENT_LOGIN_TIMEOUT_MSECS = MASTER_LOGIN_TIMEOUT_SECS*1000 =
3 minutes (login-common/client-common.h and lib-master/master-interface.h)
* This may be shorter if all the available connections are in use (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
IMAP RFC)
* 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 setting - default every 2 minutes).
* IMAP clients are supposed to send something before 30 minutes are up,
but several clients don't do this. Some Outlook versions even stop
receiving new mails entirely until manual intervention if IMAP server
disconnects the client.
* 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/client.c)
* After login: Disconnect on 20th invalid command (CLIENT_MAX_BAD_COMMANDS
in imap/imap-common.h)
POP3
----
* Before login: CLIENT_LOGIN_TIMEOUT_MSECS = MASTER_LOGIN_TIMEOUT_SECS*1000 =
3 minutes (common with IMAP code)
* This may be shorter if all the available connections are in use (service
imap-login { client_limit * process_limit }). In that case the oldest
non-logged in connection is disconnected.
* After login: CLIENT_IDLE_TIMEOUT_MSECS = 10 minutes
* Dovecot also disconnects an POP3 client that sends too many invalid
commands:
* Before login: Disconnect on 3rd invalid command in v2.2.16+, 11th on
earlier versions (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)
IMAP & POP3 proxies
-------------------
* Dovecot proxy handles IMAP and POP3 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 PROXY_DEFAULT_TIMEOUT_MSECS = 30 secs 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)
(This file was created from the wiki on 2019-06-19 12:42)
|