Server 2008 - Task Scheduler - Send an E-mail fails
When ever weset an action to send an E-mail in theServer 2008 Task Scheduler GUI, we get a"Task failed" result of"Cannot modify or delete an object that was not added using the COM+ AdminSDK (0x8004020D) once the task gets to that step.I have tried creating tasks that do nothing but try and send an email using the new functionality of the Task Manager and itfails with the exact same error, So I have narrowedit down to the emailaction being the culprit. As soon as I remove it from the other tasks, everything works as planned.Is there a fix for this? Is there a permission I need to set somewhere? It seemsthat some people have tried runningthe task as the "Network Service" and it works, but I have had no such luck yet.
September 5th, 2008 7:15pm

Hi, If a task attempts to send an e-mail, but the e-mail doesn't get sent correctly, first make sure that the settings for the e-mail action on the task are set correctly. The e-mail action must have a valid value for the SMTP server, To, and From settings. For more information about these settings, please refer to the following article: Actions http://technet.microsoft.com/en-us/library/cc722129.aspx Make sure the SMTP server that sends the e-mail is setup correctly. E-mail is sent using NTLM authentication for Windows SMTP servers, which means that the security credentials used for running the task must also have privileges on the SMTP server to send e-mail. If the SMTP server is a non-Windows based server, then the e-mail will be sent if the server allows anonymous access. For information about setting up the SMTP server, please see the following article: SMTP Server Setup http://www.microsoft.com/technet/prodtechnol/WindowsServer2003/Library/IIS/e4cf06f5-9a36-474b-ba78-3f287a2b88f2.mspx?mfr=true And for information about managing SMTP server settings, please see the following article: SMTP Administration http://technet.microsoft.com/en-us/library/cc758258.aspx Hope it helps. Tim Quan - MSFT
Free Windows Admin Tool Kit Click here and download it now
September 8th, 2008 11:35am

I'm using a third party email server and having problems. This is what I see in the logs: "2009-04-06 21:04:58 127.0.0.1 SMTP-IN 127.0.0.1 460 AUTH AUTH+LOGIN 334+RANDOMSTRING COMPUTERNAME 18 12 " I'm allowing relaying for 127.0.0.1 but have also enabled windows authentication in addition to it's built in authentication since it looks like Task Manager is attempting to authenticate. But I have no idea what the random character string is in the logs, is that meant to be the username? Can I get it not to authenticate?
April 6th, 2009 12:41pm

I didn't want to make the server a domain member (What I understood needed to happen to get authentication working) and I scoured to the edge of the earth to try to make it work with no avail. Workaround, I simply installed bmail command line mailing utility (Free) and scheduled task to run an application.bmail script is like this:bmail -s smtpserver.tld -t recipent@contsco.com -f sender@domain.com -h -a "Alert Notice Subject" -b "xyz alert has been triggered. Microsoft task alert's via email lick balls." Thanks,-Brian Brian J. Brandon, CCNP Zuit Security Research and Defense Http://www.Zuit.net
Free Windows Admin Tool Kit Click here and download it now
February 9th, 2010 3:12pm

Brian thank you for this alternative, I have been attempting to get the Task Scheduler to send an email to a distribution group for weeks, and the task kept failing for one reason or the other. Now, through bmail, the process is much simplified and if the event viewer triggers an error for what I'm watching I get the email alert. I'm not sure why the task scheduler method needs to be so complex, but I appreciate this alternative process.
February 16th, 2011 1:50am

(...) If the SMTP server is a non-Windows based server, then the e-mail will be sent if the server allows anonymous access. (...) Tim Quan - MSFT Hi everybody. I got *veeeery* late into this subject, but unfortunately it seems to me that task scheduler always try to authenticate to the smtp server, even if it is not an MS one. See the log below and notice the bold line: "TCPIP" 11072 "2011-03-16 10:25:06.845" "TCPConnection - Posting AcceptEx on 0.0.0.0:25" "DEBUG" 11072 "2011-03-16 10:25:06.860" "Creating session 51" "SMTPD" 11072 51 "2011-03-16 10:25:06.860" "127.0.0.1" "SENT: 220 ******** ESMTP" "SMTPD" 10896 51 "2011-03-16 10:25:06.860" "127.0.0.1" "RECEIVED: EHLO ********" "SMTPD" 10896 51 "2011-03-16 10:25:06.860" "127.0.0.1" "SENT: 250-********[nl]250-SIZE 20480000[nl]250 AUTH LOGIN" "SMTPD" 10896 51 "2011-03-16 10:25:06.860" "127.0.0.1" "RECEIVED: AUTH LOGIN" "SMTPD" 10896 51 "2011-03-16 10:25:06.860" "127.0.0.1" "SENT: 334 VXNlcm5hbWU6" "DEBUG" 10896 "2011-03-16 10:25:06.876" "Ending session 51" So my question is: is there a way to prevent this login try? Thanks in advance and forgive my poor English.
Free Windows Admin Tool Kit Click here and download it now
March 16th, 2011 6:00pm

This continues to come up in multiple forums from time-to-time so I thought I would share my findings. Server 2008 R2 domain - Exchange 2010 SP1 update 5. I was trying, for several days, to figure out exactly what was causing Task Scheduler to fail to send emails. After following a few different forum trails, and performing some trial and error testing, I've come to the following conclusion - Unless you make changes to the administrator account (adminSD holder object) you CANNOT run the email-sending task using the domain administrator account or have the domain administrator's email address in the 'From' field of the email message. That second part was the one that had me stumped. If you try to run the task using the administrator account you will get an MSExchangeTransport 1020 event in your Exchange servers' application log complaining that the domain\administrator is not authorized to use this server. If you have the domain administrators' email address in the 'From' field of the email message you just get a very generic 'Run Failure' with 'Error Value: 2147746321' in Task Scheduler and nothing on your Exchange server. Once you use a different user for both you can use Task Scheduler to send emails internally and externally till your heart's content. I'm currently using it to send hourly emails to my work address as a sort of po' man's Exchange check.
September 10th, 2011 10:51pm

This trace gives the key. The task scheduler always tries to authenticate. I'd be quite interested in a way to change that behaviour, but have a work around in an Exch 2010 SP1/MS AD setting 1. The receive connector in Exch 2010 needs to be set to offer Windows Integrated authentication 2. The account used to run the task needs to be mail enabled 3. The FROM address of the email being sent needs to be for that user account 4. The user account needs appropriate rights and permissions to run the task on the machine it's running on 5. The UPN of the user acct should match the email address. (Haven't fully tested this one, but in the test case i used it was set that way and I've seen that requirement a lot.) 6. The acocunt does NOT need to be an admin account in the domain or anything other than Domain User in the domain. But i heartily agree, if someone can find a way to turn off the Task Sceduler trying to authenticate and just use anonymous this would be a LOT easier.
Free Windows Admin Tool Kit Click here and download it now
September 21st, 2011 12:58am

Please add me to the list of people waiting for a fix. I have two mail servers and neither is a "Microsoft" product. I cannot get it to work either. It seems kind of silly this feature would only work with Microsoft Exchange, and very simple to make it work with thousandsd of email servers out there using industry standards.
November 14th, 2011 2:24pm

Best solution that worked best for me is to install SMTP on a non windows 2k3 box and in the properties of SMTP -> relay restriction select all except below. And it is working fine for me.
Free Windows Admin Tool Kit Click here and download it now
December 9th, 2011 2:53am

I tried to use Bmail but it does not support authentication, so I've used the SMTPMailSender (http://www.snapfiles.com/get/smtpmailsender.html) like this: smtpmailsender.exe -t <to_email> -f <from_email> -s "'subject" -b "message_body" -username <your_email_account_username> -password <your_email_account_passwd> -send The line above goes to Task Scheduler either directly from the Task Scheduler menu -> Create Basic Task ... or from Event Viewer -> Attach Task to This Event .... . Select "Run a program" as the action for the task to perform. Thanks, Adrian
June 12th, 2012 4:12am

Hy AdyCan, I tried setting the SMTPmailsender according to your specifications. Works correctly if I run a .bat file, but does not work if you start it from the task scheduler (same file). I tried to start .SMTPmailsender.exe from task scheduler, assigning additional parameters, but it did not work. Any suggestions? Thanks, Paulo Pereira
Free Windows Admin Tool Kit Click here and download it now
June 12th, 2012 7:29am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics