locked
MSCRMEmail Event Error #61042, What am I missing? RRS feed

  • Question

  • I've configured CRM to send mail from the Admin account through the CRM Email router but am getting an error in the event log and none of the CRM generated messages from the Admin account are being received.

    #61042 - An error occurred while processing the outgoing e-mail message with subject "Testing International Lead Workflow CRM:0004006" for SMTP: <HOST REMOVED> for delivery through <MAIL SERVER>. System.Net.Mail.SmtpException: Failure sending mail. ---> System.IO.IOException: Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host. ---> System.Net.Sockets.SocketException: An existing connection was forcibly closed by the remote host
       at System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size)
       --- End of inner exception stack trace ---
       at System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size)
       at System.Net.DelegatedStream.Read(Byte[] buffer, Int32 offset, Int32 count)
       at System.Net.BufferedReadStream.Read(Byte[] buffer, Int32 offset, Int32 count)
       at System.Net.Mail.SmtpReplyReaderFactory.ReadLines(SmtpReplyReader caller, Boolean oneLine)
       at System.Net.Mail.SmtpReplyReaderFactory.ReadLine(SmtpReplyReader caller)
       at System.Net.Mail.SmtpConnection.GetConnection(String host, Int32 port)
       at System.Net.Mail.SmtpClient.Send(MailMessage message)
       --- End of inner exception stack trace ---
       at System.Net.Mail.SmtpClient.Send(MailMessage message)
       at Microsoft.Crm.Tools.Email.Providers.SmtpPollingSendEmailProvider.ProcessMessageInternal(email emailMessage)
       at Microsoft.Crm.Tools.Email.Providers.CrmPollingSendEmailProvider.Run()

    Here is what I have looked into thus far:

    Configured the Exchange 2007 Hub Transport Receive Connector with the settings described in the KB article http://support.microsoft.com/kb/915827
    Run the SMTP test in the CRM Email Router - I can load the data for my CRM server, and test the connection for the Admin account via the Test Access button. The message reads Outgoing Status: Succeeded.
    Shut off the firewall on the CRM server and still getting the same error.

    I'm guessing this is a configuration issue, does anyone know what I am missing?
    Email Server: Exchange 2007
    CRM Version: 4.0.7333.3
    CRM OS: Server 2008
    • Edited by LukeG84 Monday, March 8, 2010 10:42 PM more info
    Monday, March 8, 2010 10:39 PM

Answers

  • have a read through this article.  it deals with the setup for Exchange 2010 so you can ignore those parts.  There is information in the post about required permissions and configuration.  Here are a couple more links that might help.  You most likely don't need the level of rights I indicated, it is just what I do when I am in an environment where I am trying to troubleshoot the router.  It helps to identify whether it is a security issue or something else.  I use the result to narrow my focus.

    Here are a couple of more links that might help.

    http://blogs.msdn.com/crm/archive/2009/01/08/troubleshooting-the-microsoft-dynamics-crm-e-mail-router.aspx

    http://blog.networkfoo.org/?tag=crm-email-router

    http://community.dynamics.com/blogs/cscrmblog/comments/4552.aspx

    http://video.mikelu.org/emailrouterexchange/emailrouterexchange.html

     


    Best Regards | Twitter: edwardsdna
    • Marked as answer by Jim Glass Jr Tuesday, March 30, 2010 4:28 PM
    Friday, March 26, 2010 8:21 PM
  • I haven't been able to 100% verify what fixed the problem but here is what I did.

    1. Uninstall and Re-install the CRM Email Router
    http://www.microsoft.com/downloads/details.aspx?FamilyId=E1358499-3FDB-45B8-ADF0-7585F758277E&displaylang=en

    2. Install the Router Rollup Update 9
    http://www.microsoft.com/downloads/details.aspx?familyid=5869F2B3-D1A0-4F71-8BE3-FDE6E8053A2E&displaylang=en

    Restart the Front End Server

    I ran a test email and it sent without any errors. The reason I am not 100% sure what fixed the solution is because the Exchange transport service might need to have been restarted after we added the user account to the Exchange Organization Administrator's group. Sometime between when we added the account to the group and when we installed the fix it could have been restarted and the re-install and upgrade could have nothing to do with the fix. We will investigate more and update the post when we have a complete answer.

    • Marked as answer by LukeG84 Friday, April 16, 2010 2:26 PM
    Friday, April 16, 2010 2:26 PM

All replies

  • Maybe could you post here the CRM Email router configuration?
    My blog : http://mscrmtools.blogspot.com
    You will find:
    Form Javascript Manager (export/import javascript from forms)
    ISV.Config Manager (graphical ISV.config edition - export/import)
    View Layout replicator (customize one view and replicate to others)
    And others (use tool tag on my blog)
    Wednesday, March 10, 2010 2:42 PM
    Moderator
  • Thanks for your assistance.
    What specific information about the configuration do you need?
    Wednesday, March 10, 2010 6:44 PM
  • Ensure the login account used for the E-mail Router service has full access to the Exchange Server.  You can view this post for more details on the E-mail Configuration details.


    Best Regards | Twitter: edwardsdna
    • Proposed as answer by Donna EdwardsMVP Friday, March 12, 2010 6:37 PM
    • Marked as answer by Jim Glass Jr Friday, March 12, 2010 8:04 PM
    • Unmarked as answer by LukeG84 Thursday, March 25, 2010 5:28 PM
    Friday, March 12, 2010 6:37 PM
  • Hi Donna,

    We verified the following on the crmadmin account:

    We also watched the following video from Micahel Lu and followed his instructions with no luck. We are still getting the same exception. http://blogs.msdn.com/crm/archive/2008/02/07/crm-4-0-e-mail-integration-overview.aspx

    Our current configuration is:

    Incoming:
     
    Profile Name = CRMIncoming
    E-mail Server = Exchange
    Authentication = Windows Authentication
    Location = https://mail.domain.com
    Access Credentials = Other Specified (format DOMAIN\crmadmin, also tested with the crmadmin@domain.com format for each of the Other specified fields)
     
    Outgoing:
     
    Profile Name = CRMOutgoing
    E-mail Server Type = SMTP
    Authentication Type = Windows Authentication
    Location - Server = exchange (the FQDN is exchange.DOMAIN.com so we just put exchange)
    Access Credentials = Other Specified (format DOMAIN\crmadmin)
     
    Deployments:
     
    Deployment = my company
    Access Credentials = Other Specified (format DOMAIN\crmadmin)
    Select the Default Configurations from the drop down

    Set the identity of the Microsoft CRM E-mail Router Service to crmadmin & restarted the service.

    any ideas?

    Thursday, March 25, 2010 5:46 PM
  • Can you temporarily give crmadmin full rights on Exchange to see if that makes a difference?  Also, I don't have a deployment available right now so I can't confirm the format for the Access credentials 'domain\crmadmin'.  I don't know if you need to reference the domain but it probably shows the right format in the installation guide for Access credentials.

    I've encountered the 'forcibly close connection' error in the past and it was generally security related.

     


    Best Regards | Twitter: edwardsdna
    Thursday, March 25, 2010 7:25 PM
  • Hi Donna,

    Is there a document from MS which outlines the required permissions for the CRM email router account? We have already granted a lot of access to the crm front end to allow it to send anonymous emails to the exchange server and I am getting pushback on how the CRMAdmin account needs to be a domain administrator. It would be nice to have a document which outlines the access requirements so we can grant the account the minimal permissions.

    Regardless, I will have the Administrator grant temporary full rights on Exchange and get back to you.

    Thanks,

    Luke

    Friday, March 26, 2010 1:32 PM
  • have a read through this article.  it deals with the setup for Exchange 2010 so you can ignore those parts.  There is information in the post about required permissions and configuration.  Here are a couple more links that might help.  You most likely don't need the level of rights I indicated, it is just what I do when I am in an environment where I am trying to troubleshoot the router.  It helps to identify whether it is a security issue or something else.  I use the result to narrow my focus.

    Here are a couple of more links that might help.

    http://blogs.msdn.com/crm/archive/2009/01/08/troubleshooting-the-microsoft-dynamics-crm-e-mail-router.aspx

    http://blog.networkfoo.org/?tag=crm-email-router

    http://community.dynamics.com/blogs/cscrmblog/comments/4552.aspx

    http://video.mikelu.org/emailrouterexchange/emailrouterexchange.html

     


    Best Regards | Twitter: edwardsdna
    • Marked as answer by Jim Glass Jr Tuesday, March 30, 2010 4:28 PM
    Friday, March 26, 2010 8:21 PM
  • The administrator added the user to the Exchange Organization Administrator's group and we are still recieving the error. Do we need to restart the Exchange mail service?

    Thank you,

    Friday, April 2, 2010 6:30 PM
  • Can you enable relaying on the exchange box and see if that helps?

     

    Mike

    Friday, April 9, 2010 4:14 AM
  • I haven't been able to 100% verify what fixed the problem but here is what I did.

    1. Uninstall and Re-install the CRM Email Router
    http://www.microsoft.com/downloads/details.aspx?FamilyId=E1358499-3FDB-45B8-ADF0-7585F758277E&displaylang=en

    2. Install the Router Rollup Update 9
    http://www.microsoft.com/downloads/details.aspx?familyid=5869F2B3-D1A0-4F71-8BE3-FDE6E8053A2E&displaylang=en

    Restart the Front End Server

    I ran a test email and it sent without any errors. The reason I am not 100% sure what fixed the solution is because the Exchange transport service might need to have been restarted after we added the user account to the Exchange Organization Administrator's group. Sometime between when we added the account to the group and when we installed the fix it could have been restarted and the re-install and upgrade could have nothing to do with the fix. We will investigate more and update the post when we have a complete answer.

    • Marked as answer by LukeG84 Friday, April 16, 2010 2:26 PM
    Friday, April 16, 2010 2:26 PM