How to set SMTP Relay hostname

Discuss installation of Scalix software

Moderators: ScalixSupport, admin

jmason1182
Posts: 55
Joined: Wed Jul 11, 2007 4:11 pm

How to set SMTP Relay hostname

Postby jmason1182 » Thu Aug 02, 2007 10:25 am

My scalix is running great. Like any good admin, I wanted to make sure i wasn't running an open relay and so I began running though a few open relay tests. While doing so, I was horrified to see that because the Scalix SMTP relay is the external SMTP daemon, instead of sendmail as I had used before, the local hostname and local domain of my machine are portrayed to the world. Sendmail had the

Code: Select all

DEFINE(`confDOMAIN_NAME',`mail.mydomain.com')dnl

option which would then mask the domain name so that when I did the following:

Code: Select all

telnet internal.mail.mydomain.local 25

I would see this:

Code: Select all

Trying 10.20.20.20...
Connected to internal.mail.mydomain.local (10.20.20.20).
Escape character is '^]'.
220 mail.mydomain.com ESMTP Sendmail 8.13.8/8.13.8; Thu, 2 Aug 2007 09:08:30 -0500

Emphasis on the: 220 mail.mydomain.com ESMTP...

My border router performs NAT and my domain name "mail.mydomain.com" points to it, and of course port 25 gets forwarded to "internal.mail.mydomain.local". Thus, all requests from the internet should ONLY see mail.mydomain.com.... and before, using sendmail, I had achieved this. But when I switched to scalix, the Scalix SMTP relay exposes the internal hostname of the server.
So now, this is what I have:

Code: Select all

[me@somehost ]$ telnet mail.mydomain.com 25
Trying XX.XX.XX.XX...
Connected to mail.mydomain.com.
Escape character is '^]'.
220 internal.mail.mydomain.local ESMTP Scalix SMTP Relay 11.1.0.10849; Thu, 02 Aug 2007 09:02:07 -0500 (CDT)


Once again, emphasis on: 220 internal.mail.mydomain.local ESMTP...

Aside from having to change all the attributes of an internal machine's name, DNS entries, the whole lot so that it becomes the full "mail.mydomain.com", is there a way to leave it with it's internal name but keep "internal.mail.mydomain.local" from showing up in the 220 line? IE, set the hostname for the SMTP relay service?

I tried setting the "DOMAIN=" parameter in smtpd.cfg but to no avail. Here's a snippet of smtpd.cfg.

Code: Select all

###############################################################################
# SMTP Relay Configuration
###############################################################################
EXTENSIONS=AUTH,DSN,8BITMIME
DOMAIN_NAME=mail.mydomain.com
LOCAL_NAMES=internal.mail.mydomain.local, midsl052.mydomain.local, mail.mylongdomain.com

# Uncomment the following lines to enable the Submission and LMTP listeners
SMTP=ON
SUBMIT=ON
#LMTP=ON
...

jmason1182
Posts: 55
Joined: Wed Jul 11, 2007 4:11 pm

Postby jmason1182 » Wed Sep 19, 2007 1:40 pm

I got this to work by changing the first alias in the /etc/hosts file.... so if my internal name is midsl052 and I want it to show up as the external name of mail.... then just go into /etc/hosts and change it like this:

FROM:
10.20.20.52 midsl052 midsl052.myinternal.local

TO:
10.20.20.52 mail.myexternal.com midsl052 midsl052.myinternal.local

HOWEVER... I seem to have a problem with SAC once I do this.....

kanderson

Postby kanderson » Wed Sep 19, 2007 9:24 pm

Have a look here.

http://www.scalix.com/wiki/index.php?ti ... P_Greeting

If you change your hostname, you will have other issues. There are howtos in the wiki that address them too, but I'd recommend just leaving your hostname as it was when you first installed.

Kev.


Return to “Installation”



Who is online

Users browsing this forum: No registered users and 2 guests

cron