question

basit 1 avatar image
basit 1 asked

Database Mail is not working

Hi All, i am facing an issue with Database mail. The Database mail.exe is not running automatically and mail are not sending. when we manually start the exe and we get the below error > Exception Information > =================== Exception Type: System.NullReferenceException > Message: Object reference not set to > an instance of an object. Data: > System.Collections.ListDictionaryInternal > TargetSite: > Microsoft.SqlServer.Management.SqlIMail.Server.Objects.Account > GetAccount(Int32) HelpLink: NULL > Source: DatabaseMailEngine > StackTrace Information > =================== at Microsoft.SqlServer.Management.SqlIMail.Server.DataAccess.DataAccessAdapter.GetAccount(Int32 > accountID) at > Microsoft.SqlServer.Management.SqlIMail.Server.Controller.CommandFactory.CreateSendMailCommand > (DBSession dbSession) at > Microsoft.SqlServer.Management.SqlIMail.Server.Controller. > CommandFactory.CreateCommand(DBSession > dbSession) at > Microsoft.SqlServer.Management.SqlIMail.Server.Controller.CommandRunner.Run(DBSession > db) at > Microsoft.SqlServer.Management.SqlIMail.IMailProcess.ThreadCallBack.MailOperation(Object > o) Can you please let me know why i am getting this error. Thanks Basit
dbmail
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
Kev Riley avatar image
Kev Riley answered
Try recreating the mail profiles and accounts. Make sure the service account running SQL agent has the correct permissions, as per: http://ask.sqlservercentral.com/questions/50863/database-mail-does-not-work-for-one-sql-instance-r.html
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.