This documentation is for Dovecot v2.x, see wiki1 for v1.x documentation.
Differences between revisions 1 and 2
Revision 1 as of 2010-07-02 15:52:19
Size: 3024
Editor: PageImporter
Revision 2 as of 2010-07-13 02:42:40
Size: 3031
Editor: PageImporter
Deletions are marked like this. Additions are marked like this.
Line 35: Line 35:
<i>/etc/dovecot/dovecot-sql.conf.ext</i> matches your database layout. Otherwise <b><a href=
"/Tools/Doveadm">doveadm</a></b>(1) will be unable to iterate over all users.</p>
<i>@sysconfdir@/dovecot/dovecot-sql.conf.ext</i> matches your database layout. Otherwise
<b><a href="/Tools/Doveadm">doveadm</a></b>(1) will be unable to iterate over all users.</p>



doveadm-purge - Remove messages with refcount=0 from mdbox files


doveadm [-Dv] purge
doveadm [-Dv] purge -A
doveadm [-Dv] purge -u user


The doveadm purge command is used to remove all messages with refcount=0 from a user's mail storage. The refcount of a message is decreased to 0 when the user (or some administration utility) has expunged all instances of a message from all mailboxes.

In the first form, doveadm(1) will perform the purge action for the currently logged in user.

In the second form, the command will be executed for all users

In the last form, only messages of the given user(s) will be purged.


Global doveadm(1) options:

Enables verbosity and debug messages.
Enables verbosity, including progress counter.

Command specific options:

If the -A option is present, the command will be performed for all users. Using this option in combination with system users from userdb { driver = passwd } is not recommended, because it contains also users with a lower UID than the one configured with the first_valid_uid setting.

When the sql userdb module is used make sure that the iterate_query setting in the @sysconfdir@/dovecot/dovecot-sql.conf.ext matches your database layout. Otherwise doveadm(1) will be unable to iterate over all users.

-u user/mask
Run the command only for the given user. It's also possible to use '*' and '?' wildcards (e.g. -u *
When neither the -A option nor -u user was specified, the command will be executed with the environment of the currently logged in user.

See Also

doveadm(1), doveadm-expunge(1)

See for some details.


None: Tools/Doveadm/Purge (last edited 2017-05-30 13:35:41 by PageImporter)