I have the following in 15-mailboxes.config:
mailbox Trash { special_use = \Trash autoexpunge = 30 days }
I thought that would empty the deleted emails after 30 days. However, I find that in .Deleted Messages/cur there are over 18K messages dating back to the 90's. What do I need to set to make the autoexpunge work?
-- Doug
run cron job with purge?
I have the following in 15-mailboxes.config:
mailbox Trash { special_use = \Trash autoexpunge = 30 days }
I thought that would empty the deleted emails after 30 days. However, I find that in .Deleted Messages/cur there are over 18K messages dating back to the 90's. What do I need to set to make the autoexpunge work?
-- Doug
On Feb 18, 2025, at 00:20, Marc via dovecot <dovecot@dovecot.org> wrote:
run cron job with purge?
I have the following in 15-mailboxes.config:
mailbox Trash { special_use = \Trash autoexpunge = 30 days }
I thought that would empty the deleted emails after 30 days. However, I find that in .Deleted Messages/cur there are over 18K messages dating back to the 90's. What do I need to set to make the autoexpunge work?
That did nothing. I ran:
doveadm expunge -u doug mailbox "Deleted Messages" savedbefore 2w
That worked.
On 02/18/2025 1:09 AM MST Doug Hardie via dovecot <dovecot@dovecot.org> wrote:
I have the following in 15-mailboxes.config:
mailbox Trash { special_use = \Trash autoexpunge = 30 days }
I thought that would empty the deleted emails after 30 days. However, I find that in .Deleted Messages/cur there are over 18K messages dating back to the 90's. What do I need to set to make the autoexpunge work?
Autoexpunge only works if the mailbox is accessed.
michael
On Feb 18, 2025, at 06:45, Michael Slusarz <michael.slusarz@open-xchange.com> wrote:
On 02/18/2025 1:09 AM MST Doug Hardie via dovecot <dovecot@dovecot.org> wrote:
I have the following in 15-mailboxes.config:
mailbox Trash { special_use = \Trash autoexpunge = 30 days }
I thought that would empty the deleted emails after 30 days. However, I find that in .Deleted Messages/cur there are over 18K messages dating back to the 90's. What do I need to set to make the autoexpunge work?
Autoexpunge only works if the mailbox is accessed.
My Deleted Messages mailbox has been accessed virtually every day for many years. Still had lots from the late 90's in it.
-- Doug
I have the following in 15-mailboxes.config:
mailbox Trash { special_use = \Trash autoexpunge = 30 days }
I thought that would empty the deleted emails after 30 days. However, I find that in .Deleted Messages/cur there are over 18K messages dating back to the 90's. What do I need to set to make the autoexpunge work?
Try changing '30 days' to '30d' and see if that makes a difference.
I thought that expunging messages would only work on messages flagged as deleted. Just being in the Deleted Messages folder would not necessarily mark the messages with the deleted flag. Or does the auto expunge feature work differently than I expect it to?
Ted
On Feb 18, 2025, at 2:00 PM, dovecot--- via dovecot <dovecot@dovecot.org> wrote:
I have the following in 15-mailboxes.config: mailbox Trash { special_use = \Trash autoexpunge = 30 days } I thought that would empty the deleted emails after 30 days. However, I find that in .Deleted Messages/cur there are over 18K messages dating back to the 90's. What do I need to set to make the autoexpunge work?
Try changing '30 days' to '30d' and see if that makes a difference.
dovecot mailing list -- dovecot@dovecot.org To unsubscribe send an email to dovecot-leave@dovecot.org
See https://doc.dovecot.org/2.4.0/core/config/namespaces.html#mailbox_autoexpung...
And while it says "expunge", it really means delete and expunge.
Aki
On 19/02/2025 08:07 EET Ted Hatfield via dovecot <dovecot@dovecot.org> wrote:
I thought that expunging messages would only work on messages flagged as deleted. Just being in the Deleted Messages folder would not necessarily mark the messages with the deleted flag. Or does the auto expunge feature work differently than I expect it to?
Ted
On Feb 18, 2025, at 2:00 PM, dovecot--- via dovecot <dovecot@dovecot.org> wrote:
I have the following in 15-mailboxes.config: mailbox Trash { special_use = \Trash autoexpunge = 30 days } I thought that would empty the deleted emails after 30 days. However, I find that in .Deleted Messages/cur there are over 18K messages dating back to the 90's. What do I need to set to make the autoexpunge work?
Try changing '30 days' to '30d' and see if that makes a difference.
dovecot mailing list -- dovecot@dovecot.org To unsubscribe send an email to dovecot-leave@dovecot.org
dovecot mailing list -- dovecot@dovecot.org To unsubscribe send an email to dovecot-leave@dovecot.org
See https://doc.dovecot.org/2.4.0/core/config/namespaces.html#mailbox_autoexpung... And while it says "expunge", it really means delete and expunge.
Aki
Autoexpunge says you should add 'date.save' to 'mail_always_cache_fields'.
However 'mail_cache_fields' says: "The default list of fields that are added to cache if no other caching decisions exist yet. This setting is used only when creating the initial INBOX for the user. Other folders get their defaults from the INBOX."
Does that mean since 'mail_cache_fields' is set at mailbox creation, would adding 'mail_always_cache_fields=date.save' have any effect on existing mailboxes or only on new boxes going forward?
On 19/02/2025 20:22 EET dovecot--- via dovecot <dovecot@dovecot.org> wrote:
See https://doc.dovecot.org/2.4.0/core/config/namespaces.html#mailbox_autoexpung... And while it says "expunge", it really means delete and expunge.
Aki
Autoexpunge says you should add 'date.save' to 'mail_always_cache_fields'.
However 'mail_cache_fields' says: "The default list of fields that are added to cache if no other caching decisions exist yet. This setting is used only when creating the initial INBOX for the user. Other folders get their defaults from the INBOX."
Does that mean since 'mail_cache_fields' is set at mailbox creation, would adding 'mail_always_cache_fields=date.save' have any effect on existing mailboxes or only on new boxes going forward?
mail_always_cache_fields has effect even on existing boxes. Just not existing email. Note the 'always' word there.
Aki
participants (6)
-
Aki Tuomi
-
Doug Hardie
-
dovecot@ptld.com
-
Marc
-
Michael Slusarz
-
Ted Hatfield