LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 05-18-2005, 03:26 PM   #1
Whatever123
LQ Newbie
 
Registered: May 2005
Posts: 3

Rep: Reputation: Disabled
[ Post removed ]


Hi,

I'm trying to get this mail server to work correctly..All the basics are set up. We can send and receive mail just fine, except for one thing. When we send email, some servers end up rejecting it due to our server returning the wrong hostname!

I have multiple domains set up on this machine. Mail goes through to the correct addresses and all, except the EHLO will only reply with the hostname that the machine is named.

I'll call it 'hostname.com'

So, if I send mail from 'user@anotherhostname.com', and the receiving server checks it, the EHLO says: '220 hostname.com blah blah blah'

BUT, I need it to say: '220 anotherhostname.com'
- This being a reply with the hostname according to the IP address used to access the server.

Sendmail is set up to use BIND DNS (compiled in), and 'anotherhostname.com' is entered into the DNS database on the server, however right now, all the domains are set up on our hosting provider's domain name servers.

- Can this effect this sendmail configuration???

I've looked EVERYWHERE on Google and lots of other places as well.. I've seen lots of questions about this, but I can't seem to find the answer.

So, to wrap it up, I have a server with multiple domains and need sendmail to return the correct hostname upon EHLO queries to different IP addresses.

ANY help would be GREATLY appreciated!! Thanks in advance!

Last edited by Whatever123; 03-30-2009 at 12:39 PM.
 
Old 05-19-2005, 09:17 PM   #2
scowles
Member
 
Registered: Sep 2004
Location: Texas, USA
Distribution: Fedora
Posts: 620

Rep: Reputation: 31
Add the following to /etc/mail/sendmail.mc and then rebuild sendmail.cf. Change to match the reverse lookup name for your MTA. They should match. Some MTA's (like mine) are very picky about this.
Code:
define(`confDOMAIN_NAME', `mail.mydomain1.com')dnl
 
Old 05-20-2005, 11:04 AM   #3
Whatever123
LQ Newbie
 
Registered: May 2005
Posts: 3

Original Poster
Rep: Reputation: Disabled
So, will this enable the server to be able to reply with different hostnames for each IP?

ex:
123.0.0.1 would respond like: '220 hostname.com'
and
123.0.0.2 would respond like: '220 anotherhostname.com'

??

Last edited by Whatever123; 03-30-2009 at 12:38 PM.
 
Old 05-20-2005, 06:32 PM   #4
scowles
Member
 
Registered: Sep 2004
Location: Texas, USA
Distribution: Fedora
Posts: 620

Rep: Reputation: 31
I have never configured sendmail with more than one IP, so I can't answer your question.

By making the change I posted, your MTA will always HELO with the name you assign. Which should match your MTA's reverse name in DNS (using a single IP).

FWIW: I host multiple domains using one IP address. I have never had a problem with "outbound" e-mail, just as long as the HELO name matches the reverse lookup name for that IP. i.e. The external IP address of my firewall.
 
Old 05-23-2005, 10:56 AM   #5
Whatever123
LQ Newbie
 
Registered: May 2005
Posts: 3

Original Poster
Rep: Reputation: Disabled
The problem is solved! Thanks for your help.. To fix it, I ended up having to change all the MX records for each domain to the same address, and then changed the hostname of the machine to the address I set the MX records to.

Everything is working great now.. =) Just have to install SPF records now..

Last edited by Whatever123; 03-30-2009 at 12:37 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Hostname and Sendmail caps_phisto Linux - Networking 2 10-30-2004 11:51 AM
Residual hostname in Sendmail pauljtester Linux - Software 4 10-25-2004 01:54 PM
SMPT EHLO [IP] instead of EHLO hostname pave Linux - General 0 10-12-2004 10:01 AM
sendmail and unqualified hostname wlfdgcrkz Linux - Software 1 06-02-2003 03:53 PM
Sendmail and Hostname Change bmh.01 Linux - Software 3 05-31-2003 07:48 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 01:22 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration