-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hi, I'm having a problem with some mails handled by one particular rule in procmail - all the rest are being handled ok. The .procmailrc goes like this: VERBOSE=on LOGFILE=$HOME/procmail.log ... cut :0 * ^Received: from correo.foo.es { :0 * ^Received: from (ruebert.ieee.org|engine.ieee.org|hormel3.ieee.org|boldfish.ieee.org|aries3.ieee.org) $HOME/Mail/in_ieee :0 * ^FROM_DAEMON $HOME/Mail/in_daemon :0 $HOME/Mail/in_foo } The problem is that mail matching the "^Received" clause above goes to the "/var/spool/mail/cer" folder instead of the "$HOME/Mail/in_foo" that corresponds. The log is this, showing a write error: procmail: No match on "^List-Id: <husky-discuss.lists.sourceforge.net>" procmail: Executing "/usr/bin/spamc" procmail: No match on "^X-Spam-Status: Yes" procmail: No match on "^^rom[ ]" procmail: No match on "^From.*FETCHMAIL-DAEMON@nimrodel.valinor" procmail: No match on "^To.*virusalert@nimrodel.valinor" procmail: No match on "^From.*(MAILER-DAEMON|postmaster)@nimrodel.valinor" ... procmail: Match on "^Received: from correo.foo.es" procmail: No match on "^Received: from (ruebert.ieee.org|engine.ieee.org|hormel3.ieee.org|boldfish.ieee.org|aries3.ieee.org)" procmail: No match on "(^(Mailing-List:|Precedence:.*(junk|bulk|list)|To: Multiple recipients of |(((Resent-)?(From|Sender)|X-Envelope-From):|>?From )([^>]*[^(.%@a-z0-9])?(Post(ma?(st(e?r)?|n)|office)|(send)?Mail(er)?|daemon|m(mdf|ajordomo)|n?uucp|LIST(SERV|proc)|NETSERV|o(wner|ps)|r(e(quest|sponse)|oot)|b(ounce|bs\.smtp)|echo|mirror|s(erv(ices?|er)|mtp(error)?|ystem)|A(dmin(istrator)?|MMGR|utoanswer))(([^).!:a-z0-9][-_a-z0-9]*)?[%@> ][^<)]*(\(.*\).*)?)?$([^>]|$)))" procmail: Assigning "LASTFOLDER=/home/cer/Mail/in_foo" procmail: Opening "/home/cer/Mail/in_foo" procmail: Acquiring kernel-lock So far, normal. procmail: Error while writing to "/home/cer/Mail/in_foo" procmail: Truncated file to former size A write error. What write error? procmail: No match on "^Received: from pop.tiscali.es" procmail: Extraneous locallockfile ignored .... procmail: Bypassed locking "/var/spool/mail/cer.lock" procmail: Assigning "LASTFOLDER=/var/spool/mail/cer" procmail: Opening "/var/spool/mail/cer" procmail: Acquiring kernel-lock procmail: Notified comsat: "cer@0:/var/spool/mail/cer"
From sombody@somewhere.com Wed Aug 31 20:17:13 2005 Subject: Final.... Folder: /var/spool/mail/cer 952289
I have copied over the emails in /home/cer/Mail/in_foo to another folder, then deleted, recreated in_foo, and finally copied back all the emails. The folder has 57Mb (392 emails) and Pine seems happy with it, no complaints. Ideas? - -- Cheers, Carlos Robinson -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) Comment: Made with pgp4pine 1.76 iD8DBQFDFflQtTMYHG2NR9URAuBbAJ96DTk33WG7nb+BfwkIB40MTql0qgCffUW8 i7c5FLtIHFDl86hb4moJhu8= =k4MY -----END PGP SIGNATURE-----
Apologies, Carlos, this was meant for the list: Carlos E. R. wrote:
I'm having a problem with some mails handled by one particular rule in procmail - all the rest are being handled ok. The .procmailrc goes like this:
VERBOSE=on LOGFILE=$HOME/procmail.log
... cut
:0 * ^Received: from correo.foo.es { :0 * ^Received: from (ruebert.ieee.org|engine.ieee.org|hormel3.ieee.org|boldfish.ieee.org|aries3.ieee.org) $HOME/Mail/in_ieee
:0 * ^FROM_DAEMON $HOME/Mail/in_daemon
:0 $HOME/Mail/in_foo }
[snip]
procmail: Error while writing to "/home/cer/Mail/in_foo" procmail: Truncated file to former size
I *think* your rule should point to $HOME/Mail/in_foo/ if it is a directory (note the trailing slash). Hans
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 The Wednesday 2005-08-31 at 21:50 +0200, Hans du Plooy wrote:
:0 $HOME/Mail/in_foo }
procmail: Error while writing to "/home/cer/Mail/in_foo" procmail: Truncated file to former size
I *think* your rule should point to $HOME/Mail/in_foo/ if it is a directory (note the trailing slash).
No, it is a mailbox file. The rule should be correct, it has been that way for years... it started to misbehave less than a month ago. The problem is that write error... but I recreated the file. Perhaps there is an error in one of the emails that make procmail think the file is corrupt :-? - -- Cheers, Carlos Robinson -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) Comment: Made with pgp4pine 1.76 iD8DBQFDFlQctTMYHG2NR9URAibXAJ9gIPyDNScGW3xAbDhaGJDrVCIj8ACePP25 kPTD3oboFwIEU+EttKSVHFg= =N3kv -----END PGP SIGNATURE-----
On Thu, 01 Sep, 2005 at 03:06:24 +0200, Carlos E. R. wrote:
No, it is a mailbox file. The rule should be correct, it has been that way for years... it started to misbehave less than a month ago.
The problem is that write error... but I recreated the file. Perhaps there is an error in one of the emails that make procmail think the file is corrupt :-?
If that were the case, then recreating the file *empty* should work? HTH /Jon -- YMMV
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 The Thursday 2005-09-01 at 06:57 +0200, Jon Clausen wrote:
The problem is that write error... but I recreated the file. Perhaps there is an error in one of the emails that make procmail think the file is corrupt :-?
If that were the case, then recreating the file *empty* should work?
Well, I deleted and recreated the folder with the mail client (Pine), copying back the emails one by one in a single command (I think), but it did not work. Now I have emptied completely that folder (0 emails) and I will see what happens. - -- Cheers, Carlos Robinson -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) Comment: Made with pgp4pine 1.76 iD8DBQFDFtyktTMYHG2NR9URAkrrAJ0bKnB43gc6NRgI/N2Aw9lX6uSJ2gCfc6rk obQd5zIOP6ScT/HaLLIvvmI= =9rVO -----END PGP SIGNATURE-----
On Thu, 01 Sep, 2005 at 12:48:54 +0200, Carlos E. R. wrote:
Now I have emptied completely that folder (0 emails) and I will see what happens.
Is what I meant. Assuming that some message in the mailbox is confusing procmail, then removing all messages ought to make procmail happy again. Let us know how it goes? /Jon -- YMMV
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 The Friday 2005-09-02 at 06:41 +0200, Jon Clausen wrote:
Now I have emptied completely that folder (0 emails) and I will see what happens.
Is what I meant. Assuming that some message in the mailbox is confusing procmail, then removing all messages ought to make procmail happy again.
Let us know how it goes?
It is working, at least I got one email inside today :-) Now, how do I find the culprit, I wonder? Perhaps one email that I think is spam and wanted to check later... who knows. - -- Cheers, Carlos Robinson -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) Comment: Made with pgp4pine 1.76 iD8DBQFDGLiJtTMYHG2NR9URAmnzAJsFxF/kqP92Z7qvWq4WSIsXvsM+7QCbBruE k7duMlF8Vh7Ym0Iyuhk20Es= =/+g3 -----END PGP SIGNATURE-----
* Carlos E. R. <robin1.listas@tiscali.es> [09-02-05 15:44]:
It is working, at least I got one email inside today :-)
Now, how do I find the culprit, I wonder? Perhaps one email that I think is spam and wanted to check later... who knows.
Might possibly be a bad From_ in header. A quick check: formail -ds procmail -m sandbox.rc < saved.mail.box put a recipe in sandbox.rc to deliver the reprocessed saved.mail.box to a new.mail.box. this way you can work on the possibly bad files w/o disturbing your regular mail setup. -- Patrick Shanahan Registered Linux User #207535 http://wahoo.no-ip.org @ http://counter.li.org HOG # US1244711 Photo Album: http://wahoo.no-ip.org/gallery
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 The Friday 2005-09-02 at 16:21 -0500, Patrick Shanahan wrote:
Now, how do I find the culprit, I wonder? Perhaps one email that I think is spam and wanted to check later... who knows.
Might possibly be a bad From_ in header. A quick check: formail -ds procmail -m sandbox.rc < saved.mail.box
put a recipe in sandbox.rc to deliver the reprocessed saved.mail.box to a new.mail.box.
this way you can work on the possibly bad files w/o disturbing your regular mail setup.
Good idea, I had forgotten about formail. I'll try. - -- Cheers, Carlos Robinson -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) Comment: Made with pgp4pine 1.76 iD8DBQFDGcwAtTMYHG2NR9URArw4AJ4oFAvYOHrXZAZMfZVTfqUK9b2dpgCfe8J2 e4vkolNuAjh+UEehf32VClI= =vzol -----END PGP SIGNATURE-----
* Carlos E. R. <robin1.listas@tiscali.es> [09-03-05 11:18]:
this way you can work on the possibly bad files w/o disturbing your regular mail setup.
Good idea, I had forgotten about formail. I'll try.
Please give your results. gud luk, -- Patrick Shanahan Registered Linux User #207535 http://wahoo.no-ip.org @ http://counter.li.org HOG # US1244711 Photo Album: http://wahoo.no-ip.org/gallery
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 The Saturday 2005-09-03 at 12:21 -0500, Patrick Shanahan wrote:
Good idea, I had forgotten about formail. I'll try.
Please give your results. gud luk,
Here goes the report. I used this procmail file: VERBOSE=on DEFAULT=$HOME/tmp/Mail/OutDefault LOGFILE=$HOME/tmp/Mail/procmail.log LOG=`echo -n "+++----> ";date --iso-8601=seconds ; echo` LOG="" :0 * ^Received: from correo.foo.es { :0 * ^Received: from (ruebert.ieee.org|engine.ieee.org|hormel3.ieee.org|boldfish.ieee.org|aries3.ieee.org) $HOME/tmp/Mail/OutIEEE :0 * ^FROM_DAEMON $HOME/tmp/Mail/Out_daemon :0 $HOME/tmp/Mail/Out_foo } and run using this line: time formail -ds procmail -m procmailrc < IN_foo (it run in about 22 seconds) Result was this: 64288119 2005-09-05 19:31 IN_foo 87043 2005-09-05 20:01 OutDefault 64193756 2005-09-05 19:57 Out_foo 8591 2005-09-05 19:58 Out_daemon 461624 2005-09-05 19:52 procmail.log 695 2005-09-05 19:51 procmailrc Then I read the mailboxes and saw that IN_foo had 401 messages, and Out_foo just 400, one missing. But then, OutDefault had 11, and Out_daemon 1. They don't add, the entry mbox had 401. Funny. The entry mbox had 64,288,119 bytes and the three output mboxes, have, added together 64,289,390. The byte count matches, at least. The OutDefault mbox has 5 "funny" emails, broken inside. One, for example, contains only this (looking at the full headers in Pine): Content-Type: text/html; name=3D"text2.html"; format=3Dflowed Content-Transfer-Encoding: 8bit Content-Disposition: attachment; filename=3D"text2.html" All those 5 "funnies" belong to the same email, received last mail. The email itself I can read and seems to be normal (considering outlook to be normal :-p ). A file corruption, maybe. I will put back all those emails (except the funnies) in the main mailbox where they came from, and see if things work correctly now or not. I'll leave this email in the drafts mbox till I know. [...] (Next day) No, it wasn't that. I got another email redirected to the inbox. The above procedure did not catch the problem. - -- Cheers, Carlos Robinson -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) Comment: Made with pgp4pine 1.76 iD8DBQFDHXHPtTMYHG2NR9URAqsGAJ4xfMPH72qGGq6WtVL9mkZqiZIO/wCfYPIV xIK0u4Rl7gC4G1dRZpVG+B4= =RX1i -----END PGP SIGNATURE-----
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 The Tuesday 2005-09-06 at 12:38 +0200, Carlos E. R. wrote:
No, it wasn't that. I got another email redirected to the inbox. The above procedure did not catch the problem.
I moved a bunch of recent emails to the "seen" folder, and it started to work. Some email there was making procmail complain, or perhaps the mbox was too big. I don't know the exact cause, but it works now. - -- Cheers, Carlos Robinson -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) Comment: Made with pgp4pine 1.76 iD8DBQFDHePOtTMYHG2NR9URAgOkAJ40cfrLdUMQbu806nnDae/Jv9mjDACeN622 /QbHVvhqYARDjL9MeQV3JWI= =aXb2 -----END PGP SIGNATURE-----
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 The Wednesday 2005-08-31 at 20:39 +0200, Carlos E. R. wrote: Yeah, this was long ago, but I was having the same problem now and then:
procmail: Assigning "LASTFOLDER=/home/cer/Mail/in_foo" procmail: Opening "/home/cer/Mail/in_foo" procmail: Acquiring kernel-lock procmail: Error while writing to "/home/cer/Mail/in_foo" procmail: Truncated file to former size
A write error. What write error?
The problem is caused by postfix "mailbox_size_limit" setting! <http://www.xray.mpe.mpg.de/mailing-lists/procmail/2006-10/msg00040.html> |> Thank you, that was it. I was getting the error from procmail so I |> didn't think to look at postfix, but it turns out it sets a ulimit |> before spawning the delivery agent, so procmail inherits the limit from |> postfix. |> |> If would be nice if procmail told you *what* error it encountered, at |> least in verbose mode. If I'd seen that it was exceeding the file size |> limit (write returns EFBIG) I'd probably have thought to look in the |> right place. |> |> Anyway, for the benefit of people who google or search the procmail list |> archive and have this same problem, the postfix parameter is |> mailbox_size_limit and does NOT appear in the main.cf supplied with the |> source, but is documented in sample/sample-local.cf so you can copy that |> portion into main.cf and change the limit. And it works. :-) - -- Cheers, Carlos E. R. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (GNU/Linux) Comment: Made with pgp4pine 1.76 iD8DBQFFq9t3tTMYHG2NR9URApPrAJ9VKO//iIoXmsCP/GeUugwFPCPoJQCgjXDJ gh51QW0V/3K/PDsV/fbBp14= =gCEY -----END PGP SIGNATURE----- -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
* Carlos E. R. <robin.listas@telefonica.net> [01-15-07 15:22]: [...]
The problem is caused by postfix "mailbox_size_limit" setting!
<http://www.xray.mpe.mpg.de/mailing-lists/procmail/2006-10/msg00040.html>
|> Thank you, that was it. I was getting the error from procmail so I |> didn't think to look at postfix, but it turns out it sets a ulimit |> before spawning the delivery agent, so procmail inherits the limit from |> postfix. |> |> If would be nice if procmail told you *what* error it encountered, at |> least in verbose mode. If I'd seen that it was exceeding the file size |> limit (write returns EFBIG) I'd probably have thought to look in the |> right place. |> |> Anyway, for the benefit of people who google or search the procmail list |> archive and have this same problem, the postfix parameter is |> mailbox_size_limit and does NOT appear in the main.cf supplied with the |> source, but is documented in sample/sample-local.cf so you can copy that |> portion into main.cf and change the limit.
And it works. :-)
This is odd. I don't understand the missing "mailbox_size_limit" in main.cf. It appeared in 9.0 and is in my 10.1 main.cf and was there originally. I did not add it. The commenter must not have been using SUSE/openSUSE. going further, the system was Solaris. -- Patrick Shanahan Registered Linux User #207535 http://wahoo.no-ip.org @ http://counter.li.org HOG # US1244711 Photo Album: http://wahoo.no-ip.org/gallery2 OpenSUSE Linux http://en.opensuse.org/ -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 The Monday 2007-01-15 at 17:39 -0500, Patrick Shanahan wrote:
And it works. :-)
This is odd. I don't understand the missing "mailbox_size_limit" in main.cf. It appeared in 9.0 and is in my 10.1 main.cf and was there originally. I did not add it. The commenter must not have been using SUSE/openSUSE.
I never said he did :-) That was from the procmail list. I was googling for the error message "procmail: Error while writing to", and found many occurrences of it (some by you, by the way). Then it occurred to me to look directly on the procmail site, searched on their list, and bingo, found that curious solution. I changed my setting from 51200000 to 100000000, and a folder that was having that problem started working again - so that was the answer. I would never occurred to me that postfix would be the cause. The real problem is that procmail, even in verbose mode, does not report the cause of not being able to write to the mbox - and many people have been baffled by it over the years, probably.
going further, the system was Solaris.
I didn't check that. Procmail must be widely used indeed :-) - -- Cheers, Carlos E. R. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (GNU/Linux) Comment: Made with pgp4pine 1.76 iD8DBQFFrAaatTMYHG2NR9URAp6rAJ96fzwKXvGounxBiFiM94MUpU1RlQCgjo+I DbE/43zDAbU/cMOI3vuyFn4= =FloB -----END PGP SIGNATURE----- -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
* Carlos E. R. <robin.listas@telefonica.net> [01-15-07 17:59]:
The Monday 2007-01-15 at 17:39 -0500, Patrick Shanahan wrote: [...]
This is odd. I don't understand the missing "mailbox_size_limit" in main.cf. It appeared in 9.0 and is in my 10.1 main.cf and was there originally. I did not add it. The commenter must not have been using SUSE/openSUSE.
I never said he did :-)
No, I did not mean to infer that you did.
That was from the procmail list. I was googling for the error message "procmail: Error while writing to", and found many occurrences of it (some by you, by the way). Then it occurred to me to look directly on the procmail site, searched on their list, and bingo, found that curious solution.
I changed my setting from 51200000 to 100000000, and a folder that was having that problem started working again - so that was the answer.
I have a max msg size but maxmbox is set to "0". I have plenty of disk space and "0" appears to be the SUSE/openSUSE install default.
I would never occurred to me that postfix would be the cause. The real problem is that procmail, even in verbose mode, does not report the cause of not being able to write to the mbox - and many people have been baffled by it over the years, probably.
going further, the system was Solaris.
I didn't check that. Procmail must be widely used indeed :-)
Well, you and I use it :^) -- Patrick Shanahan Registered Linux User #207535 http://wahoo.no-ip.org @ http://counter.li.org HOG # US1244711 Photo Album: http://wahoo.no-ip.org/gallery2 OpenSUSE Linux http://en.opensuse.org/ -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 The Monday 2007-01-15 at 18:03 -0500, Patrick Shanahan wrote:
I changed my setting from 51200000 to 100000000, and a folder that was having that problem started working again - so that was the answer.
I have a max msg size but maxmbox is set to "0". I have plenty of disk space and "0" appears to be the SUSE/openSUSE install default.
As my system has been updated in steps from 8.1, I don't know if I adjusted it that way or if it was Yast. I guess "0" must mean "unlimited".
going further, the system was Solaris.
I didn't check that. Procmail must be widely used indeed :-)
Well, you and I use it :^)
That counts as two, a big user base X-) - -- Cheers, Carlos E. R. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (GNU/Linux) Comment: Made with pgp4pine 1.76 iD8DBQFFrC7gtTMYHG2NR9URAvTaAKCCdHFQR+GEL3pEIk6uliKxJX8/LgCfWp9u L1zmKVyaiF0D/4l52GyHLEs= =BrJK -----END PGP SIGNATURE----- -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
participants (5)
-
Carlos E. R.
-
Carlos E. R.
-
Hans du Plooy
-
Jon Clausen
-
Patrick Shanahan