Database MAIL( sp_send_dbmail) Error in SQL2008 R2:


The mail could not be sent to the recipients because of the mail server failure. (Sending Mail using Account 1 (2012-08-31T18:10:23). Exception Message: Cannot send mails to mail server. (Mailbox unavailable. The server response was: 5.7.1 Unable to relay). 

While sending mail from SQL job through sp_send_dbmail procedure in SQL2008R2, i am getting above error.2 identical emails are send (with same distribution list and same body), with one minute of difference.

Resolution:

One of the email id in the recipients causing the above issue. So I have resolved that issue by changing the wrong mail id in the recipients list to correct mail id.

Eg .(if SMTP server related to your office smtp server. Then sp_send_dbmail will not send mail to another office server mail id in the recipients list.)

Comments

  1. I get the same problem (mail sent twice at about a minute apart) when I am auto-sending mail to individuals (one address per call to sp_send_dbmail). Any ideas what might cause that?

    ReplyDelete

Post a Comment

Popular posts from this blog

SSIS2008R2 Error: 0xC0209303 at Package:

SQL2008R2 Error: The remote copy of database "XXXXX" has not been rolled forward to a point in time that is encompassed in the local copy of the database log. (Microsoft SQL Server, Error: 1412)