Error "Connection or outbound has closed." when sending SMTP email
search cancel

Error "Connection or outbound has closed." when sending SMTP email

book

Article ID: 398309

calendar_today

Updated On:

Products

VMware Aria Suite

Issue/Introduction

  • You change the SMTP settings to enable STARTTLS and port 587 but the test emails fail
    • Error:  Connection or outbound has closed.
  • Credentials have been verified
  •  Alert emails are failing as well.

Environment

VMware Aria Operations for Logs 8.x

Cause

The username has a character that the SMTP server does not allow.

Errors in /storage/core/loginsight/var/runtime.log

ERROR] [com.vmware.loginsight.notifications.NotificationQueue] [Error sending notification com.vmware.loginsight.notifications.WrappedNotification@abcd1234]
org.apache.commons.mail.EmailException: Sending the email to the following server failed : <smtpserver>:587
...
Caused by: javax.mail.MessagingException: Can't send command to SMTP host
...
Caused by: java.net.SocketException: Connection or outbound has closed

Errors in /storage/core/loginsight/var/ui_runtime.log

INFO] [com.vmware.loginsight.web.actions.settings.AbstractConfigurationActionBean] [Failed to send test email]
org.apache.commons.mail.EmailException: Sending the email to the following server failed : <smtpserver>:587
...
Caused by: javax.mail.MessagingException: Can't send command to SMTP host
...
Caused by: java.net.SocketException: Connection or outbound has closed

Resolution

Many SMTP servers restrict the use of specific special characters in the username. Review the documentation of the SMTP server for acceptable characters in usernames.

Workaround: Create the username in the SMTP server using only alpha-numeric characters.