I have a job set up to run sp_send_dbmail. Then I notice there were no emails sent out. I check the log I found "DatabaseMail Process is shutting down".
In the log, there was "DatabaseMail Process Started" also.
I don't know what is calling this processes.
If in the log, Stop was the last activity, all I can make this process start is to restart the database.
Does anyone know the trick?
Experiencing the same problem as you, I managed to start the process which was automatically shut down by sending a new test mail. After the process was started I tried running the job which shoul trigger the mail again. No luck this time either, but in the log I now found that no default mail profile was set.
I couldn't find a good was to set a default profile in the Management Studio IDE other than removing the old account and profile and then create it all over again, this time setting the new profile as the default profile. After that It worked.
Hope it works out.
|||If you right click on Database Mail you can select the mail log. Are there any errors in there? Check the SQL Agent error log and the SQL Server Log.
You need to set up an initial DBMail profile (for the Server) and the email server it is pointing to. Also try to run the Database Mail Configuration Wizard again or open up Management, and right-click Database Mail, then follow the prompts.
Also try to restart SQLAgent in this case.
|||Database Mail process shuts itself down after a certain period of inactivity. The default value is 10 minutes, which can be changed via Database Mail Configuration Wizard (can be found in Management Studio Object Explorer under Management | Database Mail) in "Configure System Parameters" dialog.
There are some other steps you can take to troubleshoot the issue, such as making sure your profile is set correctly. Here is a good starting point:
http://msdn2.microsoft.com/en-us/library/ms175887.aspx