procmail
[Top] [All Lists]

Trouble splitting off one users mail from the rest

2001-03-12 03:14:49
Hi there folks.

I have looked in the FAQ's for an answer for this problem but can't find it
one, so I'm asking here.

I have just setup sendmail/procmail and have it working fine for both
internal and external mail except for one thing.

I have two users on my system that have email addresses.

I have a domain name registered and I get mail to 
anything(_at_)mydomain(_dot_)com(_dot_)  I
want all the mail to go to me except for one user.

I have tried several procmail scripts and none seem to work for me (I'm
using RH6.2).

In my home dir I have tried the following .procmailrc file.

# Environment variables for procmail
VERBOSE=yes
LOGABSTRACT=all

MAILDIR=${HOME}/Mail
LOGFILE=${HOME}/Mail/procmail.log

:0:
* ^TO_gnunn(_at_)pncomputing\(_dot_)com
/var/spool/gnunn

#Lets all other mail in my mailbox
:0:
${DEFAULT}

and the corresponding log is

procmail: Match on
"(^((Original-)?(Resent-)?(To|Cc|Bcc)|(X-Envelope|Apparently(-Resent)?)-To):
(.*[^-a-zA-Z0-9_.])?)gnunn(_at_)pncomputing\(_dot_)com"
procmail: Locking "/var/spool/gnunn.lock"
procmail: Error while writing to "/var/spool/_O8F.8UGr6.slowey.pncom"
procmail: Lock failure on "/var/spool/gnunn.lock"
procmail: Assigning "LASTFOLDER=/var/spool/gnunn"
procmail: Opening "/var/spool/gnunn"
procmail: Error while writing to "/var/spool/gnunn"
procmail: Locking "/var/spool/mail/pnunn.lock"
procmail: Assigning "LASTFOLDER=/var/spool/mail/pnunn"
procmail: Opening "/var/spool/mail/pnunn"
procmail: Acquiring kernel-lock
procmail: Unlocking "/var/spool/mail/pnunn.lock"
From pncomputing(_at_)yahoo(_dot_)com(_dot_)au  Mon Mar 12 16:57:16 2001
 Subject: Try again today.
  Folder: /var/spool/mail/pnunn                                            1721
procmail: Notified comsat: "pnunn(_at_)557:/var/spool/mail/pnunn"

and it ends up in my directory.

I also tried using

:0
* ^TO_gnunn(_at_)pncomputing\(_dot_)com
! gnunn

but ended up with the mail in the dead.letter box with the following log

procmail: Match on
"(^((Original-)?(Resent-)?(To|Cc|Bcc)|(X-Envelope|Apparently(-Resent)?)-To):
(.*[^-a-zA-Z0-9_.])?)gnunn(_at_)pncomputing\(_dot_)com"
procmail: Assigning "LASTFOLDER=/usr/sbin/sendmail"
From pncomputing(_at_)yahoo(_dot_)com(_dot_)au  Sun Mar 11 11:54:07 2001
 Subject: Trail again and again and again
  Folder: /usr/sbin/sendmail                                               1670
procmail: Notified comsat: "pnunn@:/usr/sbin/sendmail"
procmail: Executing "/usr/sbin/sendmail"
procmail: Match on
"(^((Original-)?(Resent-)?(To|Cc|Bcc)|(X-Envelope|Apparently(-Resent)?)-To):
(.*[^-a-zA-Z0-9_.])?)gnunn(_at_)pncomputing\(_dot_)com"
procmail: Assigning "LASTFOLDER=/usr/sbin/sendmail"
From pncomputing(_at_)yahoo(_dot_)com(_dot_)au  Sun Mar 11 12:02:03 2001
procmail: Executing "/usr/sbin/sendmail"
 Subject: Trial again and again and again
  Folder: /usr/sbin/sendmail                                               1670
procmail: Notified comsat: "pnunn@:/usr/sbin/sendmail"

where it seems to be stuck in a loop.

I also noticed that the Notified line has pnunn@ for the failed ones and
pnunn(_at_)557 for the ones that were sent to me.

So...  Long story, any idea how I make this work?

Also, should I have the .procmailrc in my home dir or in the /etc dir?  How
does it work if I'm not logged in if its in mine only?

Thanks in advance...

Peter

Attachment: Peter Nunn.vcf
Description: Vcard

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