On Tuesday, February 4, 2003, at 05:35 PM, Roland Hill wrote:
Having a /etc/procmail/.procmailrc file did not seem to work
/etc/procmailrc is the file.
- Phase 1 of plan: "Drop" mail in /var/spool/mail/<user>
A typical .procmailrc file I created:
PMDIR=/etc/procmail
LOGFILE=/var/log/procmail.log
LOG="
"
##VERBOSE=yes
##LOGABSTRACT=no
MAILDIR=$HOME/evolution
INCLUDERC=$PMDIR/rc.daddy
INCLUDERC=$PMDIR/rc.logan
Filters used for testing (not used concurrently, included in the
rc.daddy file):
#Red Hat filter 1 NEW
:0:
* ^Subject:.*Redhat
/var/spool/mail/roland
#Red Hat filter 2 EXISTING
:0
* ^Subject:.*Red Hat
* !^X-Loop: seenit6
| formail -A "X-Loop: seenit6" | \
$SENDMAIL -oi roland(_at_)monaro(_dot_)local
At the moment I forward the message (see EXISTING recipe) and use a
formail script(?) to stop mail loops. This does not seem efficient.
But as I found out tonight this was my work-around because I had
lockfile errors when the NEW recipe was used - as follows:
procmail: Lock failure on "/var/spool/mail/roland.lock"
procmail: Error while writing to "/var/spool/mail/roland"
This is probably because the procmail is not running as roland and so
doesn't have permissions to write to /var/spool/mail/roland
chown root.mail /var/spool/mail
chmod 775 /var/spool/mail
This didn't work.
If I chmod 666 /var/spool/mail/roland then the "Error while
writing..." disappears, the "Lock failure on...." stays, BUT the
message is delivered as per the recipe.
procmail is trying to create a lockfile in /var/spool/mail and does not
have permission to do so.
I read that 666 should be used with care. Have I done the correct
thing?
I don't think so, but I don't know about your specific setup with
email. I will say that using a single email address and then using
procmail to try to split that to multiple users is ugly and tricky at
best. If your isp only allows one POP/IMAP user, consider finding
another ISP. Or, you could use a service like www.dyndns.org to
register a virtual domain and then have as many users as you want.
roland(_at_)roland(_dot_)is-a-geek(_dot_)com, for example. the is-a-geek.com domain is
one of my favorite ones, and far less crowded than homeip.net or
something.
Can someone help me solve how to remove the lock file error? I haven't
found an answer yet (that I understand), even searched the procmail
archives prior to posting.
you would have to make /var/spool/mail world writable. I think that
would be a VeryBadIdea.
--
Growing up leads to growing old, and then to dying/And dying to me
don't sound like all that much fun.
_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail