Problem Sending Emails with BLAT

Posted on 2011-10-11
Medium Priority
Last Modified: 2013-11-30
Anyone familiar with the command line email program BLAT? We had it set up on our previous server (SBS 2003), and after installing it on the new one (2008), it refuses to work. I set it up with the following command:

blat -install exchange_server_name.united.local email@domain.com

Then, when I want to use the program, I call:

blat -body " body text” -s "subject" -to recipient  -from sender -attach “attachment”

This results in an error:
"The SMTP server does not like the sender name.
Have you set your mail address correctly?
Error: Connection to server was dropped."

I try -installing with any email address on our server, and this happens.
Question by:rvfowler2
LVL 23

Accepted Solution

TheCleaner earned 1500 total points
ID: 36949677
(NOTE:  The below isn't about SBS, I'm not familiar with how it changes things around, so take it for what it's worth)

I'm not familiar with BLAT, but it appears you aren't sending any authentication, so you might need to setup a relay connector and allow that IP address to send to the connector in order for it to work.

See here:


That is just the receive connector so don't think of "relay" as a bad word here.

You'll need to understand what you are doing though.  Best to create an additional IP address assigned to the Exchange server NIC, use that IP for the relay receive connector's "use these local IP addresses to receive mail".  Then in "Receive email from remote servers that have these IP addresses" put in the hosts IP addresses (like the BLAT server you are running this BLAT command on) there.

Hope that helps.  If you need further assistance let me know.

Expert Comment

ID: 36953401
This works on my 2008R2 server:

blat -body " body text”  -server SMTPmailservername -f sender  -to recipient -attach “attachment”
and make sure that unauthenticated SMTP is allowed to your SMTP relay (if you have one)

if you do not have SMTP relay server set-up then this will work (will not work on an exchange server): blat -body " body text”  -server SMTPmailservername -f sender  -to recipient -attach “attachment”

I found a 64-bit version of Blat that someone had tweaked a few months back but cannot locate it now. If all else fails, try to download a 64-bit version.

to test, cd to the folder with blat, create a test file with some content and do this:
type  | blat.exe ./test_text_file.txt -server SMTP_server -f from_address -to to_address -s "Subject Text here"

Author Closing Comment

ID: 36957130
As it turns out, you indirectly led me to the solution. After more research, I found that BLAT actually has parameters for authentication, so I used that method successfully.

Featured Post

Get your Disaster Recovery as a Service basics

Disaster Recovery as a Service is one go-to solution that revolutionizes DR planning. Implementing DRaaS could be an efficient process, easily accessible to non-DR experts. Learn about monitoring, testing, executing failovers and failbacks to ensure a "healthy" DR environment.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

On September 18, Experts Exchange launched the first installment of the Help Bell, a new feature for Premium Members, Team Accounts, and Qualified Experts. The Help Bell will serve as an additional tool to help teams increase question visibility.
How to effectively resolve the number one email related issue received by helpdesks.
The video tutorial explains the basics of the Exchange server Database Availability groups. The components of this video include: 1. Automatic Failover 2. Failover Clustering 3. Active Manager
This video demonstrates how to sync Microsoft Exchange Public Folders with smartphones using CodeTwo Exchange Sync and Exchange ActiveSync. To learn more about CodeTwo Exchange Sync and download the free trial, go to: http://www.codetwo.com/excha…
Suggested Courses

850 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question