Deleting messages from filesystem with sdbox mail format

Gionatan Danti g.danti at assyoma.it
Mon May 11 16:45:20 EEST 2020


Dear list,
I recently had to delete some messages from an sdbox mailbox, for which 
I used the canonical "doveadm expunge" command without issues.

However I got curious and, on a test mailbox, I deleted an unimportant 
message directly from the filesystem (rm u.650). After removing the 
file, the webmail continued to show it in the mail list - but no text 
was retrieved when I selected it. I supposed this was due to 
dovecot.index.cache and, indeed, deleting the cache got rid of the 
message in the webmail list.

While I understand that it is not recommended (deleting and regenerating 
the index cache is an expensive operation), I wonder if removing a file 
from the filesystem, and regenerating the index cache file, is a safe 
operation when using an sdbox mailstore. Specifically, I would like to 
know if, after a manual filesystem deletion, the main index file 
(dovecot.index) is automatically updated by dovecot (reflecting the 
deletion) or if lingering references are kept in it.

Thanks.

-- 
Danti Gionatan
Supporto Tecnico
Assyoma S.r.l. - www.assyoma.it [1]
email: g.danti at assyoma.it - info at assyoma.it
GPG public key ID: FF5F32A8


More information about the dovecot mailing list