Bug 216866 - kmail doesn't reinitiate imap connections
Summary: kmail doesn't reinitiate imap connections
Status: RESOLVED DUPLICATE of bug 213662
Alias: None
Product: kmail
Classification: Applications
Component: general (show other bugs)
Version: 1.12.2
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-11-30 22:13 UTC by Thierry Chich
Modified: 2010-03-07 23:39 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Thierry Chich 2009-11-30 22:13:15 UTC
Version:           1.12.2 (using KDE 4.3.2)
OS:                Linux
Installed from:    Ubuntu Packages

I have made some networks trace, and I think I understand why kmail seems to stay blocked sometimes, with imap account, TLSized or not.
 When you stay a long time, it is higly probable that the imap account seems to be unreadable. kmail seems to work without end. But, it is not true with all imap account. for instance, gmail accounts don't suffer with kind of problem.
This is due to the way that kmail is dealing with imap connection. It seem to assume that imap conection must be endless. This not true. There is a lot of situation where this hypothesis is incorrect. For instance, if you freeze your laptop, kmail will not be able to maintain the imap connection open, and the server will close it.
 Other case, there is a lot of firewall that have a timeout for tcp connection.
Gmail deal with this kind of problem using the following algorithm: if the server receive a tcp packet that doesn't correspond to a living connection, then it emit a tcp reset. Then kamil reinitiate a new imap session, and it is working.
 But other servers don't work this way. They don't emit tcp reset. They act as there is nothing. It is a simple security measure.
And in this case, kmail try endlessly to reemit the same tcp packet.
It should be a timer that induce the reinitialization of the imap connection.
Comment 1 Jason Oliveira 2009-12-01 16:37:47 UTC
experiencing the same issue. connecting to zimbra-based imap server (01.com), and Kmail's progress meter will stay at 44% while checking for mail. once in this state, Kmail will never update the account until app is restarted. oddly enough, I can check gmail's imap (set up as seperate account/identity) without any issues, even while my main account is hung while updating.
Comment 2 Thierry Chich 2009-12-19 18:20:01 UTC
I just want to say that this drawback/bug of the imap implementation doesn't seem to exist in "disconnected imap".
Comment 3 Sérgio Durigan Júnior 2010-01-21 13:48:23 UTC
I can confirm this bug as well.  I did not try to use the "Disconnected IMAP" option yet; will do that ASAP.
Comment 4 Pal Körössy 2010-02-21 15:29:22 UTC
I've experienced the same problem, in some cases with my (not disconnected) GMail account as well, eg. checking of Inbox hangs while other sub-mailboxes of this account can be read without problem at the same time.
I also experince the problem very often using our own IMAP server on my workplace after resuming my machine from suspend to RAM. 
Only restarting Kmail helps.
Comment 5 Björn Ruberg 2010-03-07 23:39:33 UTC

*** This bug has been marked as a duplicate of bug 213662 ***