I am trying to build an SSIS package which has to send an email to certain users. I took a SQL Mail Task from the toolbox and dropped it in my package.
There weren't many settings that were required it seems. The main setting that was SMTP Server Setting in the SMTP connection manager, I picked it from my outlook (exchange server), and put it in the SMTP Connection Manager.
When I test this particular SQL Mail task, it fails with the following error:
[Send Mail Task] Error: An error occurred with the following error message: "Failure sending mail. System.IO.IOException: Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host. System.Net.Sockets.SocketException: An existing connection was forcibly closed by the remote host".
Now I cannot figure out if this error is due to incorrect SMTP server Connection settings or anything else. Any help in this regard will be greatly appreciated.
There wasn't much code as such for me to put here or any screenshot. Still if there is anything in particular that requires to be checked or seen, please let me know and I will put it here.
Thanks in advance.