Community Discussions and Support
Deleting messages when running MercuryI (IMAP)

Profimail connects to Mercury, checks for mail and disconnects - if there's nothing new, it's only visible in the Mercury window for about 5 seconds. I think this is configurable in Profimail. As regards cost, you can download a time-limited demo without charge - I think you get 30 days to try it.

Thunderbird logs in as soon it starts up and appears to stay logged in so long as it's running. I don't think checking for mail and logging in are the same thing - for example, you would need to log in to read existing mail, unless it was synchronised and stored on the client.

Chris

 

<p>Profimail connects to Mercury, checks for mail and disconnects - if there's nothing new, it's only visible in the Mercury window for about 5 seconds. I think this is configurable in Profimail. As regards cost, you can download a time-limited demo without charge - I think you get 30 days to try it. </p><p>Thunderbird logs in as soon it starts up and appears to stay logged in so long as it's running. I don't think checking for mail and logging in are the same thing - for example, you would need to log in to read existing mail, unless it was synchronised and stored on the client.</p><p>Chris </p><p>  </p>

I have several machines running on my LAN, all of which may be used to access mail available from MercuryI.  One machine in particular, which is running Outlook Express on WinXP as the client, is having trouble purging deleted messages.  I think that this trouble started when I began to use a Moto Xoom Android tablet, running K9 mail.  K9 can view each IMAP account folder individually, but also an "All Messages" folder.  Looking at the Mercury IMAP window, it seems that the tablet is creating two IMAP connections for each account.  I am presuming that this is one for each individual account and another for each of the accounts included in "All Messages".  Mercury is showing the IP address of the router for tablet connections, given that I am connecting via the Internet hostname of the Mercury server.  Maybe the tablet has nothing to do with the problem, but this behaviour started when I first started to use the tablet.

On a recent test, I had the Mercury running on the LAN, a Win7 machine running Thunderbird, my wife's machine (where the unpurged messages are showng) and the tablet.  I powered off the Win7 machine and the tablet.  The Win7 machine connection disappeared from the IMAP window, but the tablet connection (not expected) and the connection from my wife's machine (expected) remained, even though the tablet was powered off.  I still couldn't purge the deleted messages from my wife's machine.

If I restart Mercury, the tablet IP connection is no longer there, and I can purge the messages from my wife's machine.

Is this behaviour to be expected?  Perhaps' someone could explain what is hapenning here.

I expect to see some file locking when two machines have connections to the same account, but this seems to be more than that. 

Thank you

Gordon

 

<P>I have several machines running on my LAN, all of which may be used to access mail available from MercuryI.  One machine in particular, which is running Outlook Express on WinXP as the client, is having trouble purging deleted messages.  I think that this trouble started when I began to use a Moto Xoom Android tablet, running K9 mail.  K9 can view each IMAP account folder individually, but also an "All Messages" folder.  Looking at the Mercury IMAP window, it seems that the tablet is creating two IMAP connections for each account.  I am presuming that this is one for each individual account and another for each of the accounts included in "All Messages".  Mercury is showing the IP address of the router for tablet connections, given that I am connecting via the Internet hostname of the Mercury server.  Maybe the tablet has nothing to do with the problem, but this behaviour started when I first started to use the tablet.</P> <P>On a recent test, I had the Mercury running on the LAN, a Win7 machine running Thunderbird, my wife's machine (where the unpurged messages are showng) and the tablet.  I powered off the Win7 machine and the tablet.  The Win7 machine connection disappeared from the IMAP window, but the tablet connection (not expected) and the connection from my wife's machine (expected) remained, even though the tablet was powered off.  I still couldn't purge the deleted messages from my wife's machine.</P> <P>If I restart Mercury, the tablet IP connection is no longer there, and I can purge the messages from my wife's machine.</P> <P>Is this behaviour to be expected?  Perhaps' someone could explain what is hapenning here.</P> <P>I expect to see some file locking when two machines have connections to the same account, but this seems to be more than that. </P> <P>Thank you</P> <P>Gordon</P> <P mce_keep="true"> </P>

> Is this behaviour to be expected?  Perhaps' someone could explain what is happening here.

Mercury IMAP4 does not support the IMAP4 option of  purging deleted mail with multiple connections to an account. The deletions though should occur when the last connection is logged out.  If the connections do not close with a logout though the messages marked for deletion will have deletions removed. 

<p>> Is this behaviour to be expected?  Perhaps' someone could explain what is happening here.</p><p>Mercury IMAP4 does not support the IMAP4 option of  purging deleted mail with multiple connections to an account. The deletions though should occur when the last connection is logged out.  If the connections do not close with a logout though the messages marked for deletion will have deletions removed.  </p>

Thank you, Thomas.  This sounds familiar, though I can't recall where I saw it.  I'll check this out and close all connections.

It seems that the connection isn't being closed when the K9 client is terminated (tablet powered off).  I'll check the K9 options to see if there is anything related to this.  Do you know whether Mercury IMAP4 monitors connections to make sure that a client is still connected, or does the client have to send a specific command to close the connection.

When you say "deletions though should occur when the last connection is logged out", does this include closing the client through which the deletions were made?  Certainly, if there are no other mail client machines active on the LAN from the beginning, it isn't necessary to close the deleting client for a purge to be successful.

I had assumed that the OE steps of delete and then purge are the same as the Thunderbird functions of deleting a message and then emptying the delete folder.  Maybe it is just that the terminology is different.

Thank you

Gordon

 

<P>Thank you, Thomas.  This sounds familiar, though I can't recall where I saw it.  I'll check this out and close all connections.</P> <P>It seems that the connection isn't being closed when the K9 client is terminated (tablet powered off).  I'll check the K9 options to see if there is anything related to this.  Do you know whether Mercury IMAP4 monitors connections to make sure that a client is still connected, or does the client have to send a specific command to close the connection.</P> <P>When you say "deletions though should occur when the last connection is logged out", does this include closing the client through which the deletions were made?  Certainly, if there are no other mail client machines active on the LAN from the beginning, it isn't necessary to close the deleting client for a purge to be successful.</P> <P>I had assumed that the OE steps of delete and then purge are the same as the Thunderbird functions of deleting a message and then emptying the delete folder.  Maybe it is just that the terminology is different.</P> <P>Thank you</P> <P>Gordon</P> <P mce_keep="true"> </P>

> When you say "deletions though should occur when the last connection
> is logged out", does this include closing the client through which the
> deletions were made?  Certainly, if there are no other mail client
> machines active on the LAN from the beginning, it isn't necessary to
> close the deleting client for a purge to be successful.

Closing is not the same as logging out.  The IMAP4 client needs to issue the logout command.  Turn on session logging in MercuryI and see what commands the client is issuing when closing the IMAP4 connection.

> When you say "deletions though should occur when the last connection > is logged out", does this include closing the client through which the > deletions were made?  Certainly, if there are no other mail client > machines active on the LAN from the beginning, it isn't necessary to > close the deleting client for a purge to be successful. Closing is not the same as logging out.  The IMAP4 client needs to issue the logout command.  Turn on session logging in MercuryI and see what commands the client is issuing when closing the IMAP4 connection.

Thanks Thomas.  I'll check this out.

Gordon

<P>Thanks Thomas.  I'll check this out.</P> <P>Gordon</P>

It appears that IMAP4 connections not being logged off is a known issue with K9 mail.  Even if I turn off all connected IMAP4 clients, the connections set up by K9 remain (the tablet is one of the devices turned off).

I am wondering why Mercury still  thinks that there is a connection when there defintiely is not.  Is this the way an IMAP4 server should work.

If there were any real alternative Android IMAP4 clients, I would consider using them, just because of this nuisance, but there aren't.

Gordon

 

<P>It appears that IMAP4 connections not being logged off is a known issue with K9 mail.  Even if I turn off all connected IMAP4 clients, the connections set up by K9 remain (the tablet is one of the devices turned off).</P> <P>I am wondering why Mercury still  thinks that there is a connection when there defintiely is not.  Is this the way an IMAP4 server should work.</P> <P>If there were any real alternative Android IMAP4 clients, I would consider using them, just because of this nuisance, but there aren't.</P> <P>Gordon</P> <P mce_keep="true"> </P>

 Thomas R Stephenson wrote

>The deletions though should occur when the last connection is logged out

 On my system (4.73) they appear to happen when the last but one connection is logged out, ie, once there's only a single connection. If I have an account open on two clients, and delete something, I get a message that the command cannot be carried out (because of the other login). But if I log out, wait 30 seconds and log back in, the deletion has been done.

 Perhaps I should set up session logs to confirm, when I have a spare minute.

Chris

 

<p> Thomas R Stephenson wrote </p><p>>The deletions though should occur when the last connection is logged out</p><p> On my system (4.73) they appear to happen when the last but one connection is logged out, ie, once there's only a single connection. If I have an account open on two clients, and delete something, I get a message that the command cannot be carried out (because of the other login). But if I log out, wait 30 seconds and log back in, the deletion has been done.</p><p> Perhaps I should set up session logs to confirm, when I have a spare minute. </p><p>Chris </p><p> </p>

Chris - What you are observing is what I seem to have seen also.  That is, except when the K9 Android client has been connected.

I normally have 4 machines on my home LAN, a Win7 machine running Thunderbird, an XP machine running Outlook Express, the Android tablet running the K9 mail client, and the server machine (which normally doesn't run a mail client), where Mercury resides.  If I exit Thunderbird or OE, the IMAP4 connections disappear "on the mouse click" immediately from the Mercury IMAP4 window on the server machine.  Android apps are not normally terminated in the same way and are still running in the background when their windows are closed.  Turning the tablet off obviously terminates K9, but the indication of connections stays around in the Mercury IMAP4 window indefinitely.  They can only be made to go away by terminating Mercury and restarting it.  I am guessing that Thunderbird and OE send IMAP4 logout commands as part of there exit routines, whereas K9 probably doesn't.  What I haven't tried is to power down (either by a normal Windows shutdown or simply a power-off) the machines running Thunderbird or OE, without exiting the mail clients first.  Maybe a problem similar to that with K9 would occur in those circumstances, if logout commands are not given (maybe only on a hard power off).

There is another difference between the mail clients  on the Windows machines and that on the tablet.  With OE (and I think with Thunderbird), in between the occasions when the server is being checked for new mail, there seems to be a logout (at least the connection disappears from Mercury's IMAP4 window).

I suspect that all the main problem is that K9 doesn't send out logout commands and, until the authors fix this (if ever), the problem will remain ... unless, of course, Mercury could recognize a lost connection and do the logout itself ... but that's probably not part of the IMAP4 standard.

Gordon

 

<P>Chris - What you are observing is what I seem to have seen also.  That is, except when the K9 Android client has been connected.</P> <P>I normally have 4 machines on my home LAN, a Win7 machine running Thunderbird, an XP machine running Outlook Express, the Android tablet running the K9 mail client, and the server machine (which normally doesn't run a mail client), where Mercury resides.  If I exit Thunderbird or OE, the IMAP4 connections disappear "on the mouse click" immediately from the Mercury IMAP4 window on the server machine.  Android apps are not normally terminated in the same way and are still running in the background when their windows are closed.  Turning the tablet off obviously terminates K9, but the indication of connections stays around in the Mercury IMAP4 window indefinitely.  They can only be made to go away by terminating Mercury and restarting it.  I am guessing that Thunderbird and OE send IMAP4 logout commands as part of there exit routines, whereas K9 probably doesn't.  What I haven't tried is to power down (either by a normal Windows shutdown or simply a power-off) the machines running Thunderbird or OE, without exiting the mail clients first.  Maybe a problem similar to that with K9 would occur in those circumstances, if logout commands are not given (maybe only on a hard power off).</P> <P>There is another difference between the mail clients  on the Windows machines and that on the tablet.  With OE (and I think with Thunderbird), in between the occasions when the server is being checked for new mail, there seems to be a logout (at least the connection disappears from Mercury's IMAP4 window).</P> <P>I suspect that all the main problem is that K9 doesn't send out logout commands and, until the authors fix this (if ever), the problem will remain ... unless, of course, Mercury could recognize a lost connection and do the logout itself ... but that's probably not part of the IMAP4 standard.</P> <P>Gordon</P> <P mce_keep="true"> </P>

Gordon, I think you're right in all of that, and I can't offer any way out except hope for an update or a better Android application. I don't know if David Harris has any plans to make Mercury accommodate deletion with multiple clients - I suspect he chose to write it the way it is for a reason.

I hope the android application is fixed - I am amazed that "Android apps are not normally terminated in the same way and are still running in the background when their windows are closed." - that's appalling design, particularly for an OS that's designed for battery devices. They certainly should log out as well, I guess there's potential security hole if they don't.

 Chris

<p>Gordon, I think you're right in all of that, and I can't offer any way out except hope for an update or a better Android application. I don't know if David Harris has any plans to make Mercury accommodate deletion with multiple clients - I suspect he chose to write it the way it is for a reason. </p><p>I hope the android application is fixed - I am amazed that "Android apps are not normally terminated in the same way and are still running in the background when their windows are closed." - that's appalling design, particularly for an OS that's designed for battery devices. They certainly should log out as well, I guess there's potential security hole if they don't.</p><p> Chris </p>

Chris - I beleive that there are Android apps that will "kill" other running apps (possibly like the Unix/Linux kill -9 instruction), but that doesn't mean that an IMAP4 logout instruction is going to be sent.  However, I will investigate this.  Thre is also a K-9 derivative called KaitenMail (as in K-10).  The developer is reputed to be very responsive (this is a paid app), and I will also investigate that.

Gordon

 

<P>Chris - I beleive that there are Android apps that will "kill" other running apps (possibly like the Unix/Linux kill -9 instruction), but that doesn't mean that an IMAP4 logout instruction is going to be sent.  However, I will investigate this.  Thre is also a K-9 derivative called KaitenMail (as in K-10).  The developer is reputed to be very responsive (this is a paid app), and I will also investigate that.</P> <P>Gordon</P> <P mce_keep="true"> </P>

My impression when I set up an Android phone with K-9 was that the IMAP connections were not coming from the phone's IP address but from some other server, and that K-9 was then polling that other server. That would explain why shutting down the Android device does not disconnect from Mercury. I also had the two persistent IMAP connections to Mercury. After several hours, those connections were still around, and there would be two new ones.  In addition, because of the permanent IMAP connections, it was impossible to use Pegasus to access the same account as local files. On top of that, the IMAP connections were eating lots of CPU cycles and bandwidth on the Mercury server.

My solution was to set up a separate Gmail account and forward a copy of all email from Mercury to Gmail. I then pointed the Android to Gmail instead of Mercury. The upside: no more problems with deleted emails reappearing (K-9 and the Gmail IMAP servers understand each other), and the ability to use Pegasus in addition to the Android (I know, I could have configured Pegasus to also use IMAP). The downside: you now have two inboxes to deal with (Mercury and Gmail) but in our case this is actually preferable.  I also created a filter that strips some attachments from the Gmail copy and replaces any email larger that 1MB with a short message that says there's a large email from xxx waiting for you in Pegasus to reduce the data costs on the phone.

 

<p>My impression when I set up an Android phone with K-9 was that the IMAP connections were not coming from the phone's IP address but from some other server, and that K-9 was then polling that other server. That would explain why shutting down the Android device does not disconnect from Mercury. I also had the two persistent IMAP connections to Mercury. After several hours, those connections were still around, and there would be two new ones.  In addition, because of the permanent IMAP connections, it was impossible to use Pegasus to access the same account as local files. On top of that, the IMAP connections were eating lots of CPU cycles and bandwidth on the Mercury server. </p><p>My solution was to set up a separate Gmail account and forward a copy of all email from Mercury to Gmail. I then pointed the Android to Gmail instead of Mercury. The upside: no more problems with deleted emails reappearing (K-9 and the Gmail IMAP servers understand each other), and the ability to use Pegasus in addition to the Android (I know, I could have configured Pegasus to also use IMAP). The downside: you now have two inboxes to deal with (Mercury and Gmail) but in our case this is actually preferable.  I also created a filter that strips some attachments from the Gmail copy and replaces any email larger that 1MB with a short message that says there's a large email from xxx waiting for you in Pegasus to reduce the data costs on the phone.</p><p> </p>

Thanks for your thoughts on this subelman.  I am pretty sure that you are right about the phone IP address.  I used to access my Mercury server directly from my phone (not the one that I have now) and I set up my firewall to accept connections from my ISP's servers.  However, the IP address ranges changed from time-to-time and was geographically dependent, so this was a bit awkward. 

For the tablet,  K-9 accesses Mercury through my hostname so, from the point of view of  IMAP4, the connection appears to come from the router (via port forwarding).

My current setup for access from my phone (different from the tablet and not Android) is very similar to what you are suggesting.  This benefits from the filtering done by Mercury and I have also set up a list of addresses for which messages are not forwarded to my GMail account.  For the most part, this is "commercial mail", e.g. from BestBuy or airline accounts that I don't really want to see when I am not at home.

 I may well go the GMail route, as I have done with the phone and as you have suggested.  However, I probably won't filter out the commercial e-mails for the tablet, but it is easy to set up another GMail account for this. 

I am also looking into KaitenMail, a paid derivative of K-9.  Whether this handles IMAP4 disconnection any differently, I don't know.  I am waiting to hear from the developer.

 

 

 

 

<p>Thanks for your thoughts on this subelman.  I am pretty sure that you are right about the phone IP address.  I used to access my Mercury server directly from my phone (not the one that I have now) and I set up my firewall to accept connections from my ISP's servers.  However, the IP address ranges changed from time-to-time and was geographically dependent, so this was a bit awkward. </p><p>For the tablet,  K-9 accesses Mercury through my hostname so, from the point of view of  IMAP4, the connection appears to come from the router (via port forwarding).</p><p>My current setup for access from my phone (different from the tablet and not Android) is very similar to what you are suggesting.  This benefits from the filtering done by Mercury and I have also set up a list of addresses for which messages are not forwarded to my GMail account.  For the most part, this is "commercial mail", e.g. from BestBuy or airline accounts that I don't really want to see when I am not at home.</p><p> I may well go the GMail route, as I have done with the phone and as you have suggested.  However, I probably won't filter out the commercial e-mails for the tablet, but it is easy to set up another GMail account for this. </p><p>I am also looking into KaitenMail, a paid derivative of K-9.  Whether this handles IMAP4 disconnection any differently, I don't know.  I am waiting to hear from the developer.</p><p> </p><p> </p><p> </p><p> </p>

Gordon,

 I use Profimail as an IMAP client on my smartphone and find it good. I have the Symbian version but it is also available for Android.

 http://www.lonelycatgames.com/?app=profimail

Chris

<p>Gordon,</p><p> I use Profimail as an IMAP client on my smartphone and find it good. I have the Symbian version but it is also available for Android.</p><p> http://www.lonelycatgames.com/?app=profimail</p><p>Chris </p>

I haven't tried Profimail yet but I did look at the Android Market reviews.  They were a bit mixed, though mainly on the positive side.  The main complaints seemed to be about the UI and the cost (though that's not a big issue for me, if it works well).  I haven't been able to find out whether it's possible to set Profimail to logout IMAP4 connections after checking mail.

I have also been doing a bit of research about K-9 and Thunderbird (I am now using 6.0), which both give me persistent connections.  It seems that some (maybe not all) IMAP4 servers check for unused/hung connections and remove any connections that are in this situation.  Mercury seems to be one of those that does check.  I have Mercury's IMAP4 idle time-out set to 30 minutes (the default and minimum allowed by the RFC).  In the case of Thunderbird, I have set the IMAP4 client to check for new mail every 40 minutes.  This is far too long than I would like, but is a useful test.  Indeed, after 30 minutes the connections disappear from Mercury's IMAP4 server window, which then shows no connections for 10 minutes.  I have also set the Thunderbird accounts so that they do not use the IDLE command.  Also, I have the TB accounts set so that there is only one cached connection.  I tried to use zero cached connections (I am not sure that this makes sense), but "0" wouldn't stick, and went back to "1", which I had been using.  The only other odd thing about the TB connections is that I have all of the accounts set so they don't check mail immediately when TB starts.  Of the seven accounts that are connecting to Mercury, six of them follow the desired behaviour.  One, however, makes a connection as soon as TB starts.  I don't know why.

Given that, under the above setup, there is a period when there are no connections from my machine running TB, I think that it should be possible to purge e-mails from another client (running OE6) during this window.  How practical this is really going to be, given the long mail checking cycle, I haven't decided yet.

So far as K-9 is concerned, I am still awaiting results.  There is less flexibility in setting refresh times than for TB.  I have set the IDLE refresh time to 60 minutes (there is no "never refresh" and the next smallest available is 30 minutes, which is the same as Mercury's idle time-out).  I have also set the mail polling time to 60 minutes.

Whether this is going to get me anywhere with regard to being able to delete mail in a multi-client environment, I don't know.

What I don't understand (unless Push mail is being used, which requires a persistent connection) is why IMAP4 clients don't just logon, check mail and then logout immediately.  Maybe I am missing something here.

Gordon

 

<P>I haven't tried Profimail yet but I did look at the Android Market reviews.  They were a bit mixed, though mainly on the positive side.  The main complaints seemed to be about the UI and the cost (though that's not a big issue for me, if it works well).  I haven't been able to find out whether it's possible to set Profimail to logout IMAP4 connections after checking mail.</P> <P>I have also been doing a bit of research about K-9 and Thunderbird (I am now using 6.0), which both give me persistent connections.  It seems that some (maybe not all) IMAP4 servers check for unused/hung connections and remove any connections that are in this situation.  Mercury seems to be one of those that does check.  I have Mercury's IMAP4 idle time-out set to 30 minutes (the default and minimum allowed by the RFC).  In the case of Thunderbird, I have set the IMAP4 client to check for new mail every 40 minutes.  This is far too long than I would like, but is a useful test.  Indeed, after 30 minutes the connections disappear from Mercury's IMAP4 server window, which then shows no connections for 10 minutes.  I have also set the Thunderbird accounts so that they do not use the IDLE command.  Also, I have the TB accounts set so that there is only one cached connection.  I tried to use zero cached connections (I am not sure that this makes sense), but "0" wouldn't stick, and went back to "1", which I had been using.  The only other odd thing about the TB connections is that I have all of the accounts set so they don't check mail immediately when TB starts.  Of the seven accounts that are connecting to Mercury, six of them follow the desired behaviour.  One, however, makes a connection as soon as TB starts.  I don't know why.</P> <P>Given that, under the above setup, there is a period when there are no connections from my machine running TB, I think that it should be possible to purge e-mails from another client (running OE6) during this window.  How practical this is really going to be, given the long mail checking cycle, I haven't decided yet.</P> <P>So far as K-9 is concerned, I am still awaiting results.  There is less flexibility in setting refresh times than for TB.  I have set the IDLE refresh time to 60 minutes (there is no "never refresh" and the next smallest available is 30 minutes, which is the same as Mercury's idle time-out).  I have also set the mail polling time to 60 minutes.</P> <P>Whether this is going to get me anywhere with regard to being able to delete mail in a multi-client environment, I don't know.</P> <P>What I don't understand (unless Push mail is being used, which requires a persistent connection) is why IMAP4 clients don't just logon, check mail and then logout immediately.  Maybe I am missing something here.</P> <P>Gordon</P> <P mce_keep="true"> </P>
live preview
enter atleast 10 characters
WARNING: You mentioned %MENTIONS%, but they cannot see this message and will not be notified
Saving...
Saved
With selected deselect posts show selected posts
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft