Email was unsuccessful due to an unknown error. the message could not be sent because of an unexpected error (ePolicy Orchestrator is not sending emails)

Email was unsuccessful due to an unknown error. the message could not be sent because of an unexpected error (ePolicy Orchestrator is not sending emails)



Technical Articles ID:   KB81047
Last Modified:  7/9/2018
Rated:


Environment

McAfee ePolicy Orchestrator (ePO) 5.x, 4.x

Problem

ePO is not sending emails when an Automatic Response or Server Task is configured.

Problem

In ePO 4.x, test the connection by navigating to MenuConfiguration, Server Settings and click Email Server. Enter the email address and click Test to send test email. When this issue occurs, an error similar to the following is logged in orion.log:

"email was unsuccessful due to an unknown error. the message could not be sent because of an unexpected error"
"No mail recipients com.mcafee.orion.response.command.SendEmailCommand.invoke"

NOTE: The option for sending test email is not available in ePO 5.x.

Cause

The ePO server does not have appropriate permissions on the SMTP server. Isolate the issue using the steps in the Solution to correct this issue.

Solution

Determine whether the issue is with ePO or the Exchange server permission and correct that appropriately. Use the following steps to troubleshoot sending an email using a command prompt from the ePO server:
  1. Determine the mail server you are sending to:
    1. Click StartRun, type cmd and click OK.
    2. Type: NSLOOKUP
    3. Enter the following at the > entry:

      set q=mx 
      theirdomain.com 
      Response: 
      Non-authoritative answer: 
      theirdomain.com MX preference = 50, mail exchanger = mail.theirdomain.com 

      NOTE: Replace theirdomain.com with the actual name of the domain you want to send the email to.

       
  2. Connect to the mail server:
    NOTE: SMTP communicates over port 25. Attempt to use TELNET to connect to their mail server (mail.theirdomain.com) using the following steps:

    1. Click StartRun, type cmd and click OK.
    2. Type: * TELNET MAIL.THEIRDOMAIN.COM 25

      You should see something similar to the following as a response:

      220 mx.google.com ESMTP 6si6253627yxg.6

      NOTE: Be aware that different servers will display different greetings; however, something should display here. If nothing displays at this point, there are two possible problems. Port 25 is being blocked at your firewall, or their server is not responding.

       
  3. Send an email:
    1. Use simple SMTP commands to send a test email. 
      IMPORTANT: You cannot use the backspace key. It will work on-screen but not be interpreted correctly. These commands must be typed exactly as listed below.

      ehlo mydomain.com 
      mail from:<jiten_mehta@mydomain.com
      rcpt to:<recipient@theirdomain.com
      data 
      This is a test, please do not respond 
      quit

      NOTES: 
      - EHLO: Introduce yourself to the mail server. HELO can also be used, but EHLO tells the server to use the extended command set. 
      - MAIL FROM: Who's sending the email. Make sure to use the greater than / less than brackets (< >) as many email servers will require this. 
      - RCPT TO: Who you are sending it to. Again, brackets (< >) must be used here. 
      - quit: Exit the TELNET session.