Evan Platt | 26 May 19:19 2010

Procmail on Linux / LMTP

Not sure if this is more a procmail or postfix issue, so seeing if 
anyone here can help...

I run a mail server for my own domain, just me basically. I was
running on a Mac Mini, but the thing kept overheating, so I've
switched to a FC12 desktop. I installed postfix, cyrus, procmail, etc
from yum. Copied / modified my main / master.cf . Everything seemed to
be OK, but I'm guessing something was modified somewhere along the
line, not obviously by me. Difference I initially see, is added in the
main.cf is:
mailbox_transport = lmtp:unix:/var/lib/imap/socket/lmtp
The mac had no mailbox_transport. Now it seems no matter what I do, I
can't get procmail to work with postfix.

In my /home/≤username>/procmailrc, I have
MAILDIR=/var/spool/imap/e/user/eplatt/ , but procmail isn't running or
called - at least nothing's being put in /var/log/procmail.log
(verbose is on). If I rem out the mailbox_transport line in my
main.cf, procmail is run, but near as I can tell, the mail doesn't
make it to my inbox - when I comment it out, I see procmail logging,
but the mail doesn't show in the mail dir.

Basically, in short, I'd like to enable procmail, but not seeing how
to do this with the lmtp configuration.

Any guidance appreciated. I've attached my old and my current postconf
-n .

Thanks.

(Continue reading)

Patrick Shanahan | 26 May 21:27 2010
Picon

Re: Procmail on Linux / LMTP

* Evan Platt <evan <at> espphotography.com> [05-26-10 13:22]:
> Not sure if this is more a procmail or postfix issue, so seeing if
> anyone here can help...
> 
> I run a mail server for my own domain, just me basically. I was
> running on a Mac Mini, but the thing kept overheating, so I've
> switched to a FC12 desktop. I installed postfix, cyrus, procmail, etc
> from yum. Copied / modified my main / master.cf . Everything seemed to
> be OK, but I'm guessing something was modified somewhere along the
> line, not obviously by me. Difference I initially see, is added in the
> main.cf is:
> mailbox_transport = lmtp:unix:/var/lib/imap/socket/lmtp
> The mac had no mailbox_transport. Now it seems no matter what I do, I
> can't get procmail to work with postfix.
> 
> In my /home/≤username>/procmailrc, I have
> MAILDIR=/var/spool/imap/e/user/eplatt/ , but procmail isn't running or
> called - at least nothing's being put in /var/log/procmail.log
> (verbose is on). If I rem out the mailbox_transport line in my
> main.cf, procmail is run, but near as I can tell, the mail doesn't
> make it to my inbox - when I comment it out, I see procmail logging,
> but the mail doesn't show in the mail dir.
> 
> Basically, in short, I'd like to enable procmail, but not seeing how
> to do this with the lmtp configuration.
> 
> Any guidance appreciated. I've attached my old and my current postconf

No expert, but I have (on openSUSE 11.2):

(Continue reading)

Evan Platt | 26 May 21:56 2010

Re: Procmail on Linux / LMTP

On 05/26/2010 12:27 PM, Patrick Shanahan wrote:
> No expert, but I have (on openSUSE 11.2):
> main.cf
> mailbox_command = /usr/bin/procmail
>
> master.cf
> procmail  unix  -       n       n       -       -       pipe
>    flags=R user=nobody argv=/usr/bin/procmail -t -m /etc/procmailrc
>    ${sender} ${recipient}
>    

Should the flags= go on the next line or the same line as the procmail 
line? I think i tried it both ways, still no go. :(
Gustavo Villaran | 26 May 21:58 2010
Picon

Help wit filtering recipe

Hi i need to filter some emails with procmail but im new to this and i 
dont know how to do it, i need
to do the following :

IF  the target email is "xxx <at> abc.com" and the sender is "a <at> abc.com" or 
"b <at> abc.com"
then the email needs to be delivered
else the email should be deleted

thats it

if anyone please can help me should be great.

thx

--

-- 
Este mensaje ha sido analizado por MailScanner
en busca de virus y otros contenidos peligrosos,
y se considera que está limpio.
For all your IT requirements visit: http://www.transtec.co.uk
Patrick Shanahan | 26 May 22:35 2010
Picon

Re: Procmail on Linux / LMTP

* Evan Platt <evan <at> espphotography.com> [05-26-10 15:58]:
> On 05/26/2010 12:27 PM, Patrick Shanahan wrote:
> >No expert, but I have (on openSUSE 11.2):
> >main.cf
> >mailbox_command = /usr/bin/procmail
> >
> >master.cf
> >procmail  unix  -       n       n       -       -       pipe
> >   flags=R user=nobody argv=/usr/bin/procmail -t -m /etc/procmailrc
> >   ${sender} ${recipient}
> 
> Should the flags= go on the next line or the same line as the
> procmail line? I think i tried it both ways, still no go. :(

mia culpa, the master.cf line is *one* line.  I should have added
explanation or a continuation char to the lines.

procmail  unix  -       n       n       -       -       pipe \
   flags=R user=nobody argv=/usr/bin/procmail -t -m /etc/procmailrc \
   ${sender} ${recipient}

--

-- 
Patrick Shanahan         Plainfield, Indiana, USA        HOG # US1244711
http://wahoo.no-ip.org     Photo Album:  http://wahoo.no-ip.org/gallery2
Registered Linux User #207535                     <at>  http://counter.li.org
Michelle Konzack | 26 May 22:43 2010
Picon

Re: Help wit filtering recipe

Hello Gustavo Villaran,

Am 2010-05-26 14:58:38, hacktest Du folgendes herunter:
> Hi i need to filter some emails with procmail but im new to this and
> i dont know how to do it, i need
> to do the following :
> 
> IF  the target email is "xxx <at> abc.com" and the sender is "a <at> abc.com"
> or "b <at> abc.com"
> then the email needs to be delivered
> else the email should be deleted
> 
> thats it
> 
> if anyone please can help me should be great.

    :0
    * ^To:.*xxx <at> abc\.com
    * ^From:.*(a|b) <at> abc\.com
    /dev/null

Thanks, Greetings and nice Day/Evening
    Michelle Konzack

--

-- 
##################### Debian GNU/Linux Consultant ######################
   Development of Intranet and Embedded Systems with Debian GNU/Linux

itsystems <at> tdnet France EURL       itsystems <at> tdnet UG (limited liability)
Owner Michelle Konzack            Owner Michelle Konzack
(Continue reading)

Patrick Shanahan | 26 May 22:51 2010
Picon

Re: Help wit filtering recipe

* Michelle Konzack <linux4michelle <at> tamay-dogan.net> [05-26-10 16:44]:
> Am 2010-05-26 14:58:38, hacktest Du folgendes herunter:
> > Hi i need to filter some emails with procmail but im new to this and
> > i dont know how to do it, i need
> > to do the following :
> > 
> > IF  the target email is "xxx <at> abc.com" and the sender is "a <at> abc.com"
> > or "b <at> abc.com"
> > then the email needs to be delivered
> > else the email should be deleted
> > 
> > thats it
> > 
> > if anyone please can help me should be great.
> 
>     :0
>     * ^To:.*xxx <at> abc\.com
>     * ^From:.*(a|b) <at> abc\.com
>     /dev/null
> 
> 
> Thanks, Greetings and nice Day/Evening
>     Michelle Konzack

I believe you have been somewhat hasty and a bit reckless here.  Above
will deliver mails *wanted* to /dev/null rather than the opposite.

:0
* ^To:.*xxx\ <at> abc\.com
* !^From:.*(a|b)\ <at> abc.\com
(Continue reading)

Evan Platt | 26 May 22:56 2010

Re: Procmail on Linux / LMTP

On 05/26/2010 01:35 PM, Patrick Shanahan wrote:
>
> mia culpa, the master.cf line is *one* line.  I should have added
> explanation or a continuation char to the lines.
>
> procmail  unix  -       n       n       -       -       pipe \
>     flags=R user=nobody argv=/usr/bin/procmail -t -m /etc/procmailrc \
>     ${sender} ${recipient}
>
>    

Still no go :(

I added it with the seperator, and with it all on one line. :( This 
really has me boggled.. Thanks for any suggestions..
Charles Gregory | 26 May 23:04 2010

Re: Procmail on Linux / LMTP

On Wed, 26 May 2010, Evan Platt wrote:
>>  procmail  unix  -       n       n       -       -       pipe \
>>      flags=R user=nobody argv=/usr/bin/procmail -t -m /etc/procmailrc \
>>      ${sender} ${recipient}
> Still no go :(
> I added it with the seperator, and with it all on one line. :( This really 
> has me boggled.. Thanks for any suggestions..

Uh, my master.cf does not have any line like this. All I need to
get procmail working is the mailbox_command line in main.cf:

mailbox_command = /usr/bin/procmail

I have mailbox_transport commented out....

...and make sure that you have sensible values in main.cf for:
home_mailbox
mail_spool_directory

Enjoy!

- Charles
Evan Platt | 26 May 23:27 2010

Re: Procmail on Linux / LMTP

On 05/26/2010 02:04 PM, Charles Gregory wrote:
>  all on one line. :( This really has me boggled.. Thanks for any 
> suggestions..
>
> Uh, my master.cf does not have any line like this. All I need to
> get procmail working is the mailbox_command line in main.cf:
>
> mailbox_command = /usr/bin/procmail
>
> I have mailbox_transport commented out....
>
> ...and make sure that you have sensible values in main.cf for:
> home_mailbox
> mail_spool_directory
Ok... I can do that.. Dumb question, what is my home mailbox?
I do have a /var/mail/≤user>, which has 1 file, but it's defnitely not 
my inbox. Only has about 7 'messages' in it (one long file).

thanks :)

Gmane