none
Mail Queued after a SqlAgent Error RRS feed

  • Question

  • Hey guys in our company we have an issue with out Mail Database Procedure since 28th of August all the mails that we are trying to send from a certain email adress are not delivering to our destinations...

    In Sysmail_log i look the last day wich the issue occurs this logs...

    	log_id	event_type	log_date	description
    201122	46667	error	2018-08-25 01:04:23.540	The mail could not be sent to the recipients because of the mail server failure. (Sending Mail using Account 1 (2018-08-25T01:04:23). Exception Message: Cannot send mails to mail server. (The operation has timed out.).
    )
    201123	46666	error	2018-08-25 01:04:22.887	The mail could not be sent to the recipients because of the mail server failure. (Sending Mail using Account 1 (2018-08-25T01:04:22). Exception Message: Cannot send mails to mail server. (The operation has timed out.).
    )
    201124	46665	error	2018-08-25 01:01:43.190	The mail could not be sent to the recipients because of the mail server failure. (Sending Mail using Account 1 (2018-08-25T01:01:43). Exception Message: Cannot send mails to mail server. (The operation has timed out.).
    )
    201125	46664	error	2018-08-25 01:01:42.490	The mail could not be sent to the recipients because of the mail server failure. (Sending Mail using Account 1 (2018-08-25T01:01:42). Exception Message: Cannot send mails to mail server. (The operation has timed out.).
    )
    201126	46663	information	2018-08-25 01:00:01.947	DatabaseMail process is started

    And in our event log are those logs...

    La configuración de permisos application-specific no concede el permiso Activation Local para la aplicación de servidor COM con CLSID 
    {FDC3723D-1588-4BA3-92D4-42C430735D7D}
     y APPID 
    {83B33982-693D-4824-B42E-7196AE61BB05}
     al usuario NT SERVICE\SQLAgent con SID (S-1-5-80-1038670970-4243704951-95084249-2064790357-313424594) en la dirección LocalHost (Using LRPC) que se ejecuta en el contenedor de aplicaciones con SID Unavailable (Unavailable). Este permiso de seguridad se puede modificar mediante la herramienta administrativa Servicios de componentes.

    Sorry about the spanish but i am a spanish native user...

    Searching in the forum i found a guy saying that the issue is solve runnin sp_CONFIGURE with those settings...

    sp_CONFIGURE 'show advanced', 1
    GO
    RECONFIGURE
    GO
    sp_CONFIGURE 'Database Mail XPs', 1
    GO
    RECONFIGURE
    GO

    Can someone help me plz?? We are desperate!!

    Thanks in advance!!

    Wednesday, September 5, 2018 7:36 PM

Answers

  • Stop that job and see if the mails go out.

    A Fan of SSIS, SSRS and SSAS

    • Marked as answer by Mariano D Thursday, September 6, 2018 1:53 PM
    Thursday, September 6, 2018 1:30 PM

All replies

  • Are you using msdb.dbo.sp_send_dbmail to send the emails? If yes, try to send a test email and see if it works.

    A Fan of SSIS, SSRS and SSAS

    Wednesday, September 5, 2018 8:12 PM
  • Yes we use that stored procedure and yes we try to do a test with the email that are doing the issue and all are put in the sysmail_unsentitems view... I mean all the mails are in a queue status...

    This mail are working just fine because i send mails from another platform and the mails are deliveying just fine.

    Thursday, September 6, 2018 11:59 AM
  • Did you try to send a test mail from SSMS?

    A Fan of SSIS, SSRS and SSAS

    Thursday, September 6, 2018 12:54 PM
  • What is SSMS?
    Thursday, September 6, 2018 1:01 PM
  • SQL Server Management Studio

    Or you can send a test mail through Database Mail under Management in SSMS.


    A Fan of SSIS, SSRS and SSAS


    • Edited by Guoxiong Thursday, September 6, 2018 1:11 PM
    Thursday, September 6, 2018 1:07 PM
  • I try send by DatabaseMail and by Sql Server Management Studio and the 2 of them are in queue status

    Right now im trying to stop the sysmail by using this sp...

    EXEC msdb.dbo.sysmail_stop_sp;

    But it doesnt seem to stop the service...

    Did i need to shutdown the server where the database are running then try to see if the

    agent are working again??


    Thursday, September 6, 2018 1:24 PM
  • Is your SQL job still running to try to send mails? If yes, you can stop that job first and see what happens. I am wondering your mail queue has many mails waiting to deliver.

    A Fan of SSIS, SSRS and SSAS

    Thursday, September 6, 2018 1:27 PM
  • Yes the job are still running and right now i have 200 mails waiting to be delivered since 25th August
    Thursday, September 6, 2018 1:29 PM
  • Stop that job and see if the mails go out.

    A Fan of SSIS, SSRS and SSAS

    • Marked as answer by Mariano D Thursday, September 6, 2018 1:53 PM
    Thursday, September 6, 2018 1:30 PM
  • I restart the database then all the mails start sending it.. 

    So i think its solved!

    Thanks for your time!

    Thursday, September 6, 2018 1:53 PM