i am not sure how to fix this problem

I have a ISP that is rejecting all my emails because they say the sender domain is unknown
My confusion is that i am relaying the email via my email server

for example
the linux box is flanders.mydomain.domain

in my sendmail.mc i have
define(`SMART_HOST', `mail.mydomain.com')dnl

part of the bounce header has
Received: from flanders.mydomain.com [xxx.xxx.xxx.xxx] by mail.mydomain.com with ESMTP
  (SMTPD-11.5) id 60a80000ba1d34e9; Mon, 3 Oct 2011 13:27:16 -0500

is there something else i need to do?

Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

The bounce message excerpt just says that flanders relayed through mail, it doesn't say why it was rejected at the receiving end.

I'm going to guess that you don't have a valid PTR record for the IP you are sending from at mail.mydomain.com

Goto http://network-tools.com/ and put that IP in, and see what it says in the results for "Host name"
Or you can use mxtoolbox which is handy for checking other mail related things such SPF records and blacklists.


Put your IP in where is
pariesAuthor Commented:
the reverse lookup for the ip of mail.mydomain.com is the correct ip according to network-tools.
we are not listed on anyones blacklist according to mxtoolbox

according to mxtoolbox , mx:mydomain.com is correct.

this is the response i got from the ISP support

According to the Bounce errors you are seeing the Frontier Mail Server does not see the domain @flanders.mydomain.com as valid. I would double check the reply to email address and make sure it is correct. If it is correct, you will want to email the Bounce and Headers to the post master of @flanders.mydomain.com. They can then contact the Frontier Postmaster to resovle this issue
Cloud Class® Course: Amazon Web Services - Basic

Are you thinking about creating an Amazon Web Services account for your business? Not sure where to start? In this course you’ll get an overview of the history of AWS and take a tour of their user interface.

Ah, I see.  The problem here is the envelope-from (or MAIL FROM, Return-path, envelope-sender, etc).

Try this in sendmail


Open in new window

That should work as long as all mail from that machine is @mydomain.com.  I'm not able to test that right now but have done this years ago, so give it a shot and let me know.

You can also add -f to sendmail on the commandline
    -fname      Sets the name of the ``from'' person (i.e., the sender of the
                 mail).  -f can only be used by ``trusted'' users (normally
                 root, daemon, and network) or if the person you are trying to
                 become is the same as the person you are.

Open in new window

To be clear, I know for sure that -fname works, but only like 90% certain about the masquerading since I can't test it.
pariesAuthor Commented:
so this is what i did as suggested
uncomment - MASQUERADE_AS(`mydomain.com')
added - MASQUERADE_DOMAIN(`mydomain.com')
uncomment -FEATURE(`masquerade_entire_domain')
uncomment -FEATURE(`masquerade_envelope')

#make -C /etc/mail
#/etc/rc.d/init.d/sendmail restart

here is the header now that i sent:
i do not think i did it correctly
Delivered-To: myemail@gmail.com
Received: by with SMTP id u14cs44896fal;
        Mon, 3 Oct 2011 14:42:53 -0700 (PDT)
Received: by with SMTP id e34mr409773anp.73.1317678172514;
        Mon, 03 Oct 2011 14:42:52 -0700 (PDT)
Return-Path: <root@flanders.mydomain.com>
Received: from mail.mydomain.com (mail.mydomain.com. [xxx.xxx.190.170])
        by mx.google.com with ESMTP id j38si6362776ani.43.2011.;
        Mon, 03 Oct 2011 14:42:52 -0700 (PDT)
Received-SPF: pass (google.com: domain of root@flanders.mydomain.com designates xxx.xxx.190.170 as permitted sender) client-ip=xxx.xxx.190.170;
Authentication-Results: mx.google.com; spf=pass (google.com: domain of root@flanders.mydomain.com designates xxx.xxx.190.170 as permitted sender) smtp.mail=root@flanders.mydomain.com
Received: from flanders.mydomain.com [xxx.xxx.190.234] by mail.mydomain.com with ESMTP
  (SMTPD-11.5) id e7300000bdf73c43; Mon, 3 Oct 2011 16:42:40 -0500
Received: from flanders.mydomain.com (localhost.localdomain [])
      by flanders.mydomain.com (8.13.8/8.13.8) with ESMTP id p93Lgp1Q013894
      for <myemail@gmail.com>; Mon, 3 Oct 2011 16:42:51 -0500
Received: (from root@localhost)
      by flanders.mydomain.com (8.13.8/8.13.8/Submit) id p93Lgpkd013893;
      Mon, 3 Oct 2011 16:42:51 -0500
Message-Id: <201110032142.p93Lgpkd013893@flanders.mydomain.com>
To: myemail@gmail.com
Subject: randy, October Newsletter
Date: Mon, 03 Oct 2011 16:42:51 -0500
From: "mydomain Newsletter" <noreply@mydomain.com>
X-Mailer: PHP-EMAIL,v1.1 (William Fowler)
MIME-Version: 1.0
Content-Type: multipart/alternative; boundary="-----91c2bc5a2725294704c4ba406763d00a"

Hmm yeah the problem is still there:

Open in new window

Try changing masquerade_domain, leave the others as-is.


Open in new window

pariesAuthor Commented:
yeah, no joy looks the same
pariesAuthor Commented:
this is from my mail log. not sure if it help
Oct  3 17:06:59 flanders sendmail[14899]: p93M6xmu014899: from=root, size=20606, class=0, nrcpts=1, msgid=<201110032206.p93M6xmu014899@flanders.mydomain.com>, relay=root@localhost
Oct  3 17:06:59 flanders sendmail[14900]: p93M6xHU014900: from=<root@flanders.mydomain.com>, size=20800, class=0, nrcpts=1, msgid=<201110032206.p93M6xmu014899@flanders.mydomain.com>, proto=ESMTP, daemon=MTA, relay=localhost.localdomain []
Oct  3 17:06:59 flanders sendmail[14899]: p93M6xmu014899: to=myemail@gmail.com, ctladdr=root (0/0), delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=50606, relay=[] [], dsn=2.0.0, stat=Sent (p93M6xHU014900 Message accepted for delivery)
Oct  3 17:06:59 flanders sendmail[14902]: p93M6xHU014900: to=<myemail@gmail.com>, ctladdr=<root@flanders.mydomain.com> (0/0), delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=140800, relay=mail.mydomain.com. [xxx.xxx.190.170], dsn=2.0.0, stat=Sent (Message queued)
Ahh now this is something I didn't know about...

Remove this line


Open in new window

There are always users that need to be "exposed" -- that is, their internal site name should be displayed instead of the masquerade name. Root is an example (which has been "exposed" by default prior to 8.10). You can add users to this list using

http://www.sendmail.org/m4/masquerading.html should be able to help with any other questions, but I'm pretty sure we got it after this.
On second thought, you should probably leave that in unless you must send as root to external accounts.

You can still test the overall masquerading by disabling EXPOSED_USER, or just test with a non-root account.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Email Protocols

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.