Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 17 May 2001 09:56:26 -0500
From:      Joe Guetler <joe@axiomadvertising.com>
To:        freebsd-questions@freebsd.org
Subject:   Re: Need a way to duplicate every message on mail server
Message-ID:  <3B03E69B.D2331192@axiomadvertising.com>
References:  <45ba5b45ac14.45ac1445ba5b@mbox.com.au> <NEBBKIPDBLGMBFJFJDOMEEECCDAA.jhvhs@promavto.ru> <20010517161930.C35403@everest.wananchi.com>

next in thread | previous in thread | raw e-mail | index | archive | help
	
Odhiambo Washington wrote:
> 
> * Konstantin V. SEMENOV <jhvhs@promavto.ru> [20010517 13:41]: writing on the subject 'RE: Need a way to duplicate every message on mail server'
> Konstantin>
> Konstantin>
> Konstantin> > -----Original Message-----
> Konstantin> > From: owner-freebsd-questions@FreeBSD.ORG
> Konstantin> > [mailto:owner-freebsd-questions@FreeBSD.ORG]On Behalf Of BSD Freak
> Konstantin> > Sent: Thursday, May 17, 2001 2:16 PM
> Konstantin> > To: freebsd-questions@FreeBSD.ORG
> Konstantin> > Subject: Need a way to duplicate every message on mail server
> Konstantin> >
> Konstantin> >
> Konstantin> > Hi everyone,
> Konstantin> >
> Konstantin> > I run several FreeBSD mail servers (sendmail) and need a way to
> Konstantin> > duplicate every user's incoming messages to a single mailbox for
> Konstantin> > archival purposes. Can this also be done for outgoing (SMTP) messages?
> Konstantin> > Look forward to enlightenment from the list,
> Konstantin> >
> Konstantin> > Best Regards...... and thanks in advance..... :-)
> Konstantin> >
> Konstantin>
> Konstantin> use /etc/mail/aliases
> Konstantin> ie - user1: user1, archive
> Konstantin>
> Konstantin> don't forget to execute newaliases afterwards
> 
> What happens if you have over 5K users and they were already
> existent on the system?? well you can have the file in db
> format, yes so that it's processed more quickly by your MTA but you'll
> need some script which can take the output of `ls -1` and append it to
> the alias file with a ':' and the two names besides it.
> 
> First create the user called 'archive'.
> 
> I am an amateur at this but I believe the script below will automate the
> process.
> 
> NB: I still DON'T know how to insert TAB character but I believe space
> will do!!
> 
> cd /usr/home
> for i in `ls -1` ; do
> echo $i: "" $i, archive >> /etc/mail/aliases
> done
> /usr/bin/newaliases
> exit
> 

I'm no expert, but wouldn't a procmail recipe be able to duplicate
incoming and outgoing mail to an archive?
btw, I just starting learning procmail, so don't look to me to write the
recipe if it can :)

Joe

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




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