• Home
  • About
Blue Orange Green Pink Purple

Dealing with sendmail errors

Posted in Linux. on Tuesday, August 19th, 2008 by admin Tags: 550 Banned, failure, sendmail, Service unavailable, smtp auth
Aug 19

I noticed last week that my emails were not being delivered properly. After taking a look at when the issue started, I realized that it was about the same time I updated my box.

My email was being returned with the reason: 550 Banned rcpt apache@localhost.localdomain. There was also another error 554 5.0.0 Service unavailable. Both of these errors on their own were not to helpful. I asked a friend (the one who sold me the box) to help and he gave me some good advice, but I was unable to resolve the issue and several Google searches didn’t reveal any solution.

I checked the maillog in /var/log/ and found that the mail was being sent internally, but I have to use my ISP mail server to actually deliver the messages and this was not happening. The error I found in the mail log that helped was “stat=Deferred: Temporary AUTH failure”. I was able to find the resolution to the issue right on the Sendmail.org site.

I use my sendmail as a client and up until last week I never had any issue with the setup I was using. I am still not sure if I began having an issue with sendmail because it was updated or if it was just my ISP found the security issue with the way I was using it, but eithr way, it stopped working correctly.

Here is the error:

----- The following addresses had permanent fatal errors -----
<apache@localhost.localdomain>
(reason: 550 Banned rcpt apache@localhost.localdomain *@localhost.localdomain)

----- Transcript of session follows -----
... while talking to mail.cableone.net.:
>>> RCPT To:<apache@localhost.localdomain>
<<< 550 Banned rcpt apache@localhost.localdomain *@localhost.localdomain
550 5.1.1 <apache@localhost.localdomain>... User unknown

Final-Recipient: RFC822; apache@localhost.localdomain
Action: failed
Status: 5.1.1
Remote-MTA: DNS; mail.cableone.net
Diagnostic-Code: SMTP; 550 Banned rcpt apache@localhost.localdomain *@localhost.localdomain
Last-Attempt-Date: Mon, 18 Aug 2008 21:45:23 -0500

---------- Forwarded message ----------
From: Mail Delivery Subsystem <MAILER-DAEMON>
To: <apache@localhost.localdomain>
Date: Mon, 18 Aug 2008 20:45:31 -0500
Subject: Returned mail: see transcript for details
----- The following addresses had permanent fatal errors -----
<support@cityofdilworth.com>
(reason: 550 Banned from (apache@localhost.localdomain) (*@localhost.localdomain))

----- Transcript of session follows -----
... while talking to mail.cableone.net.:
>>> MAIL From:<apache@localhost.localdomain> SIZE=1521
<<< 550 Banned from (apache@localhost.localdomain) (*@localhost.localdomain)
554 5.0.0 Service unavailable

Final-Recipient: RFC822; support@cityofdilworth.com
Action: failed
Status: 5.0.0
Diagnostic-Code: SMTP; 550 Banned from (apache@localhost.localdomain) (*@localhost.localdomain)
Last-Attempt-Date: Mon, 18 Aug 2008 20:45:31 -0500

---------- Forwarded message ----------

To resolve the issue, simply follow the instructions to setup SMTP AUTH that were provided by Benji Fisher. To start, log onto your machine as root.

  1. Change directory to where your sendmail configuration files (sendmail.mc and sendmail.cf) are located, usually /etc/mail/
  2. Create a safe subdirectory (suggested name auth/):# mkdir auth
    # chmod 700 auth
  3. Create a file with your authentication information (suggested name auth/client-info):
    AuthInfo:your.isp.net "U:root" "I:user" "P:password"

    filling in your ISP’s mail server, your user name, and your password. (Note: Earthlink, and perhaps other ISP’s, requires your full e-mail address as a user name.)

  4. Generate the authentication database and make both files readable only by root:
    # cd auth
    # makemap hash client-info < client-info
    # chmod 600 client-info*
    # cd ..
  5. Add the following lines to your sendmail.mc file, filling in your ISP’s mail server:define(`SMART_HOST',`your.isp.net')dnl
    define(`confAUTH_MECHANISMS', `EXTERNAL GSSAPI DIGEST-MD5 CRAM-MD5 LOGIN PLAIN')dnl
    FEATURE(`authinfo',`hash /etc/mail/auth/client-info')dnl
  6. Generate sendmail.cf:# m4 sendmail.mc > sendmail.cf
  7. Restart the sendmail daemon, e.g., (this depends on your OS):# service sendmail restart or # /etc/init.d/sendmail restart

That should take care of the issue!

Leave a Reply

dingobytes

  • Most Popular
    550 Banned AJAX Apache Coldfusion css directives Directory effect failure form forms image Javascript message mouseover options rotator sendmail Service unavailable setup smtp auth turorial Tutorial validation VirtualHost web site
  • Archives
    • October 2008
    • August 2008
    • April 2008
    • March 2008
    • February 2008
    • January 2008
  • flickrRSS probably needs to be setup
  • Archives
    • October 2008
    • August 2008
    • April 2008
    • March 2008
    • February 2008
    • January 2008
  • Search






  • Home
  • About

© Copyright dingobytes. All rights reserved.
Designed by FTL Wordpress Themes brought to you by Smashing Magazine

Back to Top