Page 1 of 1

postfix trying to send to itself

Posted: 2014/07/09 22:08:26
by outerlimits
I'm running a centos 5.6 version with postfix.

the server always sent to email addresses with a domain name other than it's own so when we created some email address (with the domain name of the server) on godaddy and we tried to start sending email there the server is getting confused and trying to send to itself.

let's assume the server name is

my hosts file has this entry : nnn.nnn.nnn.nnn abc

in addition to the standard stuff: localhost.localdomain localhost
::1 localhost6.localdomain6 localhost6

when the php app that runs on the server tries to send an email I get this in the maillog file:

Jul 9 11:01:57 abc postfix/qmgr[2458]: 415B8858107: to=<>, relay=none, delay=193595, delays=193595/0.01/0/0, dsn=4.4.1, status=deferred (delivery temporarily suspended: connect to[]: Connection refused)
Jul 9 11:01:57 abc postfix/qmgr[2458]: EF935858077: from=<>, size=9211, nrcpt=1 (queue active)

if I run nslookup and set the querytype to MX - it does come back with the names of the mail servers at godaddy but there's something going in the server that makes it think it should be connecting to itself.

any help would be appreciated.


Re: postfix trying to send to itself

Posted: 2014/08/27 13:36:59
by wintpe
you need to setup postfix via /etc/postfix/

things like

inet_interfaces = all

myorigin =

relayhost =

mydestination = localhost, $myhostname, $mydomain,

local_transport = local:$myhostname

mynetworks =

thats the config for a inbound mail server

regards peter