Friday, January 2, 2015

SQL Reporting Services Subscriptions with errors

I wrote previously about a problem where if you don't use the proper case on a file output for an SSRS subscription report you receive an error in the subscription but the report works fine when you run it.

There's another way this can happen when an email address that the report is distributed to is rejected by the email server.  The report renders fine when you run it manually, and the SSRS execution log shows no errors.

The trick is to review the ReportServerService log in the SSRS data folder on the server.  It will show a "mail relay" error, or something of that sort.  This means the report is generating fine but is being rejected by the mail server.  The error might look like this:

emailextension!WindowsService_23!b74!01/02/2015-09:59:42:: e ERROR: Error sending email. System.Runtime.InteropServices.COMException (0x8004020F): The server rejected one or more recipient addresses. The server response was: 550 5.7.1 Unable to relay
   at ReportingServicesCDOInterop.MessageClass.Send()
   at Microsoft.ReportingServices.EmailDeliveryProvider.EmailProvider.Deliver(Notification notification)
notification!WindowsService_23!b74!01/02/2015-09:59:42:: e ERROR: Error occured processing subscription 499699f1-25ac-4067-9c89-27265e93d964: The e-mail address of one or more recipients is not valid.


The moral of the story is to check that ReportServerService log when you get errors in a report subscription for a report that runs fine otherwise.

No comments:

Post a Comment