Re: [gentoo-user] Procmail replacement

2005-03-06 Thread Brett I. Holcomb
Yes, looks like getmail is to replace fetchmail - interesting links to 
many flames of the author of fetchmail on the site .  I'd have to use 
something else to process the mail

. On Sun, 6 Mar 2005, Jean Magnan de 
Bornier wrote:

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Nick Rout a écrit :
|  On Sat, 2005-03-05 at 19:37 -0700, Mike Melanson wrote:
| 
| > Brett I. Holcomb wrote:
| > 
| > > Some time ago someone on this list mentioned an alternative to procmail
| > > but I can't find it in the archives.  Does anyone know any alternatives
| > > to procmail.
| > 
| > When I decided to dump procmail, I switched to getmail:
| > 
| > *  net-mail/getmail
| >Latest version available: 4.2.5
| >Size of downloaded files: 120 kB
| >Homepage:http://www.qcc.ca/~charlesc/software/getmail-4/
| >Description: A POP3 mail retriever with reliable Maildir and mbox
| > delivery
| >License: GPL-2
| > 
| > Nicest part is that it does not require an SMTP server to be running
| > locally.
| 
| 
|  isn't getmail a replacement for fetchmail? Either you are confused, or I
|  am.

Yes, *getmail* is fetching mail, note quite a replacement of fetchmail
though, but aims at the same basic functions, while *grepmail* can do
the same as procmail, not quite a replacement either. Fetchmail and
procamil may be sometimes hard to deal with, but I believe they are the
most powerful tools in their respective categories
- --
Jean Magnan de Bornier
Cours Victor Hugo
13980 Alleins
T 08 70 39 34 03
P 06 09 17 35 87
e-mots: jean at bornier.net
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.2.6 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
iD8DBQFCKqNO2MXc8v/2IeARAh1HAKCZmJsmQ6i6rEtPojBCK48o/P07pwCgmCfK
kKs08acUAavLiN91zWZ+Xbs=
=MhAP
-END PGP SIGNATURE-
--
gentoo-user@gentoo.org mailing list
--
Brett I. Holcomb
[EMAIL PROTECTED]
Registered Linux User #188143
Remove R777 to email

Re: [gentoo-user] Procmail replacement

2005-03-06 Thread Brett I. Holcomb
Thank you.  I'll check it out.
On Sat, 5 Mar 2005, Kurt V. Hindenburg wrote:
On Saturday 05 March 2005 09:18 pm, Brett I. Holcomb wrote:
| Some time ago someone on this list mentioned an alternative to procmail
| but I can't find it in the archives.  Does anyone know any alternatives to
| procmail.
I use maildrop...
*  mail-filter/maildrop
 Latest version available: 1.8.0-r2
 Latest version installed: 1.8.0-r2
 Size of downloaded files: 1,966 kB
 Homepage:http://www.courier-mta.org/maildrop/
 Description: Mail delivery agent/filter
 License: GPL-2
 Regards,
 Kurt
--
gentoo-user@gentoo.org mailing list
--
Brett I. Holcomb
[EMAIL PROTECTED]
Registered Linux User #188143
Remove R777 to email
--
gentoo-user@gentoo.org mailing list


Re: [gentoo-user] Procmail replacement

2005-03-05 Thread Jean Magnan de Bornier
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Nick Rout a écrit :
| On Sat, 2005-03-05 at 19:37 -0700, Mike Melanson wrote:
|
|>Brett I. Holcomb wrote:
|>
|>>Some time ago someone on this list mentioned an alternative to procmail
|>>but I can't find it in the archives.  Does anyone know any alternatives
|>>to procmail.
|>
|>When I decided to dump procmail, I switched to getmail:
|>
|>*  net-mail/getmail
|>   Latest version available: 4.2.5
|>   Size of downloaded files: 120 kB
|>   Homepage:http://www.qcc.ca/~charlesc/software/getmail-4/
|>   Description: A POP3 mail retriever with reliable Maildir and mbox
|>delivery
|>   License: GPL-2
|>
|>Nicest part is that it does not require an SMTP server to be running
|>locally.
|
|
| isn't getmail a replacement for fetchmail? Either you are confused, or I
| am.
Yes, *getmail* is fetching mail, note quite a replacement of fetchmail
though, but aims at the same basic functions, while *grepmail* can do
the same as procmail, not quite a replacement either. Fetchmail and
procamil may be sometimes hard to deal with, but I believe they are the
most powerful tools in their respective categories
- --
Jean Magnan de Bornier
Cours Victor Hugo
13980 Alleins
T 08 70 39 34 03
P 06 09 17 35 87
e-mots: jean at bornier.net
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.2.6 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
iD8DBQFCKqNO2MXc8v/2IeARAh1HAKCZmJsmQ6i6rEtPojBCK48o/P07pwCgmCfK
kKs08acUAavLiN91zWZ+Xbs=
=MhAP
-END PGP SIGNATURE-
--
gentoo-user@gentoo.org mailing list


Re: [gentoo-user] Procmail replacement

2005-03-05 Thread Mike Melanson
Nick Rout wrote:
isn't getmail a replacement for fetchmail? Either you are confused, or I
am.
Yeah, I am confused. Sorry about that. Holdover from the days when:
fetchmail retrieved the POP mail, then passed it off to...
qmail which processed the mail, which handed it off to...
procmail for sorting and filtering, which also called...
spamprobe for Bayesian spam filtering, and in the end...
pine read the email
These days I just use Thunderbird and life is much simpler.
--
-Mike Melanson
--
gentoo-user@gentoo.org mailing list


Re: [gentoo-user] Procmail replacement

2005-03-05 Thread Nick Rout
On Sat, 2005-03-05 at 19:37 -0700, Mike Melanson wrote:
> Brett I. Holcomb wrote:
> > Some time ago someone on this list mentioned an alternative to procmail 
> > but I can't find it in the archives.  Does anyone know any alternatives 
> > to procmail.
> 
> When I decided to dump procmail, I switched to getmail:
> 
> *  net-mail/getmail
>Latest version available: 4.2.5
>Size of downloaded files: 120 kB
>Homepage:http://www.qcc.ca/~charlesc/software/getmail-4/
>Description: A POP3 mail retriever with reliable Maildir and mbox 
> delivery
>License: GPL-2
> 
> Nicest part is that it does not require an SMTP server to be running 
> locally.

isn't getmail a replacement for fetchmail? Either you are confused, or I
am.


> 
-- 
Nick Rout <[EMAIL PROTECTED]>

--
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] Procmail replacement

2005-03-05 Thread A. Khattri
On Sat, 5 Mar 2005, Kurt V. Hindenburg wrote:

> On Saturday 05 March 2005 09:18 pm, Brett I. Holcomb wrote:
> | Some time ago someone on this list mentioned an alternative to procmail
> | but I can't find it in the archives.  Does anyone know any alternatives to
> | procmail.
>
> I use maildrop...
>
> *  mail-filter/maildrop
>   Latest version available: 1.8.0-r2
>   Latest version installed: 1.8.0-r2
>   Size of downloaded files: 1,966 kB
>   Homepage:http://www.courier-mta.org/maildrop/
>   Description: Mail delivery agent/filter
>   License: GPL-2

I think maildrop can only deliver to Maildirs...

-- 
AK
--
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] Procmail replacement

2005-03-05 Thread Mike Melanson
Brett I. Holcomb wrote:
Some time ago someone on this list mentioned an alternative to procmail 
but I can't find it in the archives.  Does anyone know any alternatives 
to procmail.
When I decided to dump procmail, I switched to getmail:
*  net-mail/getmail
  Latest version available: 4.2.5
  Size of downloaded files: 120 kB
  Homepage:http://www.qcc.ca/~charlesc/software/getmail-4/
  Description: A POP3 mail retriever with reliable Maildir and mbox 
delivery
  License: GPL-2

Nicest part is that it does not require an SMTP server to be running 
locally.

--
-Mike Melanson
--
gentoo-user@gentoo.org mailing list


Re: [gentoo-user] Procmail replacement

2005-03-05 Thread Brett I. Holcomb
Thanks.  I think that was it.  I'll check it out.
On Sat, 5 Mar 2005, Kurt V. Hindenburg wrote:
On Saturday 05 March 2005 09:18 pm, Brett I. Holcomb wrote:
| Some time ago someone on this list mentioned an alternative to procmail
| but I can't find it in the archives.  Does anyone know any alternatives to
| procmail.
I use maildrop...
*  mail-filter/maildrop
 Latest version available: 1.8.0-r2
 Latest version installed: 1.8.0-r2
 Size of downloaded files: 1,966 kB
 Homepage:http://www.courier-mta.org/maildrop/
 Description: Mail delivery agent/filter
 License: GPL-2
 Regards,
 Kurt
--
gentoo-user@gentoo.org mailing list
--
Brett I. Holcomb
[EMAIL PROTECTED]
Registered Linux User #188143
Remove R777 to email
--
gentoo-user@gentoo.org mailing list


Re: [gentoo-user] Procmail replacement

2005-03-05 Thread Kurt V. Hindenburg
On Saturday 05 March 2005 09:18 pm, Brett I. Holcomb wrote:
| Some time ago someone on this list mentioned an alternative to procmail
| but I can't find it in the archives.  Does anyone know any alternatives to
| procmail.

I use maildrop...

*  mail-filter/maildrop
  Latest version available: 1.8.0-r2
  Latest version installed: 1.8.0-r2
  Size of downloaded files: 1,966 kB
  Homepage:http://www.courier-mta.org/maildrop/
  Description: Mail delivery agent/filter
  License: GPL-2

  Regards,
  Kurt
--
gentoo-user@gentoo.org mailing list



[gentoo-user] Procmail replacement

2005-03-05 Thread Brett I. Holcomb
Some time ago someone on this list mentioned an alternative to procmail 
but I can't find it in the archives.  Does anyone know any alternatives to 
procmail.

--
Brett I. Holcomb
[EMAIL PROTECTED]
Registered Linux User #188143
Remove R777 to email
--
gentoo-user@gentoo.org mailing list


Re: [gentoo-user] Procmail and mail aliasses

2005-01-27 Thread Norbert Kamenicky
Patrick Marquetecken wrote:
Hi,
I'm a bit stuck with procmail, i have one email account and several mail
aliasses at my ISP.
I use fetchmail in a cron on user level to get my emails.
I whan't now mails that are for a mail alias (other to address) deliverd
to another local .maildir. The problem is that they are pickup by the
fetchmail script of my main user. I don't know of it is possible with
procmail to point to a different home/.maildir but even then the uid would
be worng of that email.
Whats the best way to deliver those emails?
The problem is more complex as it looks like, because one thing
is mail header item "To:" (which always should stay in header)
and another thing is header item "RCPT TO:" sent to MTA during
mail transport (which is usually stored to item "Delivered-To:")
Non equal "To:" and "rcpt to:"  are used e.g. in this ML -
"To: [EMAIL PROTECTED]", "rcpt to: [EMAIL PROTECTED]".
Now it depends on ISP's MTA, what will happen next. i.e. if "rcpt to:"
mail address is stored to mail header or not.
I have bad experience using procmail on ISP's side, because it must be
used with "preline" (to prevent adding "Delivered-To:" item witch
causes mail bouncing by your MTA) and therefore "original" address
"RCPT TO:" is lost. (I don't remember it exactly, so may be wrong.)
But back to your problem ...
open fetched mail in source view to check if u can find "original"
address ... if yes, it's simple ... just write a rule for procmail
based on the item u find, can look like this ...
:0
* ^some-item: [EMAIL PROTECTED]
.path/to/users/maildir/
HTH
noro
--
gentoo-user@gentoo.org mailing list


Re: [gentoo-user] Procmail and mail aliasses

2005-01-27 Thread Norbert Kamenicky
Patrick Marquetecken wrote:
Hi,
I'm a bit stuck with procmail, i have one email account and several mail
aliasses at my ISP.
I use fetchmail in a cron on user level to get my emails.
I whan't now mails that are for a mail alias (other to address) deliverd
to another local .maildir. The problem is that they are pickup by the
fetchmail script of my main user. I don't know of it is possible with
procmail to point to a different home/.maildir but even then the uid would
be worng of that email.
Whats the best way to deliver those emails?
TIA

The problem is more complex as it looks like, because one thing
is mail header item "To:" (which always should stay in header)
and another thing is header item "RCPT TO:" sent to MTA during
mail transport (which is usually stored to item "Delivered-To:")
Non equal "To:" and "rcpt to:"  are used e.g. in this ML -
"To: [EMAIL PROTECTED]", "rcpt to: [EMAIL PROTECTED]".
Now it depends on ISP's MTA, what will happen next. i.e. if "rcpt to:"
mail address is stored to mail header or not.
I have bad experience using procmail on ISP's side, because it must be
used with "preline" (to prevent adding "Delivered-To:" item witch
causes mail bouncing by your MTA) and therefore "original" address
"RCPT TO:" is lost. (I don't remember it exactly, so may be wrong.)
But back to your problem ...
open fetched mail in source view to check if u can find "original"
address ... if yes, it's simple ... just write a rule for procmail
based on the item u find, can look like this ...
:0
* ^some-item: [EMAIL PROTECTED]
.path/to/users/maildir/
HTH
noro
--
gentoo-user@gentoo.org mailing list


Re: [gentoo-user] Procmail and mail aliasses

2005-01-27 Thread Norbert Kamenicky
Patrick Marquetecken wrote:
Hi,
I'm a bit stuck with procmail, i have one email account and several mail
aliasses at my ISP.
I use fetchmail in a cron on user level to get my emails.
I whan't now mails that are for a mail alias (other to address) deliverd
to another local .maildir. The problem is that they are pickup by the
fetchmail script of my main user. I don't know of it is possible with
procmail to point to a different home/.maildir but even then the uid would
be worng of that email.
Whats the best way to deliver those emails?
The problem is more complex as it looks like, because one thing
is mail header item "To:" (which always should stay in header)
and another thing is header item "RCPT TO:" sended to MTA during
mail transport (which is usually stored to item "Delivered-To:")
Non equal "To:" and "rcpt to:"  are used e.g. in this ML -
"To: [EMAIL PROTECTED]", "rcpt to: [EMAIL PROTECTED]".
Now it depends on ISP's MTA, what will happen next. i.e. if "rcpt to:"
mail addres is stored to mail header or not.
I have bad experience using procmail on ISP's side, because it must be
used with "preline" (to prevent adding "Delivered-To:" item witch
causes mail bounceing by your MTA) and therefore "original" address
"RCPT TO:" is lost. (I don't remember it exactly, so may be wrong.)
But back to your problem ...
open fetched mail in source view to check if u can find "original"
address ... if yes, it's simple ... just write a rule for procmail
based on the item u find, can look like this ...
:0
* ^some-item: [EMAIL PROTECTED]
.path/to/users/maildir/
HTH
noro
--
gentoo-user@gentoo.org mailing list


Re: [gentoo-user] Procmail and mail aliasses

2005-01-27 Thread Patrick Marquetecken
> Hi,
>
> Patrick Marquetecken wrote:
>



> Well, best way is in fact procmail. On the account that receives the
> emails you can do:
>
> :0
> * [EMAIL PROTECTED]
> ! [EMAIL PROTECTED]
>
> :0 [EMAIL PROTECTED]
> ! [EMAIL PROTECTED]
>
> And so on. Then your MTA will do the job of delivering the mail to the
> other users, invoking their own procmail and so on. I use Postfix so I
> can share my config with you if you wish.
>
> AFAIK, this won't work for BCCs since the address that was BCCed doesn't
> end up in the mail headers.
>
> HTH,
> Chris
>
It works,
Thanks
Patrick

--
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] Procmail and mail aliasses

2005-01-27 Thread Chris Boot
Hi,
Patrick Marquetecken wrote:
On Thu, 2005-01-27 at 10:34 +0100, Patrick Marquetecken wrote:
   

Hi,
I'm a bit stuck with procmail, i have one email account and several mail
aliasses at my ISP.
I use fetchmail in a cron on user level to get my emails.
I whan't now mails that are for a mail alias (other to address) deliverd
to another local .maildir. The problem is that they are pickup by the
fetchmail script of my main user. I don't know of it is possible with
procmail to point to a different home/.maildir but even then the uid
would
be worng of that email.
Whats the best way to deliver those emails?
TIA
 

Well, best way is in fact procmail. On the account that receives the 
emails you can do:

:0
* [EMAIL PROTECTED]
! [EMAIL PROTECTED]
:0 [EMAIL PROTECTED]
! [EMAIL PROTECTED]
And so on. Then your MTA will do the job of delivering the mail to the 
other users, invoking their own procmail and so on. I use Postfix so I 
can share my config with you if you wish.

AFAIK, this won't work for BCCs since the address that was BCCed doesn't 
end up in the mail headers.

HTH,
Chris
--
gentoo-user@gentoo.org mailing list


Re: [gentoo-user] Procmail and mail aliasses

2005-01-27 Thread Patrick Marquetecken

> On Thu, 2005-01-27 at 10:34 +0100, Patrick Marquetecken wrote:
>> Hi,
>>
>> I'm a bit stuck with procmail, i have one email account and several mail
>> aliasses at my ISP.
>> I use fetchmail in a cron on user level to get my emails.
>> I whan't now mails that are for a mail alias (other to address) deliverd
>> to another local .maildir. The problem is that they are pickup by the
>> fetchmail script of my main user. I don't know of it is possible with
>> procmail to point to a different home/.maildir but even then the uid
>> would
>> be worng of that email.
>> Whats the best way to deliver those emails?
>>
>> TIA
>
>
> run fetchmail for the other user.
>
> --
> Nick Rout <[EMAIL PROTECTED]>
>
>
won't work because on the ISP side its all in the same user mailbox.

Patrick


--
gentoo-user@gentoo.org mailing list



Re: [gentoo-user] Procmail and mail aliasses

2005-01-27 Thread Nick Rout
On Thu, 2005-01-27 at 10:34 +0100, Patrick Marquetecken wrote:
> Hi,
> 
> I'm a bit stuck with procmail, i have one email account and several mail
> aliasses at my ISP.
> I use fetchmail in a cron on user level to get my emails.
> I whan't now mails that are for a mail alias (other to address) deliverd
> to another local .maildir. The problem is that they are pickup by the
> fetchmail script of my main user. I don't know of it is possible with
> procmail to point to a different home/.maildir but even then the uid would
> be worng of that email.
> Whats the best way to deliver those emails?
> 
> TIA


run fetchmail for the other user.


> 
> 
> 
> --
> gentoo-user@gentoo.org mailing list
> 
-- 
Nick Rout <[EMAIL PROTECTED]>


--
gentoo-user@gentoo.org mailing list



[gentoo-user] Procmail and mail aliasses

2005-01-27 Thread Patrick Marquetecken
Hi,

I'm a bit stuck with procmail, i have one email account and several mail
aliasses at my ISP.
I use fetchmail in a cron on user level to get my emails.
I whan't now mails that are for a mail alias (other to address) deliverd
to another local .maildir. The problem is that they are pickup by the
fetchmail script of my main user. I don't know of it is possible with
procmail to point to a different home/.maildir but even then the uid would
be worng of that email.
Whats the best way to deliver those emails?

TIA



--
gentoo-user@gentoo.org mailing list



[gentoo-user] procmail for virtual users ?

2003-12-27 Thread albert
My setup is the one described in the gentoo virtual mailhosting howto
(setup with mysql tables http://www.gentoo.org/doc/en/virt-mail-howto.xml
). I have added SpamAssassin to the mix and I have procmail doing local
delivery, i.e. for non-virtual mailboxes (by adding "mailbox_command =
/usr/bin/procmail" to /etc/postfix/main.cf), but I can't figure out how to
get it to do the delivery for virtual mailboxes.


--
[EMAIL PROTECTED] mailing list



[gentoo-user] procmail for virtual users

2003-12-25 Thread albert
I followed the virtual mailhost manual on the gentoo website. However i
was wondering how you could implement that a virtual user can define their
own procmail file ? I tried creating a procmail file in the mail directory
of the virtual user but that doesn't work. It seems that there is a little
more to it.

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail/Fetchmail and Vcron

2003-10-26 Thread BlueRibbon
I don't know what the problem is yet... That didn't solved it :(
But... now I execute a file "getmail", from the cron (that contains 
exactly the same command), and ti works... weird!

Thanx anyway! :)

Pat Kerwan wrote:

On Sun, Oct 26, 2003 at 03:17:13AM +, BlueRibbon wrote:
 

Hi!
I have this line on my crontab:
*/5 * * * * /usr/bin/fetchmail -a -s -m "/usr/bin/procmail -d \%T"
   

Try it without the '\' character.  Mine doesn't have that, and it works.

- PK

 

But when the cron tries to run the job, it gives me the following error 
(by mail):

sh: -c: line 1: unexpected EOF while looking for matching `''
sh: -c: line 2: syntax error: unexpected end of file
fetchmail: SIGPIPE thrown from an MDA or a stream socket error
fetchmail: socket error while fetching from pop.netcabo.pt
fetchmail: Query status=2 (SOCKET)
sh: -c: line 1: unexpected EOF while looking for matching `''
sh: -c: line 2: syntax error: unexpected end of file
fetchmail: MDA returned nonzero status 2
sh: -c: line 1: unexpected EOF while looking for matching `''
sh: -c: line 2: syntax error: unexpected end of file
fetchmail: SIGPIPE thrown from an MDA or a stream socket error
fetchmail: socket error while fetching from pop.netcabo.pt
fetchmail: Query status=2 (SOCKET)
What's wrong with that line to make this prob happen?
Thanx
--
[EMAIL PROTECTED] mailing list
   



--
[EMAIL PROTECTED] mailing list
 



--
[EMAIL PROTECTED] mailing list


Re: [gentoo-user] Procmail/Fetchmail and Vcron

2003-10-26 Thread Pat Kerwan


On Sun, Oct 26, 2003 at 03:17:13AM +, BlueRibbon wrote:
> Hi!
> I have this line on my crontab:
> */5 * * * * /usr/bin/fetchmail -a -s -m "/usr/bin/procmail -d \%T"
> 

Try it without the '\' character.  Mine doesn't have that, and it works.

- PK

> But when the cron tries to run the job, it gives me the following error 
> (by mail):
> 
> sh: -c: line 1: unexpected EOF while looking for matching `''
> sh: -c: line 2: syntax error: unexpected end of file
> fetchmail: SIGPIPE thrown from an MDA or a stream socket error
> fetchmail: socket error while fetching from pop.netcabo.pt
> fetchmail: Query status=2 (SOCKET)
> sh: -c: line 1: unexpected EOF while looking for matching `''
> sh: -c: line 2: syntax error: unexpected end of file
> fetchmail: MDA returned nonzero status 2
> sh: -c: line 1: unexpected EOF while looking for matching `''
> sh: -c: line 2: syntax error: unexpected end of file
> fetchmail: SIGPIPE thrown from an MDA or a stream socket error
> fetchmail: socket error while fetching from pop.netcabo.pt
> fetchmail: Query status=2 (SOCKET)
> 
> What's wrong with that line to make this prob happen?
> Thanx
> 
> 
> --
> [EMAIL PROTECTED] mailing list


--
[EMAIL PROTECTED] mailing list



[gentoo-user] Procmail/Fetchmail and Vcron

2003-10-26 Thread Janis Kracht
Originally to: BlueRibbon

Hi ya,

> I have this line on my crontab:
> */5 * * * * /usr/bin/fetchmail -a -s -m "/usr/bin/procmail -d \%T"

Looks like your fields are out of whack here..  first of all, there should be just 3 
asterisks?  Here's a line from how I call some cron jobs:

08 0-23/6 * * * /home/bbbs/jdavismail.sh

> But when the cron tries to run the job, it gives me the following error
> (by mail):

> sh: -c: line 1: unexpected EOF while looking for matching `''
> sh: -c: line 2: syntax error: unexpected end of file
> fetchmail: SIGPIPE thrown from an MDA or a stream socket error
> fetchmail: socket error while fetching from pop.netcabo.pt
> fetchmail: Query status=2 (SOCKET)
> sh: -c: line 1: unexpected EOF while looking for matching `''
> sh: -c: line 2: syntax error: unexpected end of file
> fetchmail: MDA returned nonzero status 2
> sh: -c: line 1: unexpected EOF while looking for matching `''
> sh: -c: line 2: syntax error: unexpected end of file
> fetchmail: SIGPIPE thrown from an MDA or a stream socket error
> fetchmail: socket error while fetching from pop.netcabo.pt
> fetchmail: Query status=2 (SOCKET)

I've never run fetchmail from a cron job.. I used to call it under mandrake as a 
daemon (fetchmail -d 300).  I'm not sure if that would be the usage under gentoo.

Janis
([EMAIL PROTECTED])



--
[EMAIL PROTECTED] mailing list



[gentoo-user] Procmail/Fetchmail and Vcron

2003-10-25 Thread BlueRibbon
Hi!
I have this line on my crontab:
*/5 * * * * /usr/bin/fetchmail -a -s -m "/usr/bin/procmail -d \%T"
But when the cron tries to run the job, it gives me the following error 
(by mail):

sh: -c: line 1: unexpected EOF while looking for matching `''
sh: -c: line 2: syntax error: unexpected end of file
fetchmail: SIGPIPE thrown from an MDA or a stream socket error
fetchmail: socket error while fetching from pop.netcabo.pt
fetchmail: Query status=2 (SOCKET)
sh: -c: line 1: unexpected EOF while looking for matching `''
sh: -c: line 2: syntax error: unexpected end of file
fetchmail: MDA returned nonzero status 2
sh: -c: line 1: unexpected EOF while looking for matching `''
sh: -c: line 2: syntax error: unexpected end of file
fetchmail: SIGPIPE thrown from an MDA or a stream socket error
fetchmail: socket error while fetching from pop.netcabo.pt
fetchmail: Query status=2 (SOCKET)
What's wrong with that line to make this prob happen?
Thanx
--
[EMAIL PROTECTED] mailing list


[gentoo-user] procmail compile failure

2003-10-17 Thread Dennis Robertson
Procmail-3.22-r6 failed to emerge with the complaint:
sublib.o: file not recognised: File truncated
collect2: ld returned 1 exit status
Can anyone assist please? Thanks.


--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification"

2003-09-01 Thread Jason Stubbs
Ignore the previous message - I still haven't figured it out but there are 
enough tools written in perl to not bother piping the message here and there 
to extract small amounts of information. I'll post my complete script once 
I'm done!

On Monday 01 September 2003 13:04, Jason Stubbs wrote:
> I'm trying to go with perl now as it is much faster and seemingly more
> capable. I've ran into a problem that I can't figure out, though. The
> behaviour of the following seems very strange:
>
> my $pid = open2(*Reader, *Writer, 'formail -x From:');
> # dies with "Broken Pipe"
> my $pid = open2(*Reader, *Writer, 'formail -I ""');
> # never returns
> my $pid = open2(*Reader, *Writer, 'cat');
> # never returns
>
> Have I, a perl newbie, done something really newbtabulous? Or perhaps
> there's something wrong with my installation of Perl. The above are pretty
> much the same as the IPC man page's Bidirectional Communication section.
> Should I try the open_proc it talks about instead? Is open_proc somewhere
> in portage?

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification"

2003-09-01 Thread Jason Stubbs
On Sunday 31 August 2003 21:27, Spider wrote:
> Actually, May I suggest a look at AWK , very often used
> together with bash when bash raises its head to show bald spots?

I checked out AWK and tried using it to insert spaces at the start of 
multiline headers. I got half-way but ran into trouble.

I'm trying to go with perl now as it is much faster and seemingly more 
capable. I've ran into a problem that I can't figure out, though. The 
behaviour of the following seems very strange:

my $pid = open2(*Reader, *Writer, 'formail -x From:');
# dies with "Broken Pipe"
my $pid = open2(*Reader, *Writer, 'formail -I ""');
# never returns
my $pid = open2(*Reader, *Writer, 'cat');
# never returns

Have I, a perl newbie, done something really newbtabulous? Or perhaps there's 
something wrong with my installation of Perl. The above are pretty much the 
same as the IPC man page's Bidirectional Communication section. Should I try 
the open_proc it talks about instead? Is open_proc somewhere in portage?

Regards,
Jason

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification"

2003-08-31 Thread Spider
begin  quote
On Sun, 31 Aug 2003 07:41:18 +0900
Jason Stubbs <[EMAIL PROTECTED]> wrote:


> > I'm sorry to say, but I think you might have just exceeded the
> > capabilities of bash.  You can play around with stuff, but it looks
> > like bash likes to ditch leading spaces.  I think you need to crack
> > open the perl man pages or possibly go to temp files from within
> > procmail.
> >

Not entirely, check below


> 
> Yeah, I tried that too. I take it this is why real programmers often
> scoff at bash "programmers". So what're bash scripts good for then?
> Just automation with a small amount of primitive conditionals?


Actually, May I suggest a look at AWK , very often used
together with bash when bash raises its head to show bald spots?


//Spider


-- 
begin  .signature
This is a .signature virus! Please copy me into your .signature!
See Microsoft KB Article Q265230 for more information.
end


pgp0.pgp
Description: PGP signature


Re: [gentoo-user] Procmail and mail "notification"

2003-08-31 Thread Marshal Newrock
On Sun, 31 Aug 2003, Jason Stubbs wrote:

> > I'm pretty sure that 'read' will also ditch leading spaces, and I don't
> > know how to get around that.
>
> Yeah, I tried that too. I take it this is why real programmers often scoff at
> bash "programmers". So what're bash scripts good for then? Just automation
> with a small amount of primitive conditionals?

Something like that.  It's difficult at best to do any kind of complex
processing in bash.  On the other hand, if it's simple enough to do just
with bash builtins, you have a very lightweight script.  Even calling a
few commands will tend to be less overhead than invoking perl.

Don't eschew bash programming entirely.  It may be limited, but you can
still do a lot within those limitations.  Glory in the power of pipes.
I've been known to accomplish tasks with scriplets - single line scripts
consisting of several commands strung together.

Your computer is a swiss army knife with, instead of blades, more swiss
army knives.

-- 
Caution: Product will be hot after heating


--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification"

2003-08-30 Thread Jason Stubbs
On Sunday 31 August 2003 02:31, Marshal Newrock wrote:
> On Sat, 30 Aug 2003, Jason Stubbs wrote:
> > I've found that formail is capable of doing that too. This, however, has
> > brought another problem. I've taken the grep line out of the loop and
> > read the entire message into a variable as follows:
> >
> > message=""
> > while read msg_line
> > do
> > message="${message}${msg_line}\n"
> > done
> >
> > I figured I'd then be able to use the whole message with formail as
> > Yorkshire Dave suggested (and it increases performance too). However, the
> > whitespace at the beginning of multiline headers is being truncated so
> > formail cannot interpret the mail correctly. The only references to
> > whitespace are with regard to IFS but that doesn't seem to have any
> > effect. Is there any other way to turn off this behaviour?
>
> I'm sorry to say, but I think you might have just exceeded the
> capabilities of bash.  You can play around with stuff, but it looks like
> bash likes to ditch leading spaces.  I think you need to crack open the
> perl man pages or possibly go to temp files from within procmail.
>
> Try this and see:
> $ls
> $ "   ls"
>
> I'm pretty sure that 'read' will also ditch leading spaces, and I don't
> know how to get around that.

Yeah, I tried that too. I take it this is why real programmers often scoff at 
bash "programmers". So what're bash scripts good for then? Just automation 
with a small amount of primitive conditionals?

Moving to perl won't be too hard, though. I've got all the knowledge I need 
now to do the task - thanks to all for that! - and Perl seems to be something 
of a mix of Pascal and BASIC, so it shouldn't be too hard.

Once again, thanks to all!

Regards,
Jason

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification"

2003-08-30 Thread Marshal Newrock
On Sat, 30 Aug 2003, Jason Stubbs wrote:

> I've found that formail is capable of doing that too. This, however, has
> brought another problem. I've taken the grep line out of the loop and read
> the entire message into a variable as follows:
>
> message=""
> while read msg_line
> do
> message="${message}${msg_line}\n"
> done
>
> I figured I'd then be able to use the whole message with formail as Yorkshire
> Dave suggested (and it increases performance too). However, the whitespace at
> the beginning of multiline headers is being truncated so formail cannot
> interpret the mail correctly. The only references to whitespace are with
> regard to IFS but that doesn't seem to have any effect. Is there any other
> way to turn off this behaviour?

I'm sorry to say, but I think you might have just exceeded the
capabilities of bash.  You can play around with stuff, but it looks like
bash likes to ditch leading spaces.  I think you need to crack open the
perl man pages or possibly go to temp files from within procmail.

Try this and see:
$ls
$ "   ls"

I'm pretty sure that 'read' will also ditch leading spaces, and I don't
know how to get around that.

-- 
Caution: Product will be hot after heating


--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification"

2003-08-30 Thread Jason Stubbs
On Saturday 30 August 2003 21:34, Spider wrote:
> Although all this is pretty esoteric scripting,
> and nothing I've ever done so

Hehehe, am I trying to use a swiss-army knife to build a house? ;-)

The only problem I have now is the whitespace problem that I just outlined in 
another message. If I make the move to perl, can I easily prevent whitespace 
from being truncated?

Regards,
Jason

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification"

2003-08-30 Thread Jason Stubbs
On Saturday 30 August 2003 21:01, Jason Stubbs wrote:
> BTW is there any tool I can use to extract plain text body of a message?

I've found that formail is capable of doing that too. This, however, has 
brought another problem. I've taken the grep line out of the loop and read 
the entire message into a variable as follows:

message=""
while read msg_line
do
message="${message}${msg_line}\n"
done

I figured I'd then be able to use the whole message with formail as Yorkshire 
Dave suggested (and it increases performance too). However, the whitespace at 
the beginning of multiline headers is being truncated so formail cannot 
interpret the mail correctly. The only references to whitespace are with 
regard to IFS but that doesn't seem to have any effect. Is there any other 
way to turn off this behaviour?

Regards,
Jason

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification"

2003-08-30 Thread Spider
begin  quote
On Sat, 30 Aug 2003 21:01:57 +0900
Jason Stubbs <[EMAIL PROTECTED]> wrote:



> BTW is there any tool I can use to extract plain text body of a
> message?

Well, there is an interesting snippet in the end of "man procmailex" 
that might apply here (includes mimencode to strip mime data and convert
to plain text)

This could probably be used in combination with some other filter to
remove the headers (perhaps "formail" could work) . Although all this is
pretty esoteric scripting, and nothing I've ever done so

//Spider



-- 
begin  .signature
This is a .signature virus! Please copy me into your .signature!
See Microsoft KB Article Q265230 for more information.
end


pgp0.pgp
Description: PGP signature


Re: [gentoo-user] Procmail and mail "notification"

2003-08-30 Thread Jason Stubbs
On Saturday 30 August 2003 19:48, Spider wrote:
> begin  quote
> On Sat, 30 Aug 2003 14:20:33 +0900
>
> Jason Stubbs <[EMAIL PROTECTED]> wrote:
> > On Saturday 30 August 2003 10:08, Spider wrote:
> > > try something like
> > >
> > >  :0
> > >
> > > * ^X-Spam-Status: No
> > > {
> > >
> > > :0 c
> > > :
> > > | my-bash-script
> > > |
> > > :0
> > >
> > > storage
> > > }
> >
> > This works perfectly. Thanks!
> >
> > Now to figure out the difference between that and :0c by itself...
>
> This is basically a fork.
> First you match the "No spam" tag
> Then you enter a block {
>   then you pipe a copy through the "my-bash-script"
>   and then the original goes into "storage"
> and the block ends
>
> //Spider

Your fork recommendation is very simple to understand. My understanding of:

:0 c
* ^header-condition
| filter

is that procmail generates a copy of the message and sends it through filter 
if it matches header-condition, while the original message continues being 
processed with the following rules. Obviously I'm incorrect. I can't see how 
procmail was processing the rule to get 2 copies.

BTW is there any tool I can use to extract plain text body of a message?

Regards,
Jason

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification"

2003-08-30 Thread Spider
begin  quote
On Sat, 30 Aug 2003 14:20:33 +0900
Jason Stubbs <[EMAIL PROTECTED]> wrote:

> On Saturday 30 August 2003 10:08, Spider wrote:
> > try something like
> >
> >  :0
> >
> > * ^X-Spam-Status: No
> > {
> >
> > :0 c
> > :
> > | my-bash-script
> > |
> > :0
> >
> > storage
> > }
> 
> This works perfectly. Thanks!
> 
> Now to figure out the difference between that and :0c by itself...
> 

This is basically a fork.
First you match the "No spam" tag
Then you enter a block { 
  then you pipe a copy through the "my-bash-script"
  and then the original goes into "storage"
and the block ends

//Spider


-- 
begin  .signature
This is a .signature virus! Please copy me into your .signature!
See Microsoft KB Article Q265230 for more information.
end


pgp0.pgp
Description: PGP signature


Re: [gentoo-user] Procmail and mail "notification" (SOVLED)

2003-08-30 Thread Jason Stubbs
On Saturday 30 August 2003 14:15, Yorkshire Dave wrote:
(B> On Fri, 2003-08-29 at 14:50, Jason Stubbs wrote:
(B> > Hmmm
(B> >
(B> > I've called the script notify and changed it as follows:
(B> >
(B> > #!/bin/sh
(B>
(B> This is probably a silly question but why not just script it straight
(B> into ~/.procmailrc?
(B
(BBecause I don't know procmail well enough - barely at all, actually - to be 
(Bable to do it straight out. Also, I'd like to get the first x lines of the 
(Bbody into the notification message as well. If it's a short e-mail my 
(Bgirlfriend may not have to use the computer at all! ;-)
(B
(B> Oh, and it makes sense to use formail to extract the relevant fields,
(B> that's what it's for.
(B> FROM=`formail -xFrom:`
(B> SUBJ=`formail -xSubject:`
(B> DATE=`formail -xDate:`
(B
(BHmmm. Sounds cleaner but I've only got one stdin. Wouldn't formail want to see 
(Bthe entire mail message or at least all of the headers? If so, how could I 
(Bduplicate stdin for each field?
(B
(BRegards,
(BJason
(B
(B--
(B[EMAIL PROTECTED] mailing list

Re: [gentoo-user] Procmail and mail "notification"

2003-08-30 Thread Jason Stubbs
On Saturday 30 August 2003 10:08, Spider wrote:
> try something like
>
>  :0
>
> * ^X-Spam-Status: No
> {
>
> :0 c
> :
> | my-bash-script
> |
> :0
>
> storage
> }

This works perfectly. Thanks!

Now to figure out the difference between that and :0c by itself...

Regards,
Jason

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification" (SOVLED)

2003-08-30 Thread Yorkshire Dave
On Fri, 2003-08-29 at 14:50, Jason Stubbs wrote:
> Hmmm
> 
> I've called the script notify and changed it as follows:
> 
> #!/bin/sh
> 
This is probably a silly question but why not just script it straight
into ~/.procmailrc? 

Oh, and it makes sense to use formail to extract the relevant fields,
that's what it's for.
FROM=`formail -xFrom:`
SUBJ=`formail -xSubject:`
DATE=`formail -xDate:`

-- 
Yorkshire Dave
Custom rule generator for SpamAssassin.
http://www.wot.no-ip.com/cgi-bin/detoken.pl
top-posters will be tarred and feathered!


-- 
Scanned by MailScanner at wot.no-ip.com


--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification" (SOVLED)

2003-08-30 Thread Marshal Newrock
On Sat, 30 Aug 2003, Jason Stubbs wrote:

> The grep line is fairly easy to understand. I've got to learn regular
> expressions, though. They seem too useful!

That's what I meant.  'man 7 regex' and 'man pcre' for regular regular
expressions and perl compatible regular expressions, respectively.  In
fact, 'apropos pcre' reveals 'pcregrep' which I had not previously known
about.  Also 'man perlre' for using regular expressions in a perl script.
But regardless of what tool you use (grep, sed, perl, etc), learning
regular expressions is definately something you want to do.  But also
learn perl or another scripting language of your choice.  Bash is good for
simple tasks, but sooner or later you'll hit some limitations.

-- 
Caution: Product will be hot after heating


--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification"

2003-08-30 Thread Spider
begin  quote
On Sat, 30 Aug 2003 09:54:19 +0900
Jason Stubbs <[EMAIL PROTECTED]> wrote:

> On Saturday 30 August 2003 00:07, Christopher Fisk wrote:
> > I've answered this on the forums at
> > http://forums.gentoo.org/viewtopic.php?t=23703&postdays=0&postorder=asc&sta
> >rt=6
> >
> > The perl script would be edited to have the proper phone number, but
> > that should do what you are looking for.
> 
> Thanks for the link. I read it, well at least up until it went into
> "what is procmail?", but I will go with the bash script. Have the
> reason I'm trying to set this up is for the learning and I haven't
> even started with Perl yet. That is to say, I can read Perl and
> understand it but have never written anything and so the learning
> curve is too much for a relatively simple project such as this.
> 
> I did get some useful information, though. That being using procmail's
> 'c' flag to create a copy of the message, rather than having to ensure
> that the output matches the input with 'f'. Thanks for that too!
> 
> 
> To all:
> 
> Last problem is that it I'm getting 2 mail notifications for each
> message. My results are as follows:


try something like
 :0
* ^X-Spam-Status: No
{
:0 c
| my-bash-script

:0
storage
}




> 0:c   original message delivered and 2 notifications
> 0;f   original message not deleviered and 1 notification
> 
> I tried duplicating the input onto the output using echo with 0:f but
> still did not get the original message. Any pointers?
> 
> Thanks for everybody's help.
> 
> Regards,
> Jason
> 
> --
> [EMAIL PROTECTED] mailing list
> 


-- 
begin  .signature
This is a .signature virus! Please copy me into your .signature!
See Microsoft KB Article Q265230 for more information.
end


pgp0.pgp
Description: PGP signature


Re: [gentoo-user] Procmail and mail "notification"

2003-08-30 Thread Jason Stubbs
On Saturday 30 August 2003 00:07, Christopher Fisk wrote:
> I've answered this on the forums at
> http://forums.gentoo.org/viewtopic.php?t=23703&postdays=0&postorder=asc&sta
>rt=6
>
> The perl script would be edited to have the proper phone number, but that
> should do what you are looking for.

Thanks for the link. I read it, well at least up until it went into "what is 
procmail?", but I will go with the bash script. Have the reason I'm trying to 
set this up is for the learning and I haven't even started with Perl yet. 
That is to say, I can read Perl and understand it but have never written 
anything and so the learning curve is too much for a relatively simple 
project such as this.

I did get some useful information, though. That being using procmail's 'c' 
flag to create a copy of the message, rather than having to ensure that the 
output matches the input with 'f'. Thanks for that too!


To all:

Last problem is that it I'm getting 2 mail notifications for each message. My 
results are as follows:

0:c   original message delivered and 2 notifications
0;f   original message not deleviered and 1 notification

I tried duplicating the input onto the output using echo with 0:f but still 
did not get the original message. Any pointers?

Thanks for everybody's help.

Regards,
Jason

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification" (SOVLED)

2003-08-30 Thread Jason Stubbs
On Saturday 30 August 2003 03:02, Marshal Newrock wrote:
> It's been a little while since I've done something like this, but I think
> I've got it.  'cat /dev/stdin' is the wrong way to read input to a
> command.  Also, I'd just save everything in a variable, and avoid disk
> access.  And make sure you're only sending the header.  I believe there's
> an 'h' flag for procmail to do this.  Scanning every line of a 5MB email
> will be a bit of a performance loss.
>
> #!/bin/bash
> notify_msg=""
> while read header_line
> do
> if `echo $header_line | egrep -q '^(From|Date|Subject)'`
> then
> notify_msg="${notify_msg}${header_line}\n"
> fi
> done
> echo -e $notify_msg | mail -s "Mail Notification" $1
>

This script is beautiful! Is helping me on my way to becoming more than a 
mediocre bash 'programmer'. Thanks very much.

> If you don't understand the grep line, read the entire grep man page top
> to bottom.  It will be one of the more useful things you do.

The grep line is fairly easy to understand. I've got to learn regular 
expressions, though. They seem too useful!

Regards,
Jason

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification" (not SOLVED)

2003-08-30 Thread Jason Stubbs
On Saturday 30 August 2003 06:37, Spider wrote:
> begin  quote
> On Fri, 29 Aug 2003 23:25:03 +0900
>
> Jason Stubbs <[EMAIL PROTECTED]> wrote:
> > On Friday 29 August 2003 22:50, Jason Stubbs wrote:
> > > However, *any* mail that goes through it comes out blank! Whether it
> > > is spam or not! The script works fine from the shell so it's got to
> > > be something wrong with how I'm using procmail. I can't see where
> > > the error is though. I checked the $TMP files and both come out
> > > blank, so it seems that procmail is not piping the mail through the
> > > filter. Either way, it doesn't explain why spam is being corrupted
> > > as well. Can anyone help? Pretty please??
> >
> > To add some further information, I've found the following in
> > /var/log/mail/current:
> >
> > Aug 29 23:20:30 [procmail] Suspicious rcfile "/home/jason/.procmailrc"
> >
> >
> > My /etc/procmailrc, btw, is as follows:
> >
> > DEFAULT=/var/spool/mail/$LOGNAME
> >
> > :0fw
> >
> > * < 256000
> >
> > | /usr/bin/spamc -f
> >
> > INCLUDERC=$HOME/.procmailrc
> >
> >
> > Byte for byte matching Spider's recommendations.
>
> oh wait, I think I have it..
> I Read The Fine Manual:
>
> Suspicious rcfile "x"
>
> The owner of the rcfile was not the recipient or
> root, the file was world writable, or the direc-
> tory that contained it was  world  writable,  or
> this  was the default rcfile ($HOME/.procmailrc)
> and either it was group writable or the directo-
> ry that contained it was group writable (the
> rc-file was not used).

The file was group writable. Thanks! I wasn't looking at the procmail man page 
at all - only procmailrc and procmailex.

Jason

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification" (not SOLVED)

2003-08-29 Thread Spider
begin  quote
On Fri, 29 Aug 2003 23:25:03 +0900
Jason Stubbs <[EMAIL PROTECTED]> wrote:

> On Friday 29 August 2003 22:50, Jason Stubbs wrote:
> > However, *any* mail that goes through it comes out blank! Whether it
> > is spam or not! The script works fine from the shell so it's got to
> > be something wrong with how I'm using procmail. I can't see where
> > the error is though. I checked the $TMP files and both come out
> > blank, so it seems that procmail is not piping the mail through the
> > filter. Either way, it doesn't explain why spam is being corrupted
> > as well. Can anyone help? Pretty please??
> 
> To add some further information, I've found the following in 
> /var/log/mail/current:
> 
> Aug 29 23:20:30 [procmail] Suspicious rcfile "/home/jason/.procmailrc"
> 
> 
> My /etc/procmailrc, btw, is as follows:
> 
> DEFAULT=/var/spool/mail/$LOGNAME
> 
> :0fw
> * < 256000
> | /usr/bin/spamc -f
> 
> INCLUDERC=$HOME/.procmailrc
> 
> 
> Byte for byte matching Spider's recommendations.
> 

oh wait, I think I have it..
I Read The Fine Manual:

Suspicious rcfile "x" 

The owner of the rcfile was not the recipient or   
root, the file was world writable, or the direc-
tory that contained it was  world  writable,  or 
this  was the default rcfile ($HOME/.procmailrc)
and either it was group writable or the directo-   
ry that contained it was group writable (the
rc-file was not used).


//Spider


-- 
begin  .signature
This is a .signature virus! Please copy me into your .signature!
See Microsoft KB Article Q265230 for more information.
end


pgp0.pgp
Description: PGP signature


Re: [gentoo-user] Procmail and mail "notification" (not SOLVED)

2003-08-29 Thread Spider
begin  quote
On Fri, 29 Aug 2003 23:25:03 +0900
Jason Stubbs <[EMAIL PROTECTED]> wrote:

> To add some further information, I've found the following in 
> /var/log/mail/current:
> 
> Aug 29 23:20:30 [procmail] Suspicious rcfile "/home/jason/.procmailrc"
> 
> 
> My /etc/procmailrc, btw, is as follows:
> 
> DEFAULT=/var/spool/mail/$LOGNAME
> 
> :0fw
> * < 256000
> | /usr/bin/spamc -f
> 
> INCLUDERC=$HOME/.procmailrc
> 
> 
> Byte for byte matching Spider's recommendations.

interesting.
Could you add VERBOSE="yes" to the procmailrc and see that we can have
some information as to what is suspect?


-- 
begin  .signature
This is a .signature virus! Please copy me into your .signature!
See Microsoft KB Article Q265230 for more information.
end


pgp0.pgp
Description: PGP signature


Re: [gentoo-user] Procmail and mail "notification" (SOVLED)

2003-08-29 Thread Marshal Newrock
On Fri, 29 Aug 2003, Jason Stubbs wrote:

> #!/bin/sh
>
> TMP1=`mktemp /tmp/mailcheck.XX`
> TMP2=`mktemp /tmp/mailcheck.XX`
>
> cat /dev/stdin > $TMP1
> grep Date: $TMP1 | head -n 1 > $TMP2
> grep From: $TMP1 | head -n 1 >> $TMP2
> grep Subject: $TMP1 | head -n 1 >> $TMP2
> cat $TMP2 | mail -s "Mail Notification" $1
> cat $TMP1
>
> rm $TMP1
> rm $TMP2
>
>
> In ~/.procmailrc, I have put:
>
> :0fw
> * ^X-Spam-Status: No*
> | /usr/local/bin/notify jason
>
>
> However, *any* mail that goes through it comes out blank! Whether it is spam
> or not! The script works fine from the shell so it's got to be something
> wrong with how I'm using procmail. I can't see where the error is though. I
> checked the $TMP files and both come out blank, so it seems that procmail is
> not piping the mail through the filter. Either way, it doesn't explain why
> spam is being corrupted as well. Can anyone help? Pretty please??

It's been a little while since I've done something like this, but I think
I've got it.  'cat /dev/stdin' is the wrong way to read input to a
command.  Also, I'd just save everything in a variable, and avoid disk
access.  And make sure you're only sending the header.  I believe there's
an 'h' flag for procmail to do this.  Scanning every line of a 5MB email
will be a bit of a performance loss.

#!/bin/bash
notify_msg=""
while read header_line
do
if `echo $header_line | egrep -q '^(From|Date|Subject)'`
then
notify_msg="${notify_msg}${header_line}\n"
fi
done
echo -e $notify_msg | mail -s "Mail Notification" $1


If you don't understand the grep line, read the entire grep man page top
to bottom.  It will be one of the more useful things you do.

Hope this helps.

-- 
Caution: Product will be hot after heating


--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification"

2003-08-29 Thread Christopher Fisk
On Fri, 29 Aug 2003, Jason Stubbs wrote:

>My guess is that it is not directly possible with procmail. I'm guessing that 
>I'd have to use some sort of script to pipe each e-mail message through. Any 
>suggestions on how I could write such a script?

I've answered this on the forums at 
http://forums.gentoo.org/viewtopic.php?t=23703&postdays=0&postorder=asc&start=6

The perl script would be edited to have the proper phone number, but that 
should do what you are looking for.



Christopher Fisk
--
BOFH Excuse #106:
The electrician didn't know what the yellow cable was so he yanked the 
ethernet out.

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification" (not SOLVED)

2003-08-29 Thread Jason Stubbs
On Friday 29 August 2003 22:50, Jason Stubbs wrote:
> However, *any* mail that goes through it comes out blank! Whether it is
> spam or not! The script works fine from the shell so it's got to be
> something wrong with how I'm using procmail. I can't see where the error is
> though. I checked the $TMP files and both come out blank, so it seems that
> procmail is not piping the mail through the filter. Either way, it doesn't
> explain why spam is being corrupted as well. Can anyone help? Pretty
> please??

To add some further information, I've found the following in 
/var/log/mail/current:

Aug 29 23:20:30 [procmail] Suspicious rcfile "/home/jason/.procmailrc"


My /etc/procmailrc, btw, is as follows:

DEFAULT=/var/spool/mail/$LOGNAME

:0fw
* < 256000
| /usr/bin/spamc -f

INCLUDERC=$HOME/.procmailrc


Byte for byte matching Spider's recommendations.

Regards,
Jason

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification" (SOVLED)

2003-08-29 Thread Jason Stubbs
Hmmm

I've called the script notify and changed it as follows:

#!/bin/sh

TMP1=`mktemp /tmp/mailcheck.XX`
TMP2=`mktemp /tmp/mailcheck.XX`

cat /dev/stdin > $TMP1
grep Date: $TMP1 | head -n 1 > $TMP2
grep From: $TMP1 | head -n 1 >> $TMP2
grep Subject: $TMP1 | head -n 1 >> $TMP2
cat $TMP2 | mail -s "Mail Notification" $1
cat $TMP1

rm $TMP1
rm $TMP2


In ~/.procmailrc, I have put:

:0fw
* ^X-Spam-Status: No*
| /usr/local/bin/notify jason


However, *any* mail that goes through it comes out blank! Whether it is spam 
or not! The script works fine from the shell so it's got to be something 
wrong with how I'm using procmail. I can't see where the error is though. I 
checked the $TMP files and both come out blank, so it seems that procmail is 
not piping the mail through the filter. Either way, it doesn't explain why 
spam is being corrupted as well. Can anyone help? Pretty please??

Thanks in advance,
Jason

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification" (SOVLED)

2003-08-29 Thread Jason Stubbs
Okay! Done it. Here's the script if anyone else is interested:

#!/bin/sh

MAILADDR="[EMAIL PROTECTED]"
TMP1=`mktemp /tmp/mailcheck.XX`
TMP2=`mktemp /tmp/mailcheck.XX`

cat /dev/stdin > $TMP1
grep Date: $TMP1 | head -n 1 > $TMP2
grep From: $TMP1 | head -n 1 >> $TMP2
grep Subject: $TMP1 | head -n 1 >> $TMP2
cat $TMP2 | mail -s "Mail Notification" $MAILADDR
cat $TMP1

rm $TMP1
rm $TMP2


Piping the appropriate mail through it with procmail should do what I want. 
Now to test it in the real world...

Jason

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification" (Half-SOVLED)

2003-08-29 Thread Jason Stubbs
On Friday 29 August 2003 21:13, Marshal Newrock wrote:
> On Fri, 29 Aug 2003, Jason Stubbs wrote:
> > Me and my girlfriend have one computer - a laptop. I want to use it 24/7,
> > she wants to use it just to check mail every so often. So, what I want to
> > do is have procmail send details of any new messages that aren't spam to
> > my girlfriend's mobile. That is, not the whole message, only the
> > date/time, sender and subject - maybe a couple of lines like
> > Spam-Assassin does for spam-mail as well.
> >
> > My guess is that it is not directly possible with procmail. I'm guessing
> > that I'd have to use some sort of script to pipe each e-mail message
> > through. Any suggestions on how I could write such a script?
>
> I don't have procmail on this computer, but I think I can give a rough
> idea of what to do.  First, read the procmail man page about the flags.
> You'll want to clone the message and process only the header.  If it's to
> your girlfriend and not spam (with negative regexp for spamassassin header
> line), then filter it.  The following script should work, though you
> should doublecheck, as I haven't dealt much with multiline strings and
> I've never sent mail from a perl script before.

Hmmm, I don't understand your script at all! But that's only because I don't 
know Perl. :-( That's alright though, coz I've got something that works. His 
a little bash script that does what I want:

#!/bin/sh
cat /dev/stdin > tmp1
grep Date: tmp1 > tmp2
grep From: tmp1 >> tmp2
grep Subject: tmp1 >> tmp2
cat tmp2 | mail -s "Mail Notification" [EMAIL PROTECTED]
cat tmp1

The only problem with it is if two messages are being processed at the same 
time. And to put in the correct mail address... Anybody know how I can create 
a unique temp file from bash?

Regards,
Jason

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail and mail "notification"

2003-08-29 Thread Marshal Newrock
On Fri, 29 Aug 2003, Jason Stubbs wrote:

> Me and my girlfriend have one computer - a laptop. I want to use it 24/7, she
> wants to use it just to check mail every so often. So, what I want to do is
> have procmail send details of any new messages that aren't spam to my
> girlfriend's mobile. That is, not the whole message, only the date/time,
> sender and subject - maybe a couple of lines like Spam-Assassin does for
> spam-mail as well.
>
> My guess is that it is not directly possible with procmail. I'm guessing that
> I'd have to use some sort of script to pipe each e-mail message through. Any
> suggestions on how I could write such a script?

I don't have procmail on this computer, but I think I can give a rough
idea of what to do.  First, read the procmail man page about the flags.
You'll want to clone the message and process only the header.  If it's to
your girlfriend and not spam (with negative regexp for spamassassin header
line), then filter it.  The following script should work, though you
should doublecheck, as I haven't dealt much with multiline strings and
I've never sent mail from a perl script before.

#!/usr/bin/perl
$myemail = "";
$notify_subject = "New mail!";
$header = /^(From|Date|Subject)/;
open MAIL,"|mail -s $notify_subject $myemail";
print MAIL $header;
close MAIL;

Adapt to your own desires and needs.  :)

-- 
Caution: Product will be hot after heating


--
[EMAIL PROTECTED] mailing list



[gentoo-user] Procmail and mail "notification"

2003-08-29 Thread Jason Stubbs
Hello all,

I'm not too familiar with procmail, so I don't know if what I want to do is 
possible. I've only just started using it and thanks to Spider's guide have 
Spam-Assassin working with it correctly. Here's the current situation:

Me and my girlfriend have one computer - a laptop. I want to use it 24/7, she 
wants to use it just to check mail every so often. So, what I want to do is 
have procmail send details of any new messages that aren't spam to my 
girlfriend's mobile. That is, not the whole message, only the date/time, 
sender and subject - maybe a couple of lines like Spam-Assassin does for 
spam-mail as well.

My guess is that it is not directly possible with procmail. I'm guessing that 
I'd have to use some sort of script to pipe each e-mail message through. Any 
suggestions on how I could write such a script?

Thanks in advance,
Jason

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] procmail logfile

2003-08-25 Thread Patrick Marquetecken
On Mon, 25 Aug 2003 08:42:32 +0200
Sebastian Bergmann <[EMAIL PROTECTED]> wrote:

>   Hi,
> 
>   I'm just getting started with sendmail, fetchmal, procmail etc. and want
>   procmail to maintain a logfile of its actions.
> 
>   According to the procmail documentation the following lines at the top
>   of my /etc/procmailrc should suffice to do so:
> 
> LOGFILE=/var/log/procmail
> LOGABSTRACT = "all"
> VERBOSE = "on"
> 
>   Although mails are fetched by fetchmail and processed by procmail the
>   /var/log/procmail logfile is not created.

i have i my users home dir .promailrc
LOGFILE=/var/log/procmail.log
and this works.
do you work with a global procmailrc or a local for each user.
you could try to create it your self.



> 
>   Any hints appreciated,
> Sebastian


-- 
  "If we don't get more power to the warp drive we're all going to have to get out and 
push!" -- Paris (Parallax)

 PGP Key: http://users.pandora.be/rivendell/marquetp.gpg
 Fingerprint = 2792 057F C445 9486 F932 3AEA D3A3 1B0C 1059 273B
 ICQ# 316932703 
 Registered Linux User #44550
 http://counter.li.org


pgp0.pgp
Description: PGP signature


[gentoo-user] procmail logfile

2003-08-25 Thread Sebastian Bergmann
  Hi,

  I'm just getting started with sendmail, fetchmal, procmail etc. and want
  procmail to maintain a logfile of its actions.

  According to the procmail documentation the following lines at the top
  of my /etc/procmailrc should suffice to do so:

LOGFILE=/var/log/procmail
LOGABSTRACT = "all"
VERBOSE = "on"

  Although mails are fetched by fetchmail and processed by procmail the
  /var/log/procmail logfile is not created.

  Any hints appreciated,
Sebastian

-- 
Sebastian Bergmann
http://sebastian-bergmann.de/   http://phpOpenTracker.de/

Das Buch zu PHP 5: http://professionelle-softwareentwicklung-mit-php5.de/


--
[EMAIL PROTECTED] mailing list



[gentoo-user] Procmail files being skipped?

2003-08-14 Thread Angel Gabriel
I have a feeleing that my ~/.procmailrc files are being skipped, it
seems that email being delivered via fetchmail, is not following the
rules in these files. Is there anyway, to force fetchmail to send all
mail it collects to procmail?

I use postfix as my MTA




--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail files being skipped?

2003-08-14 Thread Spider
begin  quote
On 11 Aug 2003 17:38:31 +0100
Angel Gabriel <[EMAIL PROTECTED]> wrote:

> I have a feeleing that my ~/.procmailrc files are being skipped, it
> seems that email being delivered via fetchmail, is not following the
> rules in these files. Is there anyway, to force fetchmail to send all
> mail it collects to procmail?
> 
> I use postfix as my MTA


from  /.fetchmailrc :
set postmaster "spider"
set bouncemail
set no spambounce
set properties ""
set daemon 240
poll XXX with proto XXX
   user '' there with password 'X' is 'spider' here
options str ipcr
 mda 'procmail .procmailrc'



The important part is the "mda "  section.

//Spider


-- 
begin  .signature
This is a .signature virus! Please copy me into your .signature!
See Microsoft KB Article Q265230 for more information.
end


pgp0.pgp
Description: PGP signature


Re: [gentoo-user] Procmail files being skipped?

2003-08-14 Thread Anthony Floyd
On Mon, 11 Aug 2003 17:38:31 +0100
Angel Gabriel <[EMAIL PROTECTED]> wrote:

> I have a feeleing that my ~/.procmailrc files are being skipped, it
> seems that email being delivered via fetchmail, is not following the
> rules in these files. Is there anyway, to force fetchmail to send all
> mail it collects to procmail?

Send your fetched mail directly to procmail:

/usr/bin/fetchmail -a -m "/usr/bin/procmail -d %T"

either set this in your crontab or alias it appropriately

Cheers,
Anthony

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail files being skipped?

2003-08-12 Thread Andrusky
On Aug 11, 2003 [17:38] +0100, Angel Gabriel <[EMAIL PROTECTED]> wrote:
> I have a feeleing that my ~/.procmailrc files are being skipped, it
> seems that email being delivered via fetchmail, is not following the
> rules in these files. Is there anyway, to force fetchmail to send all
> mail it collects to procmail?
> 
> I use postfix as my MTA
> 
> 
> 
> 
> --
> [EMAIL PROTECTED] mailing list
> 

Could just add a ".forward" file to your home directory (just make sure that it is 
executable).
This is what mine looks like:

IFS=' ' && p=/usr/bin/procmail && test -f $p && exec $p -Yf- || exit 75"

-- 
Cheers,

John-Paul Andrusky
 <[EMAIL PROTECTED]>
 GnuPG Key ID: B6959A50


pgp0.pgp
Description: PGP signature


Re: [gentoo-user] procmail and nested folders

2003-08-02 Thread Christophe Boutter
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

hello,

>AFAIK the dots are if you use IMAP so my gentoo-user directory is :
>
>:0
>* ^List-Id:.*gentoo-user\.gentoo\.org
>.computing.linux.gentoo.user/
>
>which is my ~/Mail/computing/linux/getnoo/user IMAP folder.

that isn#t quite right, the dots come from the mailbox format you use, in this case it 
is maildir, on the box where procmail is invoked.
yours chris

- -- 
A lie goes around the world before the truth has got it's boots on.
- -- The Truth from Terry Pratchett

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.2.2 (GNU/Linux)

iD8DBQE/K4f8Vwu+VfalHfwRAiX8AJ0WCV631Nx50gpJuWE5DKM6cKYbvwCfdIIV
Z7JmUrm6U2nkqDfSyFnbomI=
=ZdTp
-END PGP SIGNATURE-

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] procmail and nested folders

2003-08-02 Thread Tom Knight-Markiegi
On Fri, Aug 01, 2003 at 06:26:52PM -0400, rh wrote:
Hi

> Would someone post a sample rule from their procmailrc to show me how they
> have procmail sorting their mail into various folders. I have the
> following rule in my procmailrc, which is what I read should work, and
> instead of getting emails in $MAILDIR/lists/gentoo-user, I get them in
> $MAILDIR/.lists.gentoo-user which I guess wouldn't be so bad if Mutt could
> 'see' hidden directories. Maybe someone can let me know if Mutt can indeed
> see hidden directories.

AFAIK the dots are if you use IMAP so my gentoo-user directory is :

:0
* ^List-Id:.*gentoo-user\.gentoo\.org
.computing.linux.gentoo.user/

which is my ~/Mail/computing/linux/getnoo/user IMAP folder.

Tom

> 
> Thanks. R.
> 
> :0
> * ^List-Id:.*gentoo-user\.gentoo\.org
> .lists.gentoo-user
> 

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] procmail and nested folders

2003-08-01 Thread Yannick Le Saint
On Friday 01 August 2003 22:26, rh wrote:
> Would someone post a sample rule from their procmailrc to show me how they
> have procmail sorting their mail into various folders. I have the following
> rule in my procmailrc, which is what I read should work, and instead of
> getting emails in $MAILDIR/lists/gentoo-user, I get them in
> $MAILDIR/.lists.gentoo-user which I guess wouldn't be so bad if Mutt could
> 'see' hidden directories. Maybe someone can let me know if Mutt can indeed
> see hidden directories.
>
> Thanks. R.
>
> :0
>
> * ^List-Id:.*gentoo-user\.gentoo\.org
> .lists.gentoo-user

  Should be :

:0
* ^List-Id:.*gentoo-user\.gentoo\.org
lists/gentoo-user


-- 
I use technology in order to hate it more properly.
-- Nam June Paik


--
[EMAIL PROTECTED] mailing list



[gentoo-user] procmail and nested folders

2003-08-01 Thread rh



Would someone post a sample rule from their 
procmailrc to show me how they have procmail sorting their mail into various 
folders. I have the following rule in my procmailrc, which is what I read should 
work, and instead of getting emails in $MAILDIR/lists/gentoo-user, I get them in 
$MAILDIR/.lists.gentoo-user which I guess wouldn't be so bad if Mutt could 'see' 
hidden directories. Maybe someone can let me know if Mutt can indeed see hidden 
directories.
 
Thanks. R.
 
:0
* ^List-Id:.*gentoo-user\.gentoo\.org
.lists.gentoo-user
 
 


Re: [gentoo-user] Procmail for several users

2003-07-24 Thread Christopher Fisk
On Thu, 24 Jul 2003, Patrick Marquetecken wrote:

>Now my problem is how to distribute all that mail to the mailboxes of 
>those users. I can use procmail and filter for TO: and drop the mail in 
>his Maildir, and then let sylpheed do the filtering for the subfolders.
>I think that qmail will be to heavy for my system. 

fetchmail will deliver the messages to the right users.

set postmaster "root"
set bouncemail
set properties ""
set daemon 300
poll mail.domain1.net with proto POP3
   user "janedoe" there with password "password" is janedoe here options fetchall 
keep warnings 3600
   user "freddoe" there with password "password" is someoneelse here options 
fetchall keep warnings 3600
   user "johndoe" there with password "password" is johndoe here options fetchall 
warnings 3600
poll mail.domain2.net with proto POP3
   user "johndoe" there with password "password" is johndoe here options fetchall 
warnings 3600



Hope that helps,


Christopher Fisk
--
TAR IS NOT A PLAYTHING
TAR IS NOT A PLAYTHING
Bart Simpson on chalkboard in episode 7F02

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail for several users

2003-07-24 Thread Stroller
On 24/7/03 7:52 pm, "Patrick Marquetecken" <[EMAIL PROTECTED]>
wrote:
>
> I'm installing a small server (88mb ram can't be upgraded) that will gather
> mail for 10 persons
> The have mail adresses at "normal" isp's and hotmail.
> For hotmail i'm using gotmail.
> And using fetchmail for gathering the mails from the isp's.

I don't know about procmail - I like maildrop.
The following works for me:

  $ head -40 .fetchmailrc
  defaults
 timeout 60
 protocol pop3

  # Test porpoises only
  #keep
  #fetchall

  mda "/usr/bin/maildrop -d $USER"

  poll pop.myisp.com
user "joe.stroller" there with password wibble,
is "stroller" here;
  $

HTH,

Stroller.

-- 
Enjoyed this post? Thanks for reading - please consider employing me!
Technical support / system administration - CV available on request
Linux / Unix / Windows / Mac OS X  - UK or anywhere considered



--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail for several users

2003-07-24 Thread Florian Huber
Hello Patrick,

On Thu, 24 Jul 2003 20:52:39 +0200
Patrick Marquetecken <[EMAIL PROTECTED]> wrote:

> Now my problem is how to distribute all that mail to the mailboxes
> of those users. I can use procmail and filter for TO: and drop the
> mail in his Maildir, and then let sylpheed do the filtering for the
> subfolders.

Give "getmail" a try. I does not need any other programm for the
maildelivery and you can deliver different remote mailboxes
(pop,imap,...) to different local mailboxes (mbox or maildir).

HTH
Florian Huber

--
[EMAIL PROTECTED] mailing list



[gentoo-user] Procmail for several users

2003-07-24 Thread Patrick Marquetecken
Hi,

I'm installing a small server (88mb ram can't be upgraded) that will gather mail for 
10 persons. It will be for Gentoo & Windows users. The mail client will be Sylpheed 
for both clients.
The have mail adresses at "normal" isp's and hotmail. 
For hotmail i'm using gotmail.
And using fetchmail for gathering the mails from the isp's.

Now my problem is how to distribute all that mail to the mailboxes of those users. I 
can use procmail and filter for TO: and drop the mail in his Maildir, and then let 
sylpheed do the filtering for the subfolders.
I think that qmail will be to heavy for my system. 

Like always all your idee's are more than welcom.

Patrick

-- 
  "If we don't get more power to the warp drive we're all going to have to get out and 
push!" -- Paris (Parallax)

 PGP Key: http://users.pandora.be/rivendell/marquetp.gpg
 Fingerprint = 2792 057F C445 9486 F932 3AEA D3A3 1B0C 1059 273B
 ICQ# 316932703 
 Registered Linux User #44550
 http://counter.li.org


pgp0.pgp
Description: PGP signature


Re: [gentoo-user] procmail log errors

2003-07-09 Thread Ron Cooper
[Warning... somewhat lenghty discussion follows]

Quoting Dhruba Bandopadhyay <[EMAIL PROTECTED]>:

> Hello,
>
> I have attached a procmail log which complains about errors of not
> being  able to write to folders and acquiring kernel locks.  Any help
>on  solving  these problems would be much appreciated.
>
> With regards.
>

Me thinks your procmail problem is probably a misconfigured .procmailrc
more than a procmail problem.  Try something like this. Change where
necessary to match your setup.

Note that on MAILDIR type setups, locks in the recipies are not
necessary.  You are creating unique files in a directory, the who
purpose of Maildir to begin with.  Locks are for files, not directories
in this case. Exception is spamassassin which needs locks.

>From your log file:

Procmail: Match on "^FROM:.*codewordt\.co\.uk"
procmail: Assigning "LASTFOLDER=.maildir/.flat"
^^
procmail: Opening ".maildir/.flat"
^^
procmail: Error while writing to ".maildir/.flat"
  ^
Assigning "LASTFOLDER=/home/gentoo/.maildir/msg.AkD"
   
Whats this? All your messages are going into a message file.
Your paths to your maildir folders are wrong.  First of all, forget
about using locks in Maildir folders. Locks serve no purpose there.
Indeed thats one of the reasons that Maildir folders exist.
Now,  First some common mistakes in procmail, while, they work, are not
really 100% correct:

# Dont use locks on Maildir folders as such...
:0:
* ^Subject:.*text
# Assumes my MUA puts a ':' in the Subject line.  What if it doesnt?

HINT:  use * ^Subject.*text   _NOT_  ^Subject:.   Ok?


# Escaping the '.' to detect a '.'
* ^List-Id.*cvs\.lists\.horde\.org
# ^List-Id headers dont need escaping the regex '.', it's redundant
# it complicates things, and it makes it harder to read.

# Ahh much better, and easier to read too :)
* ^List-Id.*cvs.lists.horde.org

I assume your MTA is properly configured to let procmail deliver the
mail.

Hint:  for postfix,
mailbox_command = /usr/bin/procmail -a "$EXTENSION"


Note:  in procmailrc *ALWAYS* give the file a shell.  Always
give it a path to any programs it may need.

Note 2:  I use Courier-imap.  Support about 1000 usrs.  And well your
procmail recipes are not working because you do not understand how
Maildirs are structured, and secondly you do not understand how Courier
sets up its folders in the maildir directory structure. Understanding
this is a necessary prerequsite to getting procmail to work.

I've included a short sample from one of my hundreds of .procmailrc
scripts.  It should contain enough info to help you get started, unless
you are just completely and utterly lost, in which case, you should
probably pay someone to set this up for you.

I go though great pains to define _all_ my IMAP folders at the start of
the script.  After trying to debug a procmail.log file with hundred of
thousands of entries, supporting hundreds of users, the extra
readability given to the script itself is well worth the effort.
Last, I've included a sample from my procmail.log to show how
procmail expands the directory names.

Hopefully this will be helpful to others as well.  I do not claim to be
an expert, this is stuff I have learned on my own and it's nothing
special trust me.

Feel free to ask questions, but be aware I will not do your project for
you.


SHELL=/bin/sh
PATH=$HOME/bin:/bin:/usr/bin:/usr/local/bin:/opt/f-prot/:/usr/local/anomy
UMASK=022
MAILDIR=${HOME}/.maildir
DEFAULT=${MAILDIR}/
USER=${LOGNAME}
DROPPRIVS=yes
#DEBUG_VERBOSE=YES
#VERBOSE=YES
#LOGFILE=${HOME}/procmail.log
LOGFILE=
#
#Go through the pain of setting up all the paths to IMAP folders first
#to make it simplier when we setup the recipe.
#
#Note I setup IMAP folders with a folder hierarchy, that is
#An empty folder (i.e. HORDEBASE) and then the actual folders
#that live under the BASEDIR where the actual mail goes.
#
# Horde, imp,Turba, CVS lists
HORDEBASE=${MAILDIR}/.Horde
HORDECVS=${HORDEBASE}.CVS/
HORDEIMP=${HORDEBASE}.IMP/
HORDETURBA=${HORDEBASE}.TURBA/
HORDE=${HORDEBASE}.HORDE/
#
#
# Gentoo lists
GENTOOBASE=${MAILDIR}/.Gentoo
GENTOODEV=${GENTOOBASE}.Dev/
GENTOOCVS=${GENTOOBASE}.CVS/
GENTOODESK=${GENTOOBASE}.Desktop/
GENTOOUSER=${GENTOOBASE}.User/

# Spam Assassin  Directories
SPAMBASE=${MAILDIR}/.SPAM
SPAMDIR=${SPAMBASE}/
MAYBESPAM=${SPAMBASE}/.MaybeSpam/
#
STUFF FROM CRON DAEMONS OR FROM DSLOADIT ##
:0
* ^From.*Cron
${CRONMISC}

## HORDE LISTS ###
:0
* ^List-Id.*cvs.lists.horde.org
${HORDECVS}
#
:0
* ^List-Id.*imp.lists.horde.org
${HORDEIMP}
#
:0
* ^List-Id.*turba.lists.horde.org
${HORDETURBA}
#
:0
* ^List-Id.*horde.lists.horde.org
${HORDE}
## MOVE ALL GENTOO MAIL TO THE GENTOO FOLDERS #
:0
* ^List-Id.*gentoo-cvs.gentoo.org
${GENTOOCVS}
#
:0
* ^List-Id.*gentoo-desktop.gentoo.org
${GENTOODESK}
#
:0
* ^List-Id.*

[gentoo-user] procmail log errors

2003-07-08 Thread Dhruba Bandopadhyay
Hello,

I have attached a procmail log which complains about errors of not being
able to write to folders and acquiring kernel locks.  Any help on solving
these problems would be much appreciated.

With regards.


.procmail.log
Description: Binary data
--
[EMAIL PROTECTED] mailing list

Re: [gentoo-user] procmail question/problem

2003-06-27 Thread Christopher Fisk
On Fri, 27 Jun 2003, Alexander Puchmayr wrote:

>Hi folks!
>
>I've a small procmail trouble. 
>When I have a .procmailrc in users's home dir, its working fine. But when I 
>move that file to /etc/procmailrc, then it gets ignored.

You can force it in one of multiple ways.  You can add a symlink to the 
/etc/procmailrc file in thier home directory, or you can add an actual 
.procmailrc file and use and include line

INCLUDERC=/etc/procmailrc


Hope that helps,

Christopher Fisk
--
BOFH Excuse #245:
The Borg tried to assimilate your system. Resistance was futile.

--
[EMAIL PROTECTED] mailing list



[gentoo-user] procmail question/problem

2003-06-27 Thread Alexander Puchmayr
Hi folks!

I've a small procmail trouble. 
When I have a .procmailrc in users's home dir, its working fine. But when I 
move that file to /etc/procmailrc, then it gets ignored.

Why? And how can I make procmail execute the global ruleset file?

Thanks
Alex


--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] procmail for deleting mails

2003-06-17 Thread Chris I
On 2003.06.17 04:58, Patrick Marquetecken wrote:
Hi,

I want to delete some mail before reetching my mailbox is this a good
way ?
in .procmailrc
:0:
* ^From:[EMAIL PROTECTED]
/dev/null
:0
* ^From:[EMAIL PROTECTED]
/dev/null
you forgot the * after the . , which helps. Other than that, its fine. 
I don't have the colon after the :0 in my .procmailrc, but I don't 
think it matters.

-Chris I

QOTD:
"It's hard to tell whether he has an ace up his sleeve or if
the ace is missing from his deck altogether."

pgp0.pgp
Description: PGP signature


[gentoo-user] procmail for deleting mails

2003-06-17 Thread Patrick Marquetecken
Hi,

I want to delete some mail before reetching my mailbox is this a good way ?
in .procmailrc

:0:
* ^From:[EMAIL PROTECTED]
/dev/null

-- 
 "Computer, delete Paris" -- The Doctor
 "What are you doing?!?" -- Ensign Kim
 "Computer, delete Kim" -- The Doctor (Projections)
 
 PGP Key: http://users.pandora.be/rivendell/marquetp.gpg
 Fingerprint = 2792 057F C445 9486 F932 3AEA D3A3 1B0C 1059 273B
 ICQ# 316932703 
 Registered Linux User #44550
 http://counter.li.org


pgp0.pgp
Description: PGP signature


Re: [gentoo-user] Procmail

2003-06-04 Thread Thomas T. Veldhouse
Here is what I have:

:0
* ^List-Id:.*gentoo-announce.gentoo.org.*  
${MAILDIR}/.Linux.Gentoo.Announce/

Good luck!

Tom Veldhouse

- Original Message - 
From: "--[ UxBoD ]--" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, June 02, 2003 1:09 PM
Subject: [gentoo-user] Procmail

Hi:

Having a dumb day! Just installed ProcMail and setup a basic
procmail.rc.


:0
* ^Subject:.Cron*
.cron-jobs/

:0
* ^Subject:.*[gentoo-announce].*
.gentoo-announce/

:0
* ^Subject:.*[gentoo-user].*
.gentoo-user/


Everything from Gentoo is being dropped into the gentoo-announce folder
instead of being split into user aswell based on the subject. What am I
doing wrong?

-- 

--[ UxBoD ]-- 
GPGKID [402E340E] [182C F930 C7E4 CA70 A202  9A82 82AC B1EA 402E 340E]
gpg --keyserver wwwkeys.pgp.net --recv-keys 402E340E





--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail

2003-06-03 Thread --[ UxBoD ]--
Great thanks! Told you I was having a dumb day ;)
-- 

--[ UxBoD ]-- 
GPGKID [402E340E] [182C F930 C7E4 CA70 A202  9A82 82AC B1EA 402E 340E]
gpg --keyserver wwwkeys.pgp.net --recv-keys 402E340E




signature.asc
Description: This is a digitally signed message part


Re: [gentoo-user] Procmail

2003-06-03 Thread Patrick Börjesson
> 
> :0
> * ^Subject:.Cron*
> .cron-jobs/
> 
> :0
> * ^Subject:.*[gentoo-announce].*
> .gentoo-announce/
> 
> :0
> * ^Subject:.*[gentoo-user].*
> .gentoo-user/
> 
> 
> Everything from Gentoo is being dropped into the gentoo-announce
> folder instead of being split into user aswell based on the subject.
> What am I doing wrong?

I use the list-id to sort my mail by:

-
:0
* ^List-Id:.*gentoo-user\.gentoo\.org
Mail-dir/.
-

The List-Id is easy to deduct from the mail-header.

I have these entries in my procmail-config:

* ^List-Id:.*gentoo-user\.gentoo\.org
* ^List-Id:.*gentoo-dev\.gentoo\.org
* ^List-Id:.*gentoo-security\.gentoo\.org
* ^List-Id:.*gentoo-announce\.gentoo\.org
* ^List-Id:.*gentoo-desktop\.gentoo\.org
* ^List-Id:.*gentoo-hardened\.gentoo\.org

--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail

2003-06-03 Thread Marshal Newrock
On Mon, 2 Jun 2003, --[ UxBoD ]-- wrote:

> Hi:
>
> Having a dumb day! Just installed ProcMail and setup a basic
> procmail.rc.
>
> 
> :0
> * ^Subject:.Cron*
> .cron-jobs/
>
> :0
> * ^Subject:.*[gentoo-announce].*
> .gentoo-announce/
>
> :0
> * ^Subject:.*[gentoo-user].*
> .gentoo-user/

[...] indicates a character range to match.  You would want:
* ^Subject:.*\[gentoo-user\]

This is a standard regex thing.  'man procmailrc' and 'man 7 regex' for
more details.  You also don't need a .* at the end.  It will only serve to
slow it down.

-- 
Marshal Newrock, Simon's Rock College of Bard
Caution: product may be hot after heating


--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail

2003-06-03 Thread Mark Fisher
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Monday 02 Jun 2003 7:09 pm, --[ UxBoD ]-- wrote:
> Hi:
>
> Having a dumb day! Just installed ProcMail and setup a basic
> procmail.rc.
>
> 
>
> :0
>
> * ^Subject:.Cron*
> .cron-jobs/
>
> :0
>
> * ^Subject:.*[gentoo-announce].*
> .gentoo-announce/
>
> :0
>
> * ^Subject:.*[gentoo-user].*
> .gentoo-user/
> 
>
> Everything from Gentoo is being dropped into the gentoo-announce folder
> instead of being split into user aswell based on the subject. What am I
> doing wrong?

I found I needed to escape the squared brackets:

[EMAIL PROTECTED] mark $ more .procmail/rc.gentoo-user 
:0:
* ^Subject:.*\[gentoo-user\]
.Gentoo-User/

HTH
- -- 
Mark
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.2.2 (GNU/Linux)

iD8DBQE+24b1zrmqzOOQUj8RAn3bAJ0ev38xQE3NCN2fNFlIhioVhhS8tQCeLZ4n
uRIwpKwRjMVZz5u2rF9DQMg=
=vj2D
-END PGP SIGNATURE-


--
[EMAIL PROTECTED] mailing list



Re: [gentoo-user] Procmail

2003-06-03 Thread Patrick Marquetecken
I have this and its working


* ^List-Id:.*gentoo-user
Gentoo-x86/


Patrick


On 02 Jun 2003 18:09:15 +
"--[ UxBoD ]--" <[EMAIL PROTECTED]> wrote:

> Hi:
> 
> Having a dumb day! Just installed ProcMail and setup a basic
> procmail.rc.
> 
> 
> :0
> * ^Subject:.Cron*
> .cron-jobs/
> 
> :0
> * ^Subject:.*[gentoo-announce].*
> .gentoo-announce/
> 
> :0
> * ^Subject:.*[gentoo-user].*
> .gentoo-user/
> 
> 
> Everything from Gentoo is being dropped into the gentoo-announce folder
> instead of being split into user aswell based on the subject. What am I
> doing wrong?
> 
> -- 
> 
> --[ UxBoD ]-- 
> GPGKID [402E340E] [182C F930 C7E4 CA70 A202  9A82 82AC B1EA 402E 340E]
> gpg --keyserver wwwkeys.pgp.net --recv-keys 402E340E
> 
> 
> 


-- 
 "The needs of the many outweigh the needs of the few." 
  Captain Spock in Star Trek II: The Wrath of Khan
 
 PGP Key: http://users.pandora.be/rivendell/marquetp.gpg
 Fingerprint = 2792 057F C445 9486 F932 3AEA D3A3 1B0C 1059 273B
 Registered Linux User #44550
 http://counter.li.org


pgp0.pgp
Description: PGP signature


[gentoo-user] Procmail

2003-06-03 Thread --[ UxBoD ]--
Hi:

Having a dumb day! Just installed ProcMail and setup a basic
procmail.rc.


:0
* ^Subject:.Cron*
.cron-jobs/

:0
* ^Subject:.*[gentoo-announce].*
.gentoo-announce/

:0
* ^Subject:.*[gentoo-user].*
.gentoo-user/


Everything from Gentoo is being dropped into the gentoo-announce folder
instead of being split into user aswell based on the subject. What am I
doing wrong?

-- 

--[ UxBoD ]-- 
GPGKID [402E340E] [182C F930 C7E4 CA70 A202  9A82 82AC B1EA 402E 340E]
gpg --keyserver wwwkeys.pgp.net --recv-keys 402E340E




signature.asc
Description: This is a digitally signed message part


Re: [gentoo-user] procmail lock failure

2003-02-16 Thread Mr R A Mercer
On Sat, 15 Feb 2003, mikepolniak wrote:

> On 08:56 Sat 15 Feb , Mr R A Mercer wrote:
> > Whenever an email gets delivered to my inbox I get the following error in 
> > the procmail log
> > 
> > ## procmail: Lock failure on "/var/spool/mail/ram.lock"
> > 
> > any ideas why procmail is having problems creating the lock file?
> > 
> Have not had this error myself but the man page says it...
> 
> Can  only  occur  if you specify some real weird (and illegal) lockfilenames 
> or if  the lockfile could  not  be  created  because of
> insufficient permissions or nonexistent subdirectories.

Thanks, my /var/spool/mail directory was not writable by the group mail, 
changing that removed the error.

Cheers

Adam

--
[EMAIL PROTECTED] mailing list




Re: [gentoo-user] procmail lock failure

2003-02-15 Thread mikepolniak
On 08:56 Sat 15 Feb , Mr R A Mercer wrote:
> Hi
> 
> Whenever an email gets delivered to my inbox I get the following error in 
> the procmail log
> 
> ## procmail: Lock failure on "/var/spool/mail/ram.lock"
> 
> any ideas why procmail is having problems creating the lock file?
> 
Have not had this error myself but the man page says it...

Can  only  occur  if you specify some real weird (and illegal) lockfilenames 
or if  the lockfile could  not  be  created  because of
insufficient permissions or nonexistent subdirectories.


--
[EMAIL PROTECTED] mailing list




[gentoo-user] procmail lock failure

2003-02-15 Thread Mr R A Mercer
Hi

Whenever an email gets delivered to my inbox I get the following error in 
the procmail log

## procmail: Lock failure on "/var/spool/mail/ram.lock"

any ideas why procmail is having problems creating the lock file?

Cheers

Adam

--
[EMAIL PROTECTED] mailing list