reprocessing mail

Marc Lucke marc at marcsnet.com
Sun Jan 6 10:26:12 EET 2019


Hey guys,

I had some corruptions whereby dovecot would bomb out on mail files in 
my maildir.  I found that if piped the files to dovecot-lda the all 
email was clean &lost.   I even retrieved email I thought might have 
been lost for good.  I have some better ideas now, but I still processed 
a few thousand emails like that now & would like to do something like this:

* stop dovecot
* iterate over each file
** get date
** touch date (linux - to set the date/time)
** rename the file with the correct epoch
** update dovecot-uidlist with correct epoch
* start dovecot

Will that work?  Or is there something I've missed or should do?

- Marc



More information about the dovecot mailing list