Friday, February 24, 2012

Database Mail Error "Invalid Parameter"

Hello,

We currently have the 64-bit SQL 2005 SP2 running on our machine. Prior to installation of SP2 we were able to send mail through Database Mail without any problem. Now the mail is successfully cued but not sent. Here is the message in the log:

Description:
The activated proc [dbo].[sp_sysmail_activate] running on queue msdb.dbo.ExternalMailQueue output the following: 'Error executing extended stored procedure: Invalid Parameter'

Does anyone have any thoughts?

Thanks in advance.

Simone

Have you checked the log file after the SP2 application?|||Thank you for the response. I did check the logs and saw nothing out of the ordinary.|||

Have you physically restarted the server?

We find we Database Mail stops working on our 64 bit versions of 2005 with any config change or SP install until after we reboot - then all works okay again.

Regards,

Gary.

|||Interesting. We will try the reboot this weekend. I'll post the result on Monday. Thanks for the response.|||Try restarting SQLAgent alone without the whole SQL services, as this sometimes clears the log behind the process.|||

We restarted the server over the weekend but this did not help. As advised by Satya, I restarted only SQLAgent. These are the only two messages in the log:

configuration option 'Agent XPs' changed from 1 to 0. Run the RECONFIGURE statement to install.

configuration option 'Agent XPs' changed from 0 to 1. Run the RECONFIGURE statement to install.

Mail is still failing to be sent. I am lost.

|||How to configure SQL Server Agent to send job status notifications and alert notifications in SQL Server 2005 64-bit editions

http://support.microsoft.com/kb/908360

SQL Server Agent is not integrated with Database Mail or with SQL Mail in Microsoft SQL Server 2005 64-bit editions. To send any notifications, such as job status notifications and alert notifications, follow the steps in this article to manually configure MAPI for use by SQL Server Agent Mail.

Note In SQL Server 2005 Service Pack 1 (SP1), you can use SQL Server Agent to interact with Database Mail as the mailing system on 64-bit operating systems.

|||I'm not actually using Sql Agent Mail, we are using Database Mail. It did work on this machine a few weeks ago, it just has since stopped working.|||

I believe I found our issue. We didn't receive any error messages stating that SP2 failed, but something did. Procedures in the msdb database were updated to allow for customized parameters (below taken from "What's New in SQL Server 2005 SP2 - http://download.microsoft.com/download/2/B/5/2B5E5D37-9B17-423D-BC8F-B11ECD4195B4/WhatsNewSQL2005SP2.htm):

Database Mail

You can now customize parameters that are passed to DatabaseMail90.exe

Customers and SQL Server Customer Support had difficulty in quickly identifying Database mail misconfigurations. Error reporting has been enhanced. The user will be given much more context to the underlying problems.|||

Although we received no errors when installing SP2, something did fail. The stored procedures did not all copy over. After reinstallation, database mail works as expected. Thank you to all.

Simone

|||
Thanks, we were experiencing the same problem with SP2 intallation failure and Database Mail invalid parameter error message.

No comments:

Post a Comment