Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have postfix installed(should be default install). I only set the relayhost to be the gateway I need to go through. I then use sendmail as a test but the gateway rejects my message and I see that in my postfix logs. The weird thing is in the logs the from email address is incorrect (probably my fault somehow but that is my question).

I have this file

 subject: hi there
 This is my body of the message

I then run sendmail with

 sendmail -t < email2

The postfix error is

Jan 3 13:38:07 sdi-ci postfix/qmgr[1157]: 41B6BBF88C: from=, size=297, nrcpt=1 (queue active) Jan 3 13:38:07 sdi-ci postfix/smtp[26034]: 41B6BBF88C: to=,[192.666.555.555]:25, delay=590, delays=590/0.08/0.11/0.23, dsn=4.1.8, status=deferred (host[192.666.555.555] said: 450 4.1.8 : Sender address rejected: Domain not found (in reply to RCPT TO command))

EDIT: obviously is not my real domain and that is not my real ip. That is never a good idea to post so I always modify it. I fixed it by config in my below answer.

share|improve this question
192.666.555.555 ? – Mathias R. Jessen Jan 3 '13 at 20:45
@MathiasR.Jessen – Sammitch Jan 3 '13 at 23:48
edited the post for those were it was not obvious that and the ip are both fake. – Dean Hiller Jan 4 '13 at 13:49

in /etc/postfix/, modifying mydomain and myorigin fixed the issue and setting mydomain to and myorigin to $mydomain fixed the issue.

mydomain =
myorigin = $mydomain


share|improve this answer

Did you literally use as a sender domain? Your postfix is rejecting the message, because the domain of the sender cannot be resolved, which can be read in this log bit:

Sender address rejected: Domain not found (in reply to RCPT TO command)

Other than that, did you alter the output of the log, because the resolved IP address of (192.666.555.555) is an invalid IPv4 address. IPv4 adresses can go no further than 255 per octet. So 666 and 555 are impossible values. It should resolve to

Those two things combined give a strong suspicion that your nameserver configuration is faulty. Make sure your /etc/resolv.conf file lists accessible nameservers to be used for domain name resolution.

share|improve this answer
all of those where fake as it is never a good practice to put your real ips and domain names out there. – Dean Hiller Jan 4 '13 at 13:48

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.