Re: adding new messages

1998-04-27 12:31:08
On April 25, 1998 at 23:40, Christopher Adams wrote:

#sample-archive: "|/usr/local/mail/majordomo/wrapper -f
/usr/local/mail/lists     \
/sample.archive/sample -a", "|/usr/local/bin/mhonarc -add -outdir
/usr/local/etc/httpd/htdocs/   \
samp /usr/local/mail/lists/sample.archive/sample"
Shouldn't these be part of /usr/local/etc/httpd/htdocs/?

I have included \ at the end of lines to show continuation of the lines.
I DO have it all on one line.
/usr/local/etc/httpd/htodcs/samp is the directory I am writing to.
/usr/local/mail/lists/sample.archive/sample is the mailbox that I am
archiving from. It is my understanding that I need to scan that mailbox
each time, since I am archiving  to that file. Then MHonArc scans it for
new messages and adds it to the MHonArc database.

No.  MHonArc can work that way, but for what you are doing, no.
The new message is already piped into mhonarc via stdin.  Hence,
you want something like:

    "|/usr/local/bin/mhonarc -add -outdir /usr/local/etc/httpd/htdocs/samp"

for the mhonarc portion of you sendmail alias.

The problem of having mhonarc read the actual mailbox file is that it
will be slower, and you have a race condition.  You have a dependency
that majordomo will have appended the new message to the mailbox file
before mhonarc reads the mailbox.  I believe sendmail does not wait
for a processs to terminate before executing the next process in the


             Earl Hood              | University of California: Irvine
      ehood(_at_)medusa(_dot_)acs(_dot_)uci(_dot_)edu      |      Electronic 
Loiterer | Dabbler of SGML/WWW/Perl/MIME

<Prev in Thread] Current Thread [Next in Thread>