Break up massive INBOX?

Aki Tuomi aki.tuomi at
Tue Oct 25 06:51:53 UTC 2016

On 25.10.2016 09:43, mrobti at wrote:
> I have inherited a 10+ GB mailbox which dsync converted to maildir
> very nicely. But 15GB in tens of thousands of messages is too much in
> one INBOX when used in webmail.
> I guess it's best to divide the messages into subfolders for date.
> Is there a server-side way to safely move messages into new subfolders
> so that Dovecot indexes and UIDs won't break? If I write a shell
> script to move maildir files based on date of the files, I think
> Dovecot would not like this?
> Also, is there any way to automatically create delivery or archive
> folders by date eg., on the 1st of each month? And deliver mails to
> the subfolder for the current month? I know I can create Sieve rules
> for such by hand, but prefer if there is a plugin or something to do
> this automatically.


doveadm move is probably your friend here, see man doveadm-search-query
for details on what you can search for.


More information about the dovecot mailing list