Re: Procmail filtering

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 





Alexander Dalloz wrote:
Am Sa, den 14.01.2006 schrieb Lovell Mcilwain um 16:31:

  
I seem to be having a bit of trouble getting procmail to filter e mails 
to individual mailboxes on my FC4 machine.

I am using fetchmail to poll my email to my machine and I want to use 
procmail rather my then my mail client to filter my e mail.  I don't 
have many mailboxes but I change machines often enough that its hard to 
keep updating my mail client filters.

When I tail my mail.log file it does show that .fetchmail is looking at 
my .forward file in my home directory so I am assuming that there is an 
issue with the syntax of my .procmailrc file.  Im new to using procmail 
so I copied and pasted some procmail examples into my .procmailrc file 
and gave it a whirl but no luck.

Any help is appreciated..


Here are what I have in my files:

.forward:

"|IFS=' ' && exec /usr/bin/procmail || exit 75 #myusername"
    
Why that kind of call? I assume you run  local MTA, which is Sendmail.
Correct? Then Procmail is called automatically and you don't need to use
a .forward for this.

  
I have gotten rid of my .forward file so this is not out of the picture.

.procmailrc:

# .procmailrc
# routes incoming mail to appropriate mailboxes
VERBOSE=off
    
Why off? You are debugging, so use the power of logging verbosely.

  
I turned this on so that I can start debugging.  I have not taken a look until Im sure that I have set up my .procmailrc file reasonably ok.

MAILDIR=~/mail/IMAP #elm users might use $HOME/Mail instead
    
^^^ ? Really intended?
Be aware that "MAILDIR" does not imply to get Maildir format storage.

  
I took a look at the man page and this doesn't seem to be related to the MailDir format of the mailbox.  The insert says
**MAILDIR=$HOME/Mail      #you'd better make sure it exists**
Which makes me think based on the location, it wants me to specify the directory where the mailboxes are stored that I want to send mail to via procmail.


#PMDIR=~/.procmail
DEFAULT=/var/mail/username
    
/var/spool/mail/<user> | /var/mail/<user> is the default INBOX spool, no
need to set that explicitly.
  
I have commented this out.
  
LOGFILE=~/procmail.log
    
Look into your logfile for analyzing.

  
#INCLUDERC=$PMDIR/default.rc
#INCLUDERC=$PMDIR/general.rc
#INCLUDERC=$PMDIR/lists.rc
#INCLUDERC=$PMDIR/guestbook.rc
#INCLUDERC=$PMDIR/spam.rc

# Put mail from mailing lists into mailboxs
:0:
* ^Subject:.*[Subject]
    
You have to escape special signs like "]".
  
I have escaped the entire subject so now it reads:
* ^Subject:.*"[Subject]"

  
Groups
    
Better use absolute paths.

  
:0:
* ^From.*fedora.*list.*list.*@
    
? The Fedora list is the recipient, not the From: sender. You may want
to catch

* ^Sender:.*fedora-list-bounces@redhat\.com

  
Fedora2
    
Very verbose Procmail documentation:

http://pm-doc.sourceforge.net/pm-tips-body.html

Alexander


  

[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux