"[Failed to send test email] org.apache.commons.mail.EmailException: Sending the email to the following server failed" error while configuring SMTP server in Aria Operations for Logs.
search cancel

"[Failed to send test email] org.apache.commons.mail.EmailException: Sending the email to the following server failed" error while configuring SMTP server in Aria Operations for Logs.

book

Article ID: 431072

calendar_today

Updated On:

Products

VCF Operations/Automation (formerly VMware Aria Suite)

Issue/Introduction

  • Unable to configure SMTP in Aria Operations for Logs to send email notifications.
  • While trying to configure and send the test email via the SMTP, it fails with the error: " [Failed to send test email] org.apache.commons.mail.EmailException: Sending the email to the following server failed"
  • Ping connection will be successful but the telnet connection gets terminated after getting connected.
  • SMTP server uses ESMTP mail service and the Aria Operations for Logs appliance IP is not trusted by the SMTP server. We can confirm the protocol being used by the SMTP server with the command: curl smtp://<IP address of the SMTP server>:25 -v
  • /var/log/loginsight/runtime.log contains the below errors:
    Caused by: javax.mail.MessagingException: Could not connect to SMTP host: ##.##.##.## port: 25, response: -1
            at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:2197) ~[javax.mail-1.6.2.jar:1.6.2]
         
    [20YY-MM-DD 09:54:21.876+0000] ["https-openssl-apr-443-exec-10"/##.##.##.## INFO] [com.vmware.loginsight.web.actions.misc.LoggerActionBean] [Submit form response {"errMsg":"Could not connect to SMTP host: ##.##.##.##, port: 25, response: -1","succ":false}]


Environment

Aria Operations for Logs 8.18.x

Cause

Modern ESMTP servers are configured to reject unauthorized relaying, meaning they only accept mail from authenticated users or trusted IP addresses.

Resolution

Review the SMTP server settings and check if the Aria Operations for Logs appliance's IP is trusted or not. Once the IP is trusted, the connection should be established without any termination from the SMTP server end.

Refer: Configure the SMTP Server for VMware Aria Operations for Logs