procmail
[Top] [All Lists]

Re: procmail form /etc/aliases

1996-09-11 12:35:48
bne(_at_)baynestudio(_dot_)com asked,

Well, we have already seen what bne wrote and Alan's and Stephane's citations
therefrom, so I'll cut to the chase:

| I know I am close to a solution because the file I am requesting 
| does return but from postmaster and before that I get an error 
| message also.
| 
| So, on the client machine I get:
| 
|    ----- The following addresses had delivery problems -----
| "|/usr/local/bin/procmail /zen1/info/procmail"   (unrecoverable error)
|     (expanded from: <testing-mailbot(_at_)baynestudio(_dot_)com>)
|  
|    ----- Transcript of session follows -----
| procmail: Couldn't create "/var/mail/998"
| 550 "|/usr/local/bin/procmail /zen1/info/procmail" ... Can't create output: 
| Error 0
| 
| and I also get the message that has the file I want.

Since a pipe invoked in /etc/aliases runs (or should run) unprivileged under
the "nobody" uid, I'm gathering that it does.

When procmail is invoked without the -m option, it tries to make sure it can
write to the compiled-in value for $ORGMAIL.  Even if /etc/procmailrc or
the user's ~/.procmailrc will change it, procmail tries the compiled-in value
first.  If /var/mail/998 or /var/mail/nobody does not exist and the uid of
the process does not have the power to creat files in /var/mail/, procmail
will whine, even if it can do the rest of its job.  Assigning a value for
$ORGMAIL on procmail's command line doesn't seem to make a difference.

Alan posted a solution involving the /etc/procmailrcs/ directory that I'll
take his word for, since, not being a system administrator, I've no
experience with having procmail as the MDA.  But I can tell you this:
if you use the -m option, procmail is supposed to start with $ORGMAIL unset.
So changing the alias to

  "|/usr/local/bin/procmail -m /zen1/info/procmail"

might be all that you need to do.  A couple other effects of -m are that
you must specify an rcfile name as the argument to the option, but you're
already doing that; and that procmail will, until told otherwise, stay cd'ed
to the directory that is current when it is fired up instead of cd'ing on
its own the the user's $HOME, but you already have taken care of that by
assigning $MAILDIR by a full path early in the rcfile.

David Tamkin

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