Find the answer to your Linux question:
Results 1 to 5 of 5
I guess I should put something into hosts file in order to get that to work. Something like "mail.smtp.host" ? I'm using java aspirin and get out: com.sun.mail.smtp.SMTPAddressFailedException: 504 5.5.2 ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Jan 2010
    Posts
    19

    SMTP/network ?


    I guess I should put something into hosts file in order to get that to work. Something like "mail.smtp.host" ?

    I'm using java aspirin and get out:
    com.sun.mail.smtp.SMTPAddressFailedException: 504 5.5.2 <localhost>: Helo command rejected: need fully-qualified hostname.

    I'm sure I have to do something with network setting, but not sure what.

  2. #2
    Linux Newbie
    Join Date
    Jan 2013
    Posts
    116
    According to errors you should check your hostname, have you set your hostname FQDN.

  3. #3
    Just Joined!
    Join Date
    Jan 2010
    Posts
    19
    This is the contence of my hosts file, the second line is pointless I think, I did not do that myself.
    So I guess I should put something there ? A sample mybe ?
    # Do not remove the following line, or various programs
    # that require network functionality will fail.
    127.0.0.1 localhost.localdomain localhost
    ::1 localhost6.localdomain6 localhost6
    mybe something like:

    127.0.0.1 google.com localhost

    If google.com would be on my machine ?

  4. $spacer_open
    $spacer_close
  5. #4
    Linux Newbie
    Join Date
    Jan 2013
    Posts
    116
    You use your IP address instead of 127.0.0.1 and your hostname you can use any as below:

    srv.info.com
    info.host.com
    server.domain.com

    and entry will be

    127.0.0.1 srv.info.com srv

    or

    your ip hostname


    ::1 is for ipv6, you can comment it by adding # in front if you are not using IPv6.

    One more thing you need entries for hostname as below:

    run command set temporary hostname:

    Code:
    #hostname any name
    
    for example:
    
    #hostname srv.info.com
    secondly add entries in hosts file as above and also in network file:

    Code:
    /etc/sysconfig/network
    Thanks

  6. #5
    Linux Newbie nplusplus's Avatar
    Join Date
    Apr 2010
    Location
    Charlotte, NC, USA
    Posts
    106
    Maybe you should look here, org.masukomi.aspirin.core.config.Configuration. It contains a parameter called "hostname" for which you should be able to set the fully-qualified domain name of the host you are sending from.

    N

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •