[Dovecot] IDLE command timeout
Is it possible to change the IDLE command timeout to be more than 30 minutes? I have a client on my PalmOne Treo 600 which will stay in IDLE mode as long as it can. I would like to set the timeout to something much higher than 30 minutes. Maybe several hours or even more.
I don't see a configuration setting for this value in "/etc/dovecot.conf". Am I missing something?
Thanks, -Sim
Isn't this "mailbox_idle_check_interval"?
# Like mailbox_check_interval, but used for IDLE command. #mailbox_idle_check_interval = 30
It might be better to use "imap_client_workarounds = outlook-idle" instead. This pretends a new message has arrived just before the timeout then says it was deleted. Your client is very broken if that doesn't wake it up!
Best Wishes, Chris
Sim Harbert wrote:
Is it possible to change the IDLE command timeout to be more than 30 minutes? I have a client on my PalmOne Treo 600 which will stay in IDLE mode as long as it can. I would like to set the timeout to something much higher than 30 minutes. Maybe several hours or even more.
I don't see a configuration setting for this value in "/etc/dovecot.conf". Am I missing something?
Thanks, -Sim
-- --+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+- Christopher Wakelin, c.d.wakelin@reading.ac.uk IT Services Centre, The University of Reading, Tel: +44 (0)118 378 8439 Whiteknights, Reading, RG6 2AF, UK Fax: +44 (0)118 975 3094
It isn't a matter of the client being broken. My Treo client properly reconnects when the IDLE command is disconnected due to the timeout, but this means it has to reconnect every 30 minutes. I want to avoid the overhead of reconnecting all the time and just stay connected. The reconnections chew up battery life since they involve a lot more wireless network activity than being in IDLE mode.
The "outlook-idle" workaround doesn't help, since it requires a reconnect with the server. Well, maybe it wouldn't require a full reconnect, so I suppose it might be a tiny bit better than the actual IDLE disconnect.
I believe the 'mailbox_idle_check_interval' just gives the minimum time between when the server will notify the client of changes. If set to 30 seconds, that would mean that if mail came 10 seconds apart, then client wouldn't be notified of the second email until 30 seconds after the first. (This is all just based on the short description in the configuration file...)
Is there more extensive documentation of the configuration settings somewhere? The website doesn't document the configuration options.
-Sim
Chris Wakelin wrote:
Isn't this "mailbox_idle_check_interval"?
# Like mailbox_check_interval, but used for IDLE command. #mailbox_idle_check_interval = 30
It might be better to use "imap_client_workarounds = outlook-idle" instead. This pretends a new message has arrived just before the timeout then says it was deleted. Your client is very broken if that doesn't wake it up!
Best Wishes, Chris
Sim Harbert wrote:
Is it possible to change the IDLE command timeout to be more than 30 minutes? I have a client on my PalmOne Treo 600 which will stay in IDLE mode as long as it can. I would like to set the timeout to something much higher than 30 minutes. Maybe several hours or even more.
I don't see a configuration setting for this value in "/etc/dovecot.conf". Am I missing something?
Thanks, -Sim
"You said we're headed to war in Iraq -- I don't know why you say that. I hope we're not headed to war in Iraq. I'm the person who gets to decide, not you." -- http://DubyaSpeak.com/ -- Discounting the roles of Congress and an inquisitive press in order to look tough in front of a reporter (and avoid answering the question), Crawford, Texas, Dec. 31, 2002
Sim Harbert wrote:
It isn't a matter of the client being broken. My Treo client properly reconnects when the IDLE command is disconnected due to the timeout, but this means it has to reconnect every 30 minutes. I want to avoid the overhead of reconnecting all the time and just stay connected. The reconnections chew up battery life since they involve a lot more wireless network activity than being in IDLE mode.
The "outlook-idle" workaround doesn't help, since it requires a reconnect with the server. Well, maybe it wouldn't require a full reconnect, so I suppose it might be a tiny bit better than the actual IDLE disconnect.
It shouldn't cause much traffic, just something like (C:=client, S:=server) :-
C: 1234 IDLE S: + idling
29 minutes later ...
S: * 456 EXISTS C: DONE S: 1234 OK Idle completed. S: * 456 EXPUNGE C: 1235 IDLE S: + idling
etc. I can't be bothered to wait 29 minutes for the exact sequence ;) but it doesn't involve a reconnect.
I believe the 'mailbox_idle_check_interval' just gives the minimum time between when the server will notify the client of changes. If set to 30 seconds, that would mean that if mail came 10 seconds apart, then client wouldn't be notified of the second email until 30 seconds after the first. (This is all just based on the short description in the configuration file...)
Oops, sorry, you're right! The disconnect timeout looks like it's hardcoded in src/imap/common.h, at least in dovecot-1.0-stable (it's specified in the IMAP RFC, I believe), so you'd need to modify it and recompile.
/* Disconnect client after idling this many seconds */ #define CLIENT_IDLE_TIMEOUT (60*30)
Is there more extensive documentation of the configuration settings somewhere? The website doesn't document the configuration options.
-Sim
Not yet, I think. Still, it's a Wiki, so we ought to be able to contribute our own!
Best Wishes, Chris
-- --+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+- Christopher Wakelin, c.d.wakelin@reading.ac.uk IT Services Centre, The University of Reading, Tel: +44 (0)118 378 8439 Whiteknights, Reading, RG6 2AF, UK Fax: +44 (0)118 975 3094
OK, I am turning on the outlook-idle workaround and will try that.
How did someone come up with 30 minutes? Why not 60 minutes? Outlook obviously acts oddly in relation to the server IDLE disconnect thing, but it does seem like there should be some sort of allowance for clients which want to stay in IDLE mode for longer than 30 minutes.
-Sim
Chris Wakelin wrote:
Sim Harbert wrote:
It isn't a matter of the client being broken. My Treo client properly reconnects when the IDLE command is disconnected due to the timeout, but this means it has to reconnect every 30 minutes. I want to avoid the overhead of reconnecting all the time and just stay connected. The reconnections chew up battery life since they involve a lot more wireless network activity than being in IDLE mode.
The "outlook-idle" workaround doesn't help, since it requires a reconnect with the server. Well, maybe it wouldn't require a full reconnect, so I suppose it might be a tiny bit better than the actual IDLE disconnect.
It shouldn't cause much traffic, just something like (C:=client, S:=server) :-
C: 1234 IDLE S: + idling
29 minutes later ...
S: * 456 EXISTS C: DONE S: 1234 OK Idle completed. S: * 456 EXPUNGE C: 1235 IDLE S: + idling
etc. I can't be bothered to wait 29 minutes for the exact sequence ;) but it doesn't involve a reconnect.
I believe the 'mailbox_idle_check_interval' just gives the minimum time between when the server will notify the client of changes. If set to 30 seconds, that would mean that if mail came 10 seconds apart, then client wouldn't be notified of the second email until 30 seconds after the first. (This is all just based on the short description in the configuration file...)
Oops, sorry, you're right! The disconnect timeout looks like it's hardcoded in src/imap/common.h, at least in dovecot-1.0-stable (it's specified in the IMAP RFC, I believe), so you'd need to modify it and recompile.
/* Disconnect client after idling this many seconds */ #define CLIENT_IDLE_TIMEOUT (60*30)
Is there more extensive documentation of the configuration settings somewhere? The website doesn't document the configuration options.
-Sim
Not yet, I think. Still, it's a Wiki, so we ought to be able to contribute our own!
Best Wishes, Chris
"You said we're headed to war in Iraq -- I don't know why you say that. I hope we're not headed to war in Iraq. I'm the person who gets to decide, not you." -- http://DubyaSpeak.com/ -- Discounting the roles of Congress and an inquisitive press in order to look tough in front of a reporter (and avoid answering the question), Crawford, Texas, Dec. 31, 2002
It's in RFC3501 (e.g. http://www.rfc.net/rfc3501.html#s5.4.) that any inactivity autologout timer must be at least 30 minutes, so a client ought to send something every 29 minutes to be sure of not getting disconnected. RFC2177 says this autologout may happen during an IDLE command.
I guess most servers take this as meaning 30 minutes is what's expected, and that Mark Crispin left it up to server implementors to have longer timeouts, but put this limit to warn/protect client writers (and Microsoft and others ignored it!).
Chris
Sim Harbert wrote:
OK, I am turning on the outlook-idle workaround and will try that. How did someone come up with 30 minutes? Why not 60 minutes? Outlook obviously acts oddly in relation to the server IDLE disconnect thing, but it does seem like there should be some sort of allowance for clients which want to stay in IDLE mode for longer than 30 minutes.
-Sim
-- --+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+- Christopher Wakelin, c.d.wakelin@reading.ac.uk IT Services Centre, The University of Reading, Tel: +44 (0)118 378 8439 Whiteknights, Reading, RG6 2AF, UK Fax: +44 (0)118 975 3094
participants (2)
-
Chris Wakelin
-
Sim Harbert