Configuring a Report Server for E-Mail Delivery
SQL Server 2005 Reporting Services includes an e-mail delivery extension so that you can distribute reports through e-mail.
The report server e-mail delivery extension is not configured by default. You must use the Reporting Services Configuration tool to minimally configure the extension. To set advanced properties, you must edit the RSReportServer.config file. If you cannot configure the report server to use this extension, you can deliver reports to a shared folder instead. For more information, see File Share Delivery in Reporting Services.
Configuration Requirements
- Report server e-mail delivery is implemented on Collaboration Data Objects (CDO) and requires a local or remote Simple Mail Transport Protocol (SMTP) server or SMTP forwarder.
- The Report Server Windows service account must have permission on the SMTP server to send mail.
- The Report Server E-mail delivery extension uses UTF-8 encoding in e-mail attachments. You cannot modify the encoding; the HTML rendering extension only supports UTF-8.
Note
The default e-mail delivery extension does not provide support for digitally signing or encrypting outgoing mail messages.
Configuring a Report Server for Local or Remote SMTP Service
You can use a local SMTP service or a remote SMTP server or forwarder to support e-mail delivery. If you have access to an existing remote SMTP server, you should consider using it. If there is no SMTP server available or if you subsequently encounter report delivery errors that can be attributed to computer connection failures, you should switch to using a local SMTP service. Details about how to configure a report server for local or remote service are provided further on in this topic.
Setting Configuration Options for E-Mail Delivery
Before you can use Report Server e-mail delivery, you must set configuration values that provide information about which SMTP server to use.
To configure a report server for e-mail delivery, do the following:
- Use the Reporting Services Configuration tool if you are specifying just an SMTP server and a user account that has permission to send e-mail. These are the minimum settings that are required for configuring the Report Server e-mail delivery extension.
- (Optionally) Use a text editor to specify additional settings in the RSreportserver.config and RSwebapplication.config files. Together, these two configuration files include all of the configuration settings for Report Server e-mail delivery. Specifying additional settings in these files is required if you are using a local SMTP server or if you are restricting e-mail delivery to specific hosts. For more information about finding and modifying configuration files, see Reporting Services Configuration Files in SQL Server Books Online.
The following table describes the e-mail delivery settings in each file:
File | Description |
---|---|
RSwebapplication.config |
Specifies the default delivery extension for all subscriptions that are created and managed through Report Manager. The DefaultDeliveryExtension setting in RSwebapplication.config specifies that the default delivery extension is report server e-mail. |
RSreportserver.config |
Stores all settings that relate to the SMTP service. |
Note
Report server e-mail settings are based on CDO. If you want more detail about specific settings, you can refer to the CDO production documentation.
Example Report Server E-Mail Configuration
The following example illustrates the settings in the RSreportserver.config file for a remote SMTP server. To read about the setting descriptions and valid values, see RSReportServer Configuration File or the CDO product documentation.
<RSEmailDPConfiguration>
<SMTPServer>mySMTPServer.Adventure-Works.com</SMTPServer>
<SMTPServerPort></SMTPServerPort>
<SMTPAccountName></SMTPAccountName>
<SMTPConnectionTimeout></SMTPConnectionTimeout>
<SMTPServerPickupDirectory></SMTPServerPickupDirectory>
<SMTPUseSSL></SMTPUseSSL>
<SendUsing>2</SendUsing>
<SMTPAuthenticate></SMTPAuthenticate>
<From>my-rs-email-account@Adventure-Works.com</From>
<EmbeddedRenderFormats>
<RenderingExtension>MHTML</RenderingExtension>
</EmbeddedRenderFormats>
<PrivilegedUserRenderFormats></PrivilegedUserRenderFormats>
<ExcludedRenderFormats>
<RenderingExtension>HTMLOWC</RenderingExtension>
<RenderingExtension>NULL</RenderingExtension>
</ExcludedRenderFormats>
<SendEmailToUserAlias>True</SendEmailToUserAlias>
<DefaultHostName></DefaultHostName>
<PermittedHosts>
<HostName>Adventure-Works.com</HostName>
<HostName>hotmail.com</HostName>
</PermittedHosts>
</RSEmailDPConfiguration>
Configuration Options for Setting the To: Field in a Message
User-defined subscriptions that are created according to the permissions granted by the Manage individual subscriptions task contain a pre-set user name that is based on the domain user account. When the user creates the subscription, the recipient name in the To: field is self-addressed using the domain user account of the person creating the subscription.
If you are using an SMTP server or forwarder that uses e-mail accounts that are different from the domain user account, the report delivery will fail when the SMTP server tries to deliver the report to that user.
To workaround this issue, you can modify configuration settings that allow users to enter a name in the To: field:
- Open RSReportServer.config with a text editor.
- Set SendEmailToUserAlias to False.
- Set DefaultHostName to the Domain Name System (DNS) name or IP address of the SMTP server or forwarder.
- Save the file.
Configuration Options for Remote SMTP Service
The connection between the report server and an SMTP server or forwarder is determined by the following configuration settings:
- SendUsing specifies a method for sending messages. You can choose between a network SMTP service or a local SMTP service pickup directory. To use a remote SMTP service, this value must be set to 2 in the RSReportServer.config file.
- SMTPServer specifies the remote SMTP server or forwarder. This value is a required value if you are using a remote SMTP server or forwarder.
- From sets the value that appears in the From: line of an e-mail message. This value is a required value if you are using a remote SMTP server or forwarder.
Other values that are used for remote SMTP service include the following (note that you do not need to specify unless you want to override the default values).
- SMTPServerPort is configured for port 25.
- SMTPAuthenticate specifies how the report server connects to the remote SMTP server. The default value is 0 (or no authentication). In this case, the connection is made through Anonymous access. Depending on your domain configuration, the report server and the SMTP server may need to be members of the same domain.
To send e-mail to restricted distribution lists (for example, distribution lists that accept incoming messages only from authenticated accounts), set SMTPAuthenticate to 2.
Configuration Options for Local SMTP Service
Configuring a local SMTP service is useful if you are testing or troubleshooting report server e-mail delivery. The local SMTP service is not enabled by default. For instructions on how to enable it, see How to: Configure a Report Server for E-mail Delivery (Reporting Services Configuration).
The connection between the report server and a local SMTP server or forwarder is determined by the following configuration settings:
SendUsing is set to 1.
SMTPServerPickupDirectory is set to a folder on the local drive.
Note
Be sure that you do not set SMTPServer if you are using a local SMTP server.
From sets the value that appears in the From: line of an e-mail message. This value is required.
Change History
Release | History |
---|---|
12 December 2006 |
|
17 July 2006 |
|
See Also
Tasks
How to: Start Reporting Services Configuration
How to: Configure a Report Server for E-mail Delivery (Reporting Services Configuration)
Concepts
E-Mail Delivery in Reporting Services
Reporting Services Configuration Files
Other Resources
Delivering Reports Through Subscriptions