Compress IMAP account on Nethserver 7

Is there a way to compress/compact stored mails on each IMAP account on a Nethserver 7 ?

I have installed the following mail modules:

  • nethserver-roundcubemail-1.3.0-1
  • nethserver-mail-common-2.4.5-1
  • nethserver-mail-filter-2.4.5-1
  • nethserver-mail-disclaimer-2.4.5-1

It’s possible to compact with Roundcube.

On the bottom left click the gear:


In the roundcube server settings you could setup “Compact Inbox on logout”.

I read that “Compact Inbox on logout” option does is:

“This will remove all messages flagged for deletion from the Inbox when you log out”

What I would like to do is reduce the size of the IMAP Account by compressing it.

Is this possible ?

According to their docs

Compact Inbox on logout
This will remove all messages flagged for deletion from the Inbox when you log-off.

(Sorry if it has been already posted)

1 Like

I don’t know if Linux support on the fly file compression (EXT4 shouldn’t) , but often… compression means lacks of performance.
@davidep is used maildir or mbox as default mail format?

I don’t know if it is possible, but I think it’s a task for dovecot…


1 Like

1 Like

Out of luck tonight MrMarkuz :wink:

It compresses on the wire data, not storage


Link was wrong, edited.

1 Like

Awesome! But not straightforward… However seems viable!

Did you check our current dovecot version compatibility?

Alternative solution to compression: buy another hard disk :money_mouth_face:

Compression is CPU bounded: perhaps it requires less disk space but more CPU power.

Also, using a flash storage could lead to a bit more write overhead… On the other side, if disk space is an issue (virtual server) compression could lead to more problem than effective solutions, due to computational overhead.


We use dovecot 2.2.36 (oldstable) and zlib compression seems implemented.