Re: Breaking up large archives?

From: Darryl Lee <lee_at_darryl.com_at_hypermail-project.org>
Date: Thu, 6 Jul 2000 10:15:12 -0700 (PDT)
Message-Id: <200007061715.KAA24511_at_shell3.ba.best.com>


> Hi,
>
> I wonder: Is it possible to configure Hypermail in a way that he
> automatically breaks the archive up (say in monthly chunks)?
>
> I have a rather large archive at: http://spam.zyn.de and the loading times
> are horrible....
>
> Thanks.

Here's my embarrassingly ugly solution for splitting ongoing archives into months. (i really should rewrite it in Perl, as shell scripts are quite disgusting.) i simply have a cron job run the following script at 12:01am on the 1st of every month. It simply creates a new directory every month (200006/ for instance), and then moves everything from current/ into it. It then copies a blank index file into that directory in case somebody stumbles upon it before there have been any new messages archived:

 cd /webadmin/home/web2/notyou/public_html/winmac  mkdir `date -v -1m "+%Y%m"`
 mv current/*.html `date -v -1m "+%Y%m"`  cp index.empty current/index.shtml

But since you're also trying to split up an already existing archive, if you don't have the messages in mbox format, first use the tool that came with hypermail (contrib/hypetombox.pl) for converting messages back into mbox format, and then grab the very handy perl script mms (mailbox month splitter) and let it have at it. (http://www.netrus.net/users/troc/perl.html)

Have fun. :}

-- 
Darryl Lee <lee_at_darryl.com> | Bore yourself silly: <http://www.darryl.com>
Received on Thu 06 Jul 2000 07:19:05 PM GMT

This archive was generated by hypermail 2.2.0 : Thu 22 Feb 2007 07:33:52 PM GMT GMT