Microsoft KB Archive/153159

= HOW TO: Troubleshoot SQL Mail with Microsoft Exchange Server =

Article ID: 153159

Article Last Modified on 12/29/2003

-

APPLIES TO


 * Microsoft SQL Server 2000 Standard Edition
 * Microsoft SQL Server 2000 64-bit Edition
 * Microsoft SQL Server 7.0 Standard Edition
 * Microsoft SQL Server 6.5 Standard Edition
 * Microsoft SQL Server 6.0 Standard Edition

-



This article was previously published under Q153159



SUMMARY
 * SQL Mail Checklist

REFERENCES



SUMMARY
This article discusses certain basic troubleshooting techniques that you can use to diagnose and resolve most SQL Mail problems. Typically, the errors you receive when you start a SQL Mail session or when you send mail from SQL Mail with a Microsoft Exchange Server fall into two categories:
 * Permissions problems.

-and-


 * Exchange client setup problems.

SQL Mail functionality is documented in SQL Server Books Online. Read the SQL Mail documentation thoroughly before you use SQL Mail.

Note SQL Mail is not currently supported in Microsoft SQL Server 2000 64 bit. For more information, see the SQL Server 2000 64 bit Readme file.

back to the top

SQL Mail Checklist
To troubleshoot the SQL Mail problem, follow the items in this checklist in order:  Log on to Microsoft Windows NT with a user account that is an administrator of the local computer, and that is also a domain account. Confirm that the Microsoft Exchange client, Exchng32.exe, can connect to the Exchange server, and confirm that you can send mail. Confirm that the Exchange profile that you are using does not have a Personal Message Store (.pst) by running the Mail and Fax tool in Control Panel. Click Show Profiles. In the Mail dialog box, click to select the default profile that is in the profile list according to the drop-down list labeled "When starting Microsoft Exchange, use this profile." Click Properties. Click the Services tab in the new dialog box, and then confirm that the only services are Microsoft Exchange Server and Personal Address Book. Click the Delivery tab, and confirm that the selection in the Deliver To drop-down list box is the Mailbox on the Exchange Server, which is something like "Mailbox - " where "Friendly User Name" is the name of the user who logged on to Windows NT in step one. To run SQL Mail with an Exchange Server, the MSSQLServer service must run under the same user account that logged on in step one. To determine this, open the Services tool in Control Panel, and then select the MSSQLServer service. Click Startup. Confirm that the SQL Mail user name and password are correct by running the SQL Server Setup. Click Set Server Options, and then click Mail Login. The user name must match the Profile name in step three.NOTE: The password and Copy SQLMail Configuration in the Current UserAccount check box do not matter because both no longer apply.

SQL Server Setup version 6.5 only prompts you for the Exchange Profile name.

</li> : The password and Copy SQLMail Configuration in the Test SQL Server access permissions to the Exchange Server by using the xp_cmdshell extended stored procedure, which runs with the same permissions as SQL Mail. Use the following command to test connectivity to the server, assuming that the Exchange Server is located on a computer that is named "NTServer":

xp_cmdshell "NET USE \\NTServer\IPC$" If this command fails, step three has not been completed correctly.

</li> : The password and Copy SQLMail Configuration in the At this point, SQL Mail should:

<ul> Be able to Autostart.

-or-

</li> Be able to start manually with the xp_startmail extended stored procedure.

</li></ul>

Additionally, you can choose the profile to use with xp_startmail by replacing the <Profile name> with the profile name from step three, as in the following example:

xp_startmail "<Profile name>","" </li></ol>

back to the top

<div class="references_section">