# Need help with linux Sendmail 550 (relay) error



## Shodan99 (Apr 13, 2012)

I am having the worst time getting email to work on my machine. the mx records are pointing to the right place finally but now I have problems with sendmail's relay configuration. nothing is getting through. I know everyone suggests using postfix, but I've spent a lot of time trying to figure out sendmail and feel like I'm almost there. If postfix would be easier to set up from start to finish I'm not against that either but I don't know the first thing about postfix. please help!


----------



## Shodan99 (Apr 13, 2012)

Delivery to the following recipient failed permanently:

info@andrewjohnston.me

Technical details of permanent failure: 
Google tried to deliver your message, but it was rejected by the recipient domain. We recommend contacting the other email provider for further information about the cause of this error. The error that the other server returned was: 550 550 5.7.1 <info@andrewjohnston.me>... Relaying denied (state 14).

----- Original message -----

DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=20120113;
        h=message-id:date:from:user-agent:mime-version:to:subject
         :content-type:content-transfer-encoding;
        bh=g3zLYH4xKxcPrHOD18z9YfpQcnk/GaJedfustWU5uGs=;
        b=gb4cjGEZibkM7Q659r7kNPOA2RQI1JMyathTWSIA6E+nUTdnYem+PAaOajipAXwP/X
         k/kulvjKyBqnToLIdlW5HiCJa1vjWxTm9NUfrz1SqJ9LiH8jgxHzY6mJOW/41ilhT8gQ
         MzczEekZDt2hJ0zePATh0GboNvVrMtEYVd0hIQ4Iz1JgOJ28nOjfx/eW2WYBpjeyp46t
         tMYnldl+tHLRV2c53aBe7Dnk4YfOO26kSeqRs2QQoKpYQVQOOcMnd+4W5ZUyIHXp9m+p
         iEeLzxrCbN3JOk4aIK1GpngDS3lZiSBjnaQvsSrmJa37l2wahDe8kKrmPI64RuY4ckM3
         DovA==
Received: by 10.60.172.231 with SMTP id bf7mr2585046oec.45.1334330429538;
        Fri, 13 Apr 2012 08:20:29 -0700 (PDT)
Return-Path: <bucsgamer@gmail.com>
Received: from [192.168.0.12] (cpe-76-185-119-164.tx.res.rr.com. [76.185.119.164])
        by mx.google.com with ESMTPS id o9sm10450627obd.21.2012.04.13.08.20.27
        (version=SSLv3 cipher=OTHER);
        Fri, 13 Apr 2012 08:20:28 -0700 (PDT)
Message-ID: <4F88442D.30408@gmail.com>
Date: Fri, 13 Apr 2012 10:20:13 -0500
From: "Andrew D. Johnston" <bucsgamer@gmail.com>
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:11.0) Gecko/20120327 Thunderbird/11.0.1
MIME-Version: 1.0
To: info@andrewjohnston.me
Subject: test
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

test


----------



## Easy Rhino (Apr 14, 2012)

what does your sendmail log say?


----------



## Shodan99 (Apr 14, 2012)

the most recent and the 40 or 50 test emails all show up as the following with different timestamps


Apr 13 19:24:58 ip-50-63-53-83 sendmail[1500]: q3E2OTb1001500: ruleset=check_rcpt, arg1=<xingkong268@126.com>, relay=[113.116.51.83] reject=550 5.7.1 <xingkong268@126.com>... Relaying denied. IP name lookup failed [113.116.51.83]


----------



## Easy Rhino (Apr 14, 2012)

Shodan99 said:


> the most recent and the 40 or 50 test emails all show up as the following with different timestamps
> 
> 
> Apr 13 19:24:58 ip-50-63-53-83 sendmail[1500]: q3E2OTb1001500: ruleset=check_rcpt, arg1=<xingkong268@126.com>, relay=[113.116.51.83] reject=550 5.7.1 <xingkong268@126.com>... Relaying denied. IP name lookup failed [113.116.51.83]



looks like sendmail isnt setup to accept mail on that IP. you have to add it and localhost to your config.


----------



## Shodan99 (Apr 16, 2012)

where do I do that? I've been looking at the sendmail.mc file and making changes and using m4 to update the changes into the sendmail.cf file, but I don't really know what I'm looking at in the sendmail.mc file to begin with.


----------



## Easy Rhino (Apr 16, 2012)

sorry i am not familiar with sendmail config files. there should be a place where you tell sendmail that any mail coming to it over port 25 should be relayed to your local system (for what will be handed off to your MDA) if the local system is whatever your ip is. 

in other words, this...

http://www.sendmail.org/~ca/email/relayingdenied.html#RELDENMISSDNS


----------



## Shodan99 (Apr 16, 2012)

nevermind, I just figured it out. Thanks for your help


----------



## Easy Rhino (Apr 16, 2012)

Shodan99 said:


> nevermind, I just figured it out. Thanks for your help



what was it?


----------



## Shodan99 (Apr 16, 2012)

For some reason the script that tells sendmail to accept mail from outside my localhost was commented out. so it was only allowing internal emails


----------



## Easy Rhino (Apr 16, 2012)

Shodan99 said:


> For some reason the script that tells sendmail to accept mail from outside my localhost was commented out. so it was only allowing internal emails



ah yes. by default sendmail denies relays. glad you got it worked out.


----------

