Backup and Restore strategies for Cyrus IMAP folders

John Alton Tamplin jtampli at sph.emory.edu
Thu Apr 17 10:27:10 EDT 2003


Gary Mills wrote:

>On Wed, Apr 16, 2003 at 07:42:52AM -0400, Earl R Shannon wrote:
>  
>
>>If you restore back to the users inbox you run the chance, although
>>probably small, of overwriting a message. For instance. If a message
>>already exists in the mailbox that has a file name 42. and your 
>>restoration puts back a file named 42. then if they have different 
>>contents you have lost the first message. To prevent this we do our
>>restorations to a folder we create simply named BACKUP. We also give
>>this folder the same quota as the user's inbox. Then after two weeks we 
>>remove the BACKUP folder( and subfolders ).
>>    
>>
>
>Thanks for the response.  Our restore procedure, with Legato
>Networker, never overwrites existing files, so we don't have that
>problem.
>  
>
There is still a potential race condition.  Imagine the next message id 
to use is 101.  Between the time Cyrus decides to use this message id 
for a new message and it actually writes it, Legato restores the file 
101.  Now, Cyrus will write the new message to this file (either 
overwriting the newly-restored message or having a problem because the 
file already exists -- I haven't checked the code to see which).  I 
think it is safer to restore the files to a freshly created folder and 
reconstruct there.

-- 
John A. Tamplin                               Unix System Administrator
Emory University, School of Public Health     +1 404/727-9931







More information about the Info-cyrus mailing list