39 messages in net.sourceforge.lists.courier-maildropRe: [maildropl] Maildrop EX_TEMPFAIL
FromSent OnAttachments
ha...@newmail.tvnet.huJul 5, 2002 11:37 pm 
Derrick 'dman' HudsonJul 6, 2002 9:05 am 
ha...@newmail.tvnet.huJul 8, 2002 12:56 am 
ha...@newmail.tvnet.huJul 8, 2002 6:40 am 
Derrick 'dman' HudsonJul 8, 2002 7:07 am 
Ben RosengartJul 8, 2002 7:09 am 
Matthias AndreeJul 8, 2002 8:24 am 
Matthias AndreeJul 8, 2002 8:25 am 
Ben RosengartJul 8, 2002 8:35 am 
Matthias AndreeJul 8, 2002 8:51 am 
Sam VarshavchikJul 8, 2002 3:03 pm 
Ben RosengartJul 8, 2002 3:32 pm 
Sam VarshavchikJul 8, 2002 4:15 pm 
Matthias AndreeJul 8, 2002 5:10 pm 
Sam VarshavchikJul 8, 2002 6:09 pm 
Ben RosengartJul 8, 2002 6:20 pm 
Sam VarshavchikJul 8, 2002 6:28 pm 
Ben RosengartJul 8, 2002 6:44 pm 
Sam VarshavchikJul 8, 2002 6:51 pm 
ha...@newmail.tvnet.huJul 9, 2002 3:56 am 
Matthias AndreeJul 10, 2002 2:47 am 
Matthias AndreeJul 10, 2002 2:49 am 
Matthias AndreeJul 10, 2002 3:05 am 
Derrick 'dman' HudsonJul 10, 2002 7:40 am 
Matthias AndreeJul 11, 2002 2:51 am 
Derrick 'dman' HudsonJul 13, 2002 9:00 am 
Matthias AndreeJul 14, 2002 7:47 am 
Derrick 'dman' HudsonJul 15, 2002 8:19 pm 
Sam VarshavchikJul 15, 2002 9:19 pm 
Ben RosengartJul 16, 2002 6:52 am 
Sam VarshavchikJul 16, 2002 7:22 am 
Ben RosengartJul 16, 2002 8:09 am 
Ben RosengartJul 16, 2002 11:24 am 
Sam VarshavchikJul 17, 2002 9:59 am 
Ben RosengartJul 17, 2002 12:29 pm 
Matthias AndreeJul 17, 2002 3:27 pm 
Matthias AndreeJul 17, 2002 3:33 pm 
Matthias AndreeJul 17, 2002 3:34 pm 
Matthias AndreeJul 18, 2002 12:21 pm 
Actions with this message:
Paste this link in email or IM:
Paste this link in email or IM:
Atom feed for this thread
Paste this URL into your reader:
Subject:Re: [maildropl] Maildrop EX_TEMPFAILActions...
From:Matthias Andree (ma@dt.e-technik.uni-dortmund.de)
Date:Jul 8, 2002 8:24:43 am
List:net.sourceforge.lists.courier-maildrop

ha@newmail.tvnet.hu writes:

Hi! I have a problem. Everything is working fine, but when someone send an email to my mailserver which can not deliver (there isn't such user, there was a mailserver change and some of the emailaddresses has expired) maildrop give an exit code (EX_TEMPFAIL). And maildrop tries to deliver in a few time, and EX_TEMPFAIL. It makes a very long queue in /var/spool/mqueue because sendmail don't drop the letters. Is there any solution? What can I do? rgs, Andras

I offered Sam a patch for 1.3.8.mumble and for 1.3.9 to overcome this and return EX_NOUSER instead, but never got a reply. Before I offered the patch, I had been told to not accept mail for unknown users, but on some MTAs, "unknown user" rejection won't work depending on how mail comes in (SMTP vs. sendmail) and how maildrop is integrated.

Sam?

Not sure if it still applies to 1.4. Unpack your source, save this mail, cd to the source directory, apply the patch with

patch -p1 <where-you-saved-this-mail

and recompile and reinstall maildrop. Reusing an existing unpacked maildrop source tree and patching that should also be fine.

This fixes your problem for me, but make sure that you reject mail for unknown users at your SMTP port as well, to avoid unnecessary mail + bounce traffic.

diff -ur maildrop-1.3.8.20020418/maildrop/maildrop.C
maildrop-1.3.8.20020418-ma1/maildrop/maildrop.C --- maildrop-1.3.8.20020418/maildrop/maildrop.C Sun Dec 31 07:04:00 2000 +++ maildrop-1.3.8.20020418-ma1/maildrop/maildrop.C Tue Apr 23 17:09:04 2002 @@ -74,6 +74,15 @@ cleanup(); return (r); } + catch (Except e) + { + merr << argv[0] << ": " << e.string << "\n"; +#if SYSLOG_LOGGING + syslog(LOG_INFO, e.string); +#endif + cleanup(); + return (e.exit_code); + } catch (const char *p) { merr << argv[0] << ": " << p << "\n"; diff -ur maildrop-1.3.8.20020418/maildrop/maildrop.h
maildrop-1.3.8.20020418-ma1/maildrop/maildrop.h --- maildrop-1.3.8.20020418/maildrop/maildrop.h Fri Sep 10 04:10:05 1999 +++ maildrop-1.3.8.20020418-ma1/maildrop/maildrop.h Tue Apr 23 17:08:31 2002 @@ -16,6 +16,13 @@ #include "mio.h" #include "config.h"

+class Except { +public: + int exit_code; + const char *string; + Except(int ex, const char *s) { exit_code = ex; string = s; } +}; + class Maildrop { public: int verbose_level; // Current verbose level diff -ur maildrop-1.3.8.20020418/maildrop/main.C
maildrop-1.3.8.20020418-ma1/maildrop/main.C --- maildrop-1.3.8.20020418/maildrop/main.C Fri Feb 15 14:37:15 2002 +++ maildrop-1.3.8.20020418-ma1/maildrop/main.C Tue Apr 23 17:04:09 2002 @@ -90,8 +90,8 @@

static void nouser() { - errexit=EX_TEMPFAIL; - throw "Invalid user specified."; + errexit=EX_NOUSER; + throw Except(errexit, "Invalid user specified."); }

static void nochangeuidgid()