Re: [Mailman-Users] (re-post) smtp failures, please help
Awesome, this below is exactly what I was looking for; I'll add that code to try and get more debug from the smtp transaction.
Thanks Ricardo
If you look in Mailman/Handlers/SMTPDirect.py within the definition of bulkdeliver() you'll see
except smtplib.SMTPResponseException, e: syslog('smtp-failure', 'SMTP session failure: %s, %s, msgid: %s', e.smtp_code, e.smtp_error, msgid)
You could add following that something like
syslog('smtp-failure', 'Args\n envsender->%s \n recips->%s\n msgtext->%s', envsender, recips, msgtext)
to try to see what is actually being given to the sendmail method that fails.
-- Mark Sapiro msapiro@value.net The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
Ricardo Kleemann wrote:
Awesome, this below is exactly what I was looking for; I'll add that code to try and get more debug from the smtp transaction.
<snip> >> >> You could add following that something like >> >> syslog('smtp-failure', 'Args\n envsender->%s >> \n recips->%s\n msgtext->%s', envsender, recips, msgtext) >> >> >> to try to see what is actually being given to the sendmail method that >> fails.
Ooops... can't break a single quoted string across lines. Make that
syslog('smtp-failure', 'Args\n envsender->%s\n recips->%s\n
msgtext->%s', envsender, recips, msgtext)
(and watch out for the wrapped line, and be sure the syslog is intented to the same level as the preceding one.)
-- Mark Sapiro msapiro@value.net The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
Thanks Mark.
This helped me to figure it out...! The envelope sender is set to mailman-bounces@localhost, and it seems courier doesn't like that. I verified that by telnetting into my mail server and got the same 517 syntax error when I sent:
mail from: mailman-bounces@localhost
Is mailman-bounces one of the required aliases? How can I configure mailman such that it uses a proper email address rather than providing mailman-bounces@localhost ?
Ricardo ----- Original Message ----- From: "Mark Sapiro" msapiro@value.net To: "Ricardo Kleemann" ricardo@americasnet.com Cc: mailman-users@python.org Sent: Wednesday, June 01, 2005 8:49 PM Subject: Re: [Mailman-Users] (re-post) smtp failures, please help
Ricardo Kleemann wrote:
Awesome, this below is exactly what I was looking for; I'll add that code to try and get more debug from the smtp transaction.
<snip> >> >> You could add following that something like >> >> syslog('smtp-failure', 'Args\n envsender->%s >> \n recips->%s\n msgtext->%s', envsender, recips, msgtext) >> >> >> to try to see what is actually being given to the sendmail method that >> fails.
Ooops... can't break a single quoted string across lines. Make that
syslog('smtp-failure', 'Args\n envsender->%s\n recips->%s\n
msgtext->%s', envsender, recips, msgtext)
(and watch out for the wrapped line, and be sure the syslog is intented to the same level as the preceding one.)
-- Mark Sapiro msapiro@value.net The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
Ricardo Kleemann wrote:
This helped me to figure it out...! The envelope sender is set to mailman-bounces@localhost, and it seems courier doesn't like that. I verified that by telnetting into my mail server and got the same 517 syntax error when I sent:
mail from: mailman-bounces@localhost
Is mailman-bounces one of the required aliases? How can I configure mailman such that it uses a proper email address rather than providing mailman-bounces@localhost ?
I'm guessing the specific error is the localhost part, not the -bounces part since virtually all mail from mailman has an envelope sender of some listname-bounces@some.domain. In this case the listname is 'mailman', i.e. the site list.
Go to the admin pages (General Options) for the mailman list and you'll probably see host_name is localhost. Change it there and I think you'll be OK.
You could also run
bin/withlist -l -r fixurl mailman
Assuming your Defaults.py/mm_cfg.py values for DEFAULT_URL_HOST and mm_cfg.DEFAULT_EMAIL_HOST are 'good'.
-- Mark Sapiro msapiro@value.net The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
Hi Mark,
One thing that confuses me, is that I sent email to ricardo1-owner@lists.americasnet.com but as you see the smtp transaction used mailman-bounces (so it didn't use the listname, 'ricardo1')
I'm guessing the specific error is the localhost part, not the -bounces part since virtually all mail from mailman has an envelope sender of some listname-bounces@some.domain. In this case the listname is 'mailman', i.e. the site list.
Go to the admin pages (General Options) for the mailman list and you'll probably see host_name is localhost. Change it there and I think you'll be OK.
But unfortunately that's not the case... The config for the list has 'lists.americasnet.com' for the hostname
You could also run
bin/withlist -l -r fixurl mailman
Assuming your Defaults.py/mm_cfg.py values for DEFAULT_URL_HOST and mm_cfg.DEFAULT_EMAIL_HOST are 'good'.
What should DEFAULT_EMAIL_HOST be? I have it as localhost because I thought this is the host mailman uses to _connect_ to the email server, therefore it's set to localhost.
Ricardo
Thanks again Mark,
You've helped me solve it! :-)
Indeed, it was the localhost in Defaults.py that was causing the problem. I changed it to 'lists.americasnet.com' and now messages to -owner work...
Ricardo
----- Original Message ----- From: "Mark Sapiro" msapiro@value.net To: "Ricardo Kleemann" ricardo@americasnet.com Cc: mailman-users@python.org Sent: Thursday, June 02, 2005 7:29 AM Subject: Re: [Mailman-Users] (re-post) smtp failures, please help
Ricardo Kleemann wrote:
This helped me to figure it out...! The envelope sender is set to mailman-bounces@localhost, and it seems courier doesn't like that. I verified that by telnetting into my mail server and got the same 517
syntax
error when I sent:
mail from: mailman-bounces@localhost
Is mailman-bounces one of the required aliases? How can I configure mailman such that it uses a proper email address rather than providing mailman-bounces@localhost ?
I'm guessing the specific error is the localhost part, not the -bounces part since virtually all mail from mailman has an envelope sender of some listname-bounces@some.domain. In this case the listname is 'mailman', i.e. the site list.
Go to the admin pages (General Options) for the mailman list and you'll probably see host_name is localhost. Change it there and I think you'll be OK.
You could also run
bin/withlist -l -r fixurl mailman
Assuming your Defaults.py/mm_cfg.py values for DEFAULT_URL_HOST and mm_cfg.DEFAULT_EMAIL_HOST are 'good'.
-- Mark Sapiro msapiro@value.net The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
participants (2)
-
Mark Sapiro
-
Ricardo Kleemann