1

I am trying to debug a CDO.Message.1 error '80040213', The transport failed to connect to the server.

So I am testing the connection to the SMTP server via telnet. After entering the DATA I am getting this response:

250 ok 1515609773 qp 24996

On a different SMTP server I am getting something like (from memory):

250 ok id=734E5544AB

I am expecting a message about the email being queued or accepted. Maybe all SMTP servers do this differently?

In any case the most important thing is the emails never arrive. Is that related to the Transport failed message? CDO sees the emails are not actually getting sent?

I am running telnet from a Windows Server 2008 Datacenter SP1 Azure VM.

Brad Mathews
  • 173
  • 2
  • 8
  • `250 ok` is a success code so that looks like it should deliver the message, or at least that it accepted the message for delivery. I think the first response shows an ID number and then maybe a size or something like that. The second just shows an ID number for the message. Are the receiving servers totally foreign and you can't access the logs? If you can get tot he logs I'd go there next. Also many servers will accept a message at the SMTP level and *then* send it through a spam filter and quarantine or drop it at that point. So getting your message accepted is still early on. – Todd Wilcox Jan 10 '18 at 19:17
  • I finally got tech support at HostGator to get me some log data. It looks like the From field is never set and the email is being sent, but is being refused by the POP server and bounced back. So in that case this seems to have nothing to do with the Transport Failed message. Am I reading that correctly? – Brad Mathews Jan 10 '18 at 22:32
  • Hard to say. If you have copies of the logs files it might help a lot to quote a relevant section in your question. – Todd Wilcox Jan 10 '18 at 22:38

1 Answers1

2

Ok I figured it out. The standard way to test and SMTP server via telnet that I found in three different places is WRONG!

They are not RFC 5322 compliant in that they do not set the From header. Without a From header, many email servers (like gmail) will bounce the email back as it is suspected spam. To "help" matters along Gmail will hide the bounce in the spam folder so you never get the first clue as to what's wrong.

Here is the right way to send an email via telnet

Simply put, you need to add from: name@yourdomain.com in the DATA. You can also add to: and subject:. I do not know if those are helpful or required, didn't test that.

Brad Mathews
  • 173
  • 2
  • 8