XFER command does not transfer cyrus.expunge and the deleted messages.

Ken Murchison murch at andrew.cmu.edu
Fri Sep 29 11:07:41 EDT 2006

Paul Turgyan wrote:
> I have just submitted a bug (#2877)  and a patch that fixes XFER,  such 
> that XFER
> also transfers the cyrus.expunge and the deleted but unexpunged message 
> files
> to the destination machine.  The approach I used was to open the 
> directory and
> transfer all the message files,  transfer the cyrus.expunge file (if it
> exists),  and then the other meta files.  Finally the rest of the user's
> files are transferred in dump_mailbox (mbdump.c).

Just committed by own version of the patch, using older mbdump.c code 
which didn't have the use of cyrus.index for xfering message files.

> The only problem I can see with this,  is if the destination machine
> does not support delayed expunge,  we have transferred the cyrus.expunge,
> and the previously deleted messages.  These deleted messages are now
> sitting in the destination mailbox but not in the cyrus.index file.  If 
> the user's mailbox
> were then reconstructed, the deleted messages would end up back in the 
> mailbox.

As XFER was originally designed, and mostly used, for moving user's 
between backends in a Murder, and all backends need to be configured 
similarly, I don't consider this a problem.

Even if the two servers are configured with delayed expunge and 
immediate expunge, nothing really bad happens, just an inconvenient user 

> Rename also has the same problem (bug 2872),  where the cyrus.expunge is
> deleted and the deleted messages are expunged and not moved to the new 
> location.
> I propose adding similar code to rename, that moves whatever message 
> files in the mailbox
> to the destination along with all the meta files.

I'll take a look.

Kenneth Murchison
Systems Programmer
Project Cyrus Developer/Maintainer
Carnegie Mellon University

More information about the Cyrus-devel mailing list