1

从 SSRS 中的电子邮件订阅发送邮件时出现以下错误。

下面是配置部分:

<RSEmailDPConfiguration>
                        <SMTPServer>mysmtpserver addres</SMTPServer>
                        <SMTPServerPort>
                        </SMTPServerPort>
                        <SMTPAccountName>
                        </SMTPAccountName>
                        <SMTPConnectionTimeout>
                        </SMTPConnectionTimeout>
                        <SMTPServerPickupDirectory>
                        </SMTPServerPickupDirectory>
                        <SMTPUseSSL>
                        </SMTPUseSSL>
                        <SendUsing>2</SendUsing>
                        <SMTPAuthenticate>2
                        </SMTPAuthenticate>
                        <From>myid@domain.com</From>
                        <EmbeddedRenderFormats>
                            <RenderingExtension>MHTML</RenderingExtension>
                        </EmbeddedRenderFormats>
                        <PrivilegedUserRenderFormats>
                        </PrivilegedUserRenderFormats>
                        <ExcludedRenderFormats>
                            <RenderingExtension>HTMLOWC</RenderingExtension>
                            <RenderingExtension>NULL</RenderingExtension>
                            <RenderingExtension>RGDI</RenderingExtension>
                        </ExcludedRenderFormats>
                        <SendEmailToUserAlias>True</SendEmailToUserAlias>
                        <DefaultHostName>
                        </DefaultHostName>
                        <PermittedHosts>
                        </PermittedHosts>
                    </RSEmailDPConfiguration>

错误:

notification!WindowsService_0!1858!08/20/2013-05:48:02:: i INFO: Handling subscription f78a80f1-dd72-4215-b86a-96fa7391cfc0 to report ReportMenu, owner: mydomain\myid, delivery extension: Report Server Email.
library!WindowsService_0!1858!08/20/2013-05:48:02:: i INFO: RenderForNewSession('/ReportProject/ReportMenu')
library!WindowsService_0!1858!08/20/2013-05:48:04:: i INFO: Initializing EnableExecutionLogging to 'True'  as specified in Server system properties.
emailextension!WindowsService_0!1858!08/20/2013-05:48:04:: e ERROR: Error sending email. Exception: System.Net.Mail.SmtpException: Mailbox unavailable. The server response was: 5.7.1 Client does not have permissions to send as this sender
   at System.Net.Mail.DataStopCommand.CheckResponse(SmtpStatusCode statusCode, String serverResponse)
   at System.Net.Mail.SmtpConnection.OnClose(Object sender, EventArgs args)
   at System.Net.ClosableStream.Close()
   at System.Net.Mail.MailWriter.Close()
   at System.Net.Mail.SmtpClient.Send(MailMessage message)
   at Microsoft.ReportingServices.EmailDeliveryProvider.EmailProvider.Deliver(Notification notification)
notification!WindowsService_0!1858!08/20/2013-05:48:04:: i INFO: Notification f06badda-98db-4aba-8a1f-26646430479b completed.  Success: True, Status: Failure sending mail: Mailbox unavailable. The server response was: 5.7.1 Client does not have permissions to send as this sender, DeliveryExtension: Report Server Email, Report: ReportMenu, Attempt 0

有人可以帮忙吗?

4

1 回答 1

4

根据例外情况,问题来自 SMTP 服务器:

状态:发送邮件失败:邮箱不可用。服务器响应为:5.7.1 客户端无权作为此发件人发送

因为您已在配置中SMTPAuthenticate设置为2,SSRS 服务用户将尝试对 SMTP 服务器进行身份验证。有关详细信息,请参阅为电子邮件传递配置报表服务器

您需要解决此问题 - 因为 SSRS 正在运行NT Service\ReportServer并尝试发送邮件,因为<From>myid@domain.com</From>SMTP 服务器不允许这样做,因此会出现错误。

作为测试,您可以将 SSRS 服务用户更改myid@domain.com为检查以确认这是问题所在。

如果是这样,您应该调查让域用户设置邮箱并在该用户下运行 SSRS 服务。

您的另一个选项是从配置中删除 Authentication 选项(即设置SMTPAuthenticate0)并允许对 SMTP 服务器进行匿名身份验证,尽管在您的环境中可能不允许这样做。

于 2013-08-20T13:51:01.757 回答