I have a postfix server using an IMAP with TLS to retrieve my emails.

It feels rather slow and becomes slower as time passes, even though I try to limit the number of emails I have to just a few hundred (362 at the moment.)

Looking in the Maildir/cur folder on my server, I could a total of 853 emails. However, if I ignore files that end with ",S" or ",RS", then the total is 362. Exactly what I see when Thunderbird starts (it shows me the count in the status bar at the bottom.)

Looking at those emails with ",S" or ",RS" at the end of the filename, they are all spam emails. In Thunderbird, I do not see any of those emails.

Why would Thunderbird / Postfix not delete those emails when I empty my Trash folder? Looking at the dates, some of those files are as old as 2013. So really, Thunderbird or Postfix have a problem on that one?!

1 Answer 1


First of all, Postfix has absolutely nothing to do with IMAP. At most, it delivers messages to the Maildir directly, or to some LDA, but that's all – your IMAP access is most likely provided by Dovecot, Courier, or Cyrus.

Second, messages in Maildir/{cur,new,tmp} are not in "Trash" in the first place – that's your "INBOX" folder. So emptying the Trash wouldn't affect them.

(Instead, IMAP subfolders are usually mapped to hidden "dot" directories inside the Maildir, so Trash would correspond to Maildir/.Trash/{cur,new,tmp}.)

So if you see some messages in the storage but not in Thunderbird, there could be two problems:

  • Thunderbird is hiding the messages. Easy way to find out is to set up another IMAP client – for example, just run mutt -f imaps://mail.example.com/INBOX.

  • The IMAP server doesn't "see" the messages. Usually, for performance reasons, the IMAP service doesn't rescan the entire directory every time – it might keep an internal index, and external modifications (such as your antispam system trying to set 'spam' flags) don't update that index.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .