Table of Contents

Name

mboxscrub - remove old mails from mbox file

Synopsis

mboxscrub [ -D days-to-keep ] mboxfile

Description

Remove old emails from an mbox file.

Options

-D days-to-keep
Keep the last days-to-keep days in mbox file. Default: 40

Return Value

The return value is 0 / EX_OK when no error happened. When the mbox file can’t be read EX_NOINPUT is returned. When the mbox file can’t be opened for writing then EX_CANTCREAT is returned. When the mbox file can’t be written EX_IOERR is returned.

Examples

$ cd /var/spool/mail
$ postlock user1 mboxscrub -D 31 user1

Caveats

The mbox size must be less than 2 GiB when compiled on 32 bit host and otherwise less than 4 GiB.

Author

Frank Bergmann, http://www.tuxad.com


Table of Contents