[horde] AS email not current

Simon Wilson simon at simonandkate.net
Mon Mar 4 11:45:45 UTC 2013


>>> Quoting Simon Wilson <simon at simonandkate.net>:
>>>
>>>>> Quoting Simon Wilson <simon at simonandkate.net>:
>>>>>
>>>>>>>> On 02/03/2013 4:22 AM, Simon Wilson wrote:
>>>>>>>>> But if I delete emails in Imp, the deleted messages are not  
>>>>>>>>> sync'ed, and those emails continue to show in the iOS devices
>>>>>>>>
>>>>>>>> http://wiki.horde.org/ActiveSync
>>>>>>>>
>>>>>>>> "Deleting from a MUA: If the MUA is not configured to move  
>>>>>>>> messages to the trash, and instead just flags them as  
>>>>>>>> deleted, these message deletions will NOT be synched to the  
>>>>>>>> ActiveSync client, as there is no equivalent command in the  
>>>>>>>> protocol. These messages will only be removed from the  
>>>>>>>> ActiveSync client once expunged from the mailbox. This is in  
>>>>>>>> accordance with the ActiveSync protocol specs.
>>>>>>>>
>>>>>>>> *If you wish to ensure all message deletions are synched  
>>>>>>>> quickly to the device, you should configure the use of a  
>>>>>>>> Trash folder.*"
>>>>>>>>
>>>>>>>> --
>>>>>>>> Horde mailing list
>>>>>>>> Frequently Asked Questions: http://horde.org/faq/
>>>>>>>> To unsubscribe, mail: horde-unsubscribe at lists.horde.org
>>>>>>>
>>>>>>> As per my other reply, Imp is configured to move to trash  
>>>>>>> folder, and purge from Inbox.
>>>>>>>
>>>>>>> It does not just flag as deleted.
>>>>>>>
>>>>>>> Simon
>>>>>>> --
>>>>>>
>>>>>> OK - did an experiment... deleting an email on the same iOS  
>>>>>> device in Apple Mail (via a direct IMAP connection), and the  
>>>>>> resultant sync back to the AS email connection removes the  
>>>>>> deleted email correctly.
>>>>>>
>>>>>> Delete an email in Imp and it does not.
>>>>>>
>>>>>> My Imp's mail deletion prefs are set as per following screen shot:
>>>>>>
>>>>>> http://www.simonandkate.net/impprefs.png
>>>>>>
>>>>>> So what is happening in Imp that it is not flagging those  
>>>>>> deletions back through AS?
>>>>>
>>>>> Not sure. Those settings are correct.
>>>>> --
>>>>> mike
>>>>>
>>>>
>>>> :( troubleshooting suggestions?
>>>>
>>>> If I empty the AS log, delete an email in Imp, and post the sync  
>>>> log will that help?
>>>
>>> I doubt it, though I'll look at it if you send it me. The device  
>>> is not being told to remove the email, so it won't be in the log.
>>>
>>>> What about Imap log for the delete transaction?
>>>
>>> Not really. The email is obviously being removed from your INBOX  
>>> since you no longer see it in IMP (or other MUA).
>>>
>>>> What is the process that a delete triggers?
>>>
>>> This happens in one of two ways depending on the features of your  
>>> IMAP server. If you don't support CONDSTORE or per-mailbox MODSEQ  
>>> values (which, if I remember right from looking at your log, is  
>>> your case) - we basically compare the UID list that we have cached  
>>> in the ActiveSync state with what the IMAP server returns as being  
>>> present in the mailbox. Anything not listed in the IMAP server's  
>>> list of UIDs, but present in the ActiveSync list is removed from  
>>> the device.
>>>
>>>
>>>
>>>> Does AS care WHERE the email is deleted to? I have Cyrus IMAP  
>>>> with a "Deleted Items" folder that Imp calls Trash, seems to  
>>>> function fine. Should I be using virtual trash in Imp?
>>>
>>> It doesn't matter. From the point of view of ActiveSync, the  
>>> message is just vanished from the INBOX (or whatever folder we are  
>>> talking about). Adding it to the Deleted Items/Trash/Whatever  
>>> folder is a separate operation.
>>>
>>>
>>>
>>> -- 
>>> mike
>>>
>>
>> Thanks Mike. You know how much I hate it when things start working  
>> by themselves with no change????? Lots.
>>
>> I tried today in Outlook with an IMAP connection to my mailbox.  
>> Deleted some emails. When my iOS devices next connected, the  
>> mailbox changes (deletions) were correctly sent through. So that is  
>> with both Apple Mail and MS Outlook 2010 that deletions in other  
>> MUAs are correctly sync'ed through AS.
>>
>> Then tried in Imp again. And it updated. :-O
>>
>> Man I hate that.
>>
>> I haven't changed ANYTHING.
>>
>> Anyway, apologies for the noise, I'll monitor and see if it reoccurs.
>>
>> Simon.
>>
>
> I spoke too soon. It was updating automatically for a while, then  
> stopped again.
>
> At this stage I have one email that ActiveSync thinks is there but  
> that isn't.
>
> I have confirmed that the email does NOT exist in the Cyrus  
> partition, so the IMAP delete has successfully completed.
>
> Is there any way to see what UIDs ActiveSync has cached, and what it  
> is getting from IMAP to compare?
>
> I then deleted a second email from Imp, and it also hung up...  
> deleted OK on the Cyrus partition, but AS still thinks it's there.
>
> Third email deleted then from Outlook - and it also hung up... as  
> per last one, gone in Cyrus, AS still thinks it's there.
>
> Sounding to me like AS caching something incorrectly reading the  
> Cyrus list. Could it be related to bug 11115?
>
> Simon
>

I have the following set in backends.local.php. Cache was set to true,  
but setting to false hasn't changed anything. :

<?php

$servers['imap'] = array(
     'disabled' => false,
     'name' => 'Cyrus IMAP Server',
     'hostspec' => 'server04.simonandkate.lan',
     'hordeauth' => true,
     'protocol' => 'imap',
     'secure' => 'tls',
     'port' => 143,
     'quota' => array(
         'driver' => 'imap',
         'params' => array(
                 'hide_quota_when_unlimited' => true,
                 'unit' => 'MB'
          )
     ),
     'maildomain' => 'simonandkate.net',
     'acl' => true,
     'cache' => false,
//    'debug' => ($GLOBALS['registry']->getAuth() == 'simon') ?  
'/var/log/hordeas/impdebug' : false,
     'debug' => '/var/log/hordeas/impdebug',
     'debug_raw' => false,
);

Setting Impdebug gives some info...

Initial connection:

------------------------------
>> Mon, 04 Mar 2013 21:12:28 +1000
S: * OK [CAPABILITY IMAP4 IMAP4rev1 LITERAL+ ID STARTTLS  
LOGINDISABLED] server04.simonandkate.lan Cyrus IMAP4  
v2.3.7-Invoca-RPM-2.3.7-12.el5_7.2 server ready
C: 1 STARTTLS
S: 1 OK Begin TLS negotiation now
C: 2 CAPABILITY
S: * CAPABILITY IMAP4 IMAP4rev1 LITERAL+ ID AUTH=PLAIN SASL-IR ACL  
RIGHTS=kxte QUOTA MAILBOX-REFERRALS NAMESPACE UIDPLUS NO_ATOMIC_RENAME  
UNSELECT CHILDREN MULTIAPPEND BINARY SORT SORT=MODSEQ  
THREAD=ORDEREDSUBJECT THREAD=REFERENCES ANNOTATEMORE CATENATE  
CONDSTORE IDLE LISTEXT LIST-SUBSCRIBED X-NETSCAPE URLAUTH
S: 2 OK Completed
C: [LOGIN Command - username: simon]
S: 3 OK [CAPABILITY IMAP4 IMAP4rev1 LITERAL+ ID LOGINDISABLED ACL  
RIGHTS=kxte QUOTA MAILBOX-REFERRALS NAMESPACE UIDPLUS NO_ATOMIC_RENAME  
UNSELECT CHILDREN MULTIAPPEND BINARY SORT SORT=MODSEQ  
THREAD=ORDEREDSUBJECT THREAD=REFERENCES ANNOTATEMORE CATENATE  
CONDSTORE IDLE LISTEXT LIST-SUBSCRIBED X-NETSCAPE URLAUTH] User logged  
in


Doing an update on the iPhone's AS Inbox generates this IMAP debug log:

http://www.simonandkate.net/imaplog.txt

That UID list returned from Cyrus is correct - 46072 is the last  
(newest) email that is actually in the mailbox. It appears that Cyrus  
is sending the correct info. Imp shows this correctly. Yet AS into iOS  
is not showing this, with four emails showing that are newer.

The AS log for this is as follows:

http://www.simonandkate.net/asimap.txt

That also shows the correct UID sequence. Yet iPhone continues to show  
the old list of emails - not being told to update?

One oddity in the IMAP log is the following entry:

>> Mon, 04 Mar 2013 21:39:27 +1000
S: * OK [CAPABILITY IMAP4 IMAP4rev1 LITERAL+ ID STARTTLS  
LOGINDISABLED] server04.simonandkate.lan Cyrus IMAP4  
v2.3.7-Invoca-RPM-2.3.7-12.el5_7.2 server ready
C: 1 STARTTLS
S: 1 OK Begin TLS negotiation now
C: 2 CAPABILITY
S: * CAPABILITY IMAP4 IMAP4rev1 LITERAL+ ID AUTH=PLAIN SASL-IR ACL  
RIGHTS=kxte QUOTA MAILBOX-REFERRALS NAMESPACE UIDPLUS NO_ATOMIC_RENAME  
UNSELECT CHILDREN MULTIAPPEND BINARY SORT SORT=MODSEQ  
THREAD=ORDEREDSUBJECT THREAD=REFERENCES ANNOTATEMORE CATENATE  
CONDSTORE IDLE LISTEXT LIST-SUBSCRIBED X-NETSCAPE URLAUTH
S: 2 OK Completed
C: [LOGIN Command - username: simon]
S: 3 OK [CAPABILITY IMAP4 IMAP4rev1 LITERAL+ ID LOGINDISABLED ACL  
RIGHTS=kxte QUOTA MAILBOX-REFERRALS NAMESPACE UIDPLUS NO_ATOMIC_RENAME  
UNSELECT CHILDREN MULTIAPPEND BINARY SORT SORT=MODSEQ  
THREAD=ORDEREDSUBJECT THREAD=REFERENCES ANNOTATEMORE CATENATE  
CONDSTORE IDLE LISTEXT LIST-SUBSCRIBED X-NETSCAPE URLAUTH] User logged  
in
>> Slow IMAP Command: 901.102 seconds
C: 4 NAMESPACE
S: * NAMESPACE (("INBOX." ".")) (("user." ".")) (("" "."))
S: 4 OK Completed
C: 5 LOGOUT
S: * BYE LOGOUT received
S: 5 OK Completed

900 seconds - what is it doing??

As noted previously, iOS does not do this for either of my Exchange AS  
connections - it's only on the Horde AS connection I have this issue.

There has to be some information in here that helps?? I hope! :)

Simon

--
Simon Wilson
M: 0400 12 11 16
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: PGP Digital Signature
URL: <http://lists.horde.org/archives/horde/attachments/20130304/b2e72089/attachment.bin>


More information about the horde mailing list