Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 23 May 2003 09:32:51 -0700
From:      Joe Miller <joeym@joeym.net>
To:        ODHIAMBO Washington <wash@wananchi.com>, freebsd-isp@freebsd.org
Subject:   Re: Expiring old mail in Maildir/
Message-ID:  <20030523163250.GS51524@joeym.net>
In-Reply-To: <20030523161900.GA12569@ns2.wananchi.com>
References:  <20030523161900.GA12569@ns2.wananchi.com>

next in thread | previous in thread | raw e-mail | index | archive | help
http://archivemail.sourceforge.net/

Usage: archivemail [options] mailbox [mailbox...]
Moves old mail in IMAP, mbox, MH or maildir-format mailboxes to an
mbox-format
mailbox compressed with gzip. 

Options are as follows:
  -a, --days-new=NUM    archive messages _newer_ than NUM days
(default: 30)
  -A, --date-new=DATE   archive messages _newer_ than DATE
  -d, --days=NUM        archive messages older than NUM days
(default: 180)
  -D, --date=DATE       archive messages older than DATE
  -o, --output-dir=DIR  directory to store archives (default: same as
original)
  -s, --suffix=NAME     suffix for archive filename (default: '_archive')
  -S, --size=NUM        only archive messages NUM bytes or larger
  -n, --dry-run         don't write to anything - just show what would be
done
  -u, --preserve-unread never archive unread messages
      --delete          delete rather than archive old mail (use with
caution!)
      --include-flagged messages flagged important can also be archived
      --no-compress     do not compress archives with gzip
      --warn-duplicate  warn about duplicate Message-IDs in the same
mailbox
  -v, --verbose         report lots of extra debugging information
  -q, --quiet           quiet mode - print no statistics (suitable for
crontab)
  -V, --version         display version information
  -h, --help            display this message

Example: archivemail linux-kernel
  This will move all messages older than 180 days to a 'mbox' mailbox
called 
  'linux-kernel_archive.gz', deleting them from the original
'linux-kernel'
  mailbox. If the 'linux-kernel_archive.gz' mailbox already exists, the 
  newly archived messages are appended.

To archive IMAP mailboxes, format your mailbox argument like this:
  imap://username:password@server/mailbox


-- 
Joe Miller


On Fri, May 23, 2003 at 07:19:00PM +0300, ODHIAMBO Washington wrote:
 // 
 // Hiya ISP Admins,
 // 
 // 
 // Apart from using `find`, I am wondering if someone already owns the wheel
 // that can expire mail older than N number of days from users Maildir.
 // I used to use one by Phil Male of Information Systems Engineering Group
 // which was well adapted for mbox-type mailboxes, but now I have changed to
 // Maildir/
 // 
 // Thanks in advance for any pointers.
 // 
 // 
 // -Wash
 // 
 // -- 
 // Odhiambo Washington   <wash@wananchi.com>  "The box said 'Requires
 // Wananchi Online Ltd.  www.wananchi.com      Windows 95, NT, or better,'
 // Tel: +254 2 313985-9  +254 2 313922         so I installed FreeBSD."   
 // GSM: +254 72 743223   +254 733 744121       This sig is McQ!  :-)
 // 
 // 
 // Stult's Report:
 // 	Our problems are mostly behind us.  What we have to do now is
 // fight the solutions.
 // _______________________________________________
 // freebsd-isp@freebsd.org mailing list
 // http://lists.freebsd.org/mailman/listinfo/freebsd-isp
 // To unsubscribe, send any mail to "freebsd-isp-unsubscribe@freebsd.org"



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030523163250.GS51524>