Forum OpenACS Q&A: Error in ns_sendmail

Posted by Roberto Mello on
Hi all,

I am getting this error from the user registration (by selecting ns_param RegistrationRequiresEmailVerificationP 0):

[25/Jun/2000:17:00:44][12585.19463][-conn9-] Error: nsd.tcl:
Expected a 250 status line; got:
554 buildaddr: no host
Expected a 250 status line; got:
554 buildaddr: no host
    while executing
"_ns_sendmail $smtp $smtpport $timeout $tolist $bcclist  $from
$subject $body $extraheaders"
    (procedure "ns_sendmail" line 58)
    invoked from within

I checked my /etc/hosts and it's there. I don't know if this is some silly Sendmail configuration (I didn't setup the box), but Watchdog sends me e-mail with the error logs just fine (but it's written in Perl, hence it doesn't use ns_sendmail).

Anybody knows what could be causing AOLserver's ns_sendmail to act like that ?


Posted by Nathan Reeves on
From what I understand,  ns_sendmail doesn't actually use sendmail on the machine.  ns_sendmail does all mail communication by connecting directly to the remote host on port 25.

What may be a good first test would be to attempt to telnet to the remote host on port 25 and see if you get a connection successfully.  It's sounding like ns_sendmail isn't working out the address of buildaddr correctly (either by DNS or from /etc/hosts).

If all else fails, you might want to replace the hostname you have in your nsd.tcl/nsd.ini set as your mailhost and instead use the IP Address.

Let us know how you go.


Posted by Roberto Mello on
ns_sendmail just talks to port 25, yes, what I meant is that there's something wrong with my Sendmail (which is what is listening on port 25 on that machine) that is preventing AOLserver from sending e-mail. This is what I had found out by using telnet:

[robertm@hal Buyback]$ telnet localhost 25
Connected to localhost.localdomain.
Escape character is '^]'.
220 ESMTP Sendmail 8.9.3/8.8.7; Sun, 25 Jun 2000
17:27:10 -0600
HELO AOLserver
250 Hello localhost.localdomain [], pleased
to meet you
250 Sender ok
551 we do not relay
I did the "HELO AOLserver" and all myself. Since I hate the way configurations are done in Sendmail, I don't know how to tell Sendmail "Yes, it's ok to let domains relay".
Posted by Don Baccus on
You'll get a different error message if relaying's denied, so you're not far enough along to know if that's going to be a problem or not.

You do have MailHost set up correctly in your nsd.tcl file. i.e. to  On my boxes I'm just using my ISP's smtp server rather than set up sendmail on my box, and have never had a problem getting it to work.  If someone's listening on port 25 and expecting SMTP, as seems to be the case here, you should at least get a more specific error rather than the "there's no host" error.

Posted by Tom Jackson on

Another possible answer is a small bug I found in ACS. This I explained and provided a fix for at

Strange bug that only shows up with certain configurations.

The bug has been confirmed and fixed in the ACS