IMAP: got response tag unexpectedly: F00059
I changed in camel-network-service.c:network_service_connect_sync() g_socket_client_set_timeout (client, 90 → 10); twice and told the IMAP server to do on every fifth command after the authentication is completed delay of 15 sec (if (random() % 5 == 1) sleep(15);
). The delay is made, before the client can enter commands. Once entered commands are not delayed further.
Evolution is told to use only one TCP connection for the account.
I started evolution with CAMEL_DEBUG=imapx:io,imapx:conman
. It prints
[imapx:F] I/O: 'F00058 UID FETCH 1305 (BODY.PEEK[])'
[imapx:F] I/O: '* 1305 FETCH (UID 1305 BODY[] {15095}
Return-Path: …
-------cBjQukR75mHaaQp2-1490886922--'
[imapx:F] I/O: ')
F00058 OK Completed (0.001 sec)'
[imapx:F] I/O: 'F00059 SELECT A/B/C (QRESYNC (1148510473 759339 1:29011 (1,8776,21898,26272,27730,28216,28378,28432,28450 1,8985,22390,26810,28282,28768,28930,28984,29002)))'
[imapx:F] I/O: 'F00060 SELECT INBOX (QRESYNC (1084544768 759349 56140:283925 (1,774,1260,1422,1476,1494 56140,234335,272029,281118,283642,283897)))'
[imapx:F] I/O: '* OK [CLOSED] Ok
* 28459 EXISTS
* 1 RECENT
* FLAGS (\Answered \Flagged \Draft \Deleted \Seen Junk NonJunk $Forwarded $MDNSent $NotJunk)
* OK [PERMANENTFLAGS (\Answered \Flagged \Draft \Deleted \Seen Junk NonJunk $Forwarded $MDNSent $NotJunk \*)] Ok
* OK [UNSEEN 28372] Ok
* OK [UIDVALIDITY 1148510473] Ok
* OK [UIDNEXT 29012] Ok
* OK [HIGHESTMODSEQ 759347] Ok
* OK [URLMECH INTERNAL] Ok
* OK [ANNOTATIONS 65536] Ok
* 28458 FETCH (FLAGS (\Seen) UID 29010 MODSEQ (759341))
* 28459 FETCH (FLAGS (\Recent \Seen) UID 29011 MODSEQ (759347))
F00059 OK [READ-WRITE] Completed'
[imapx:F] Removed connection 0x1a62b20 (server:0xbeaa40) due to error: Failed to select mailbox: got response tag unexpectedly: F00059
[imapx:F] I/O: ''
[New Thread 0x7fff6a87a700 (LWP 4282)]
[imapx:G] I/O: '* OK [CAPABILITY IMAP4rev1 LITERAL+ ID ENABLE STARTTLS LOGINDISABLED] mail.aegee.org Cyrus IMAP 3.0.11-91-geb3fa3e0d server ready'
[imapx:G] I/O: 'G00061 STARTTLS'
[imapx:G] I/O: 'G00061 OK Begin TLS negotiation now'
[imapx:G] I/O: ''
[imapx:G] I/O: 'G00062 CAPABILITY'
Is this a problem with the IMAP client or with the IMAP server?
Edited by Дилян Палаузов