"IMAP Idle" through guam connections are dropped after 300 seconds
Closed, ResolvedPublic


root@kolabfek001a [0] ~ # yum list guam
Installed Packages
guam.x86_64 0.8.3-1.1.el6.kolab_14  @kolab-14-extras-audit

IMAP Idle Connections are closed after 300 seconds if the IMAP connection is
encrypted (direct SSL/TLS or STARTTLS) and the connection goes through guam.

We tested this several times and tcpdump on client shows this on the two last lines of the pcap file:

36	15.483402	TCP	66	60762 > imap [ACK] Seq=601 Ack=4163 Win=41974 Len=0 TSval=51771942 TSecr=1908298286
37	319.012712	TCP	60	imap > 60762 [RST, ACK] Seq=4163 Ack=601 Win=4740 Len=0

Connections on cyrus direct without guam stay open and are not hit by this problem.
Is ther some guam config setting to enable "IMAP Idle" via guam or did we find some bug here?


Ticket Type

Event Timeline

BTW, RFC2177 is talking about re-connecting in 29 minutes, so I suppose guam should set the timeout to 30 minutes.

seigo moved this task from Backlog to Pending on the Guam board.Dec 13 2016, 2:01 PM
ralf added a subscriber: ralf.May 5 2017, 1:48 PM

We have the same problem. Is there a workaround available?

I have pushed a commit to the feature/autodetect_ipv6 branch which turns on keepalive for the socket; there is a corresponding fix on the eimap (imap server connection code) side as well, though I'm not sure that is needed. Hopefully that will resolve the issue as it will try to keep the socket up as long as the other side is still there according to the OS settings for these timeouts. by default on Linux it is 2 hours, which should be plenty.

Needs field testing, however, so if someone is willing to build from that branch and confirm, that'd be great.

pasik added a subscriber: pasik.Nov 25 2017, 2:40 PM
vanmeeuwen lowered the priority of this task from 60 to Normal.Mar 28 2019, 8:12 AM
mollekopf added subscribers: seigo, mollekopf.

Unfortunately missed this for 0.9.6, so I'll pick it up in the next release.

mollekopf closed this task as Resolved.Jan 26 2021, 1:48 PM

The keepalive patch is available sine 0.9.7.

We don't do any special IDLE handling in guam, it's the clients responsibility to reconnect after 29 minutes.