Error when using SMTPMailService: 501 Command "HELO" requires an argument

Date:23 May 2008
Product/Release:LANSA Integrator
Abstract:Stack trace: javax.mail.MessagingException: 501 Command "HELO" requires an argument
Submitted By:LANSA Technical Support

Description:

When I try to use the SMTPCLIENT I get this error:

JSM ERROR STATUS CODE: ERROR
MESSAGE: 501 Command "HELO" requires an argument
Send Email error

Solution:

The most common cause of this error would be that the TCP/IP settings on the machine have not been setup correctly. This may be because the machine has been changed or if a new System i machine is in place and not set up yet.

The problem is that the following Java code used by JavaMail is failing:

InetAddress.getLocalHost().getHostName()

Check your TCP configuration:

GO CFGTCP 12. Change TCP/IP domain information Host name . . . . . . . . . . . 'LANSA01' Domain name . . . . . . . . . . 'SYD.LANSA.COM.AU'

Also check that the host.domain name exists in host table or DNS.