Kohei Nozaki's blog 

Configuring helo names of James


Posted on Friday Feb 06, 2015 at 04:47PM in Technology


My James instance looks like failed to determine its hostname as follows:

$ telnet localhost 10025
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
220 localhost.localdomain JAMES SMTP Server Server (JAMES SMTP Server ) ready
helo example.com
250 localhost.localdomain Hello example.com [127.0.0.1])

This can be solved by editing XML files such as smtpserver.xml, pop3server.xml and imapserver.xml respectively as follows:

<helloName autodetect="false">www.nailedtothex.org</helloName>

Also you should check that the name which James will use during communicate to another SMTP server. you can check it easily with this site. if the name is wrong, this may be a cause of that remote server will consider your James server as spammer. the name to use will be hostname of the server. you can check it with simply issuing hostname command on Linux.

Unfortunately you can’t set the hostname in portable way due to a bug in a dependency geronimo-javamail_1.4_mail. the hostname should be able to configured in mailetcontainer.xml as follows but not worked at the present time.

<!-- Set the HELO/EHLO name to use when connectiong to remote SMTP-Server -->
<mail.smtp.localhost>www.nailedtothex.org</mail.smtp.localhost>

So current geronimo-javamail_1.4_mail ignores that value. considerable solutions are following:

  1. Change the hostname of the server (for <= Java 7u51)

  2. Put you FQDN first (before localhost) in /etc/hosts. detail (for recent Java)

  3. Apply a patch to James

  4. Apply a patch to Geronimo JavaMail and update dependency of James. unfortunately seems like that fixed version of Geronimo JavaMail is not released yet.



No one has commented yet.

Leave a Comment

HTML Syntax: NOT allowed