Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Send Mail Task works perfectly within BIDS but does not work in SQL Agent Job. Expand / Collapse
Author
Message
Posted Wednesday, July 24, 2013 6:50 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Friday, August 16, 2013 5:29 AM
Points: 12, Visits: 119
Hi,
I have a SSIS Package with a Send Mail Task in it. This works perfectly within BIDS...I can get the desired email. However when I put this SSIS package in a SQL Agent Job, the Send Mail Tasks does not work.

I am getting the below error :

An error occurred with the following error message: "Failure sending mail. System.Net.WebException: Unable to connect to the remote server System.Net.Sockets.SocketException: An attempt was made to access a socket in a way forbidden by its access permissions 10.38.58.184:25"

What needs to be done to get my Send Mail Tasks to send the desired emails while executing as a SQL Agent Job?

Any and All help will be greatly appreciated...Thanks
Post #1477039
Posted Wednesday, July 24, 2013 9:12 AM
SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Saturday, August 16, 2014 9:15 AM
Points: 2,818, Visits: 2,557
If you set up a proxy with the appropriate mail server access and ran the SSIS package under the security context of the proxy that should work. You should be able to find a number of articles on setting up a Proxy for the SQL Agent to use when running SSIS packages.
Post #1477123
Posted Wednesday, July 24, 2013 9:19 AM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Thursday, May 15, 2014 5:11 PM
Points: 6,067, Visits: 5,283
Are you running the package in BIDS on the same machine that you are trying to run it on as a job.

I have seen local firewall differences as well as access control rules on the destination side that could yield this.

CEWII
Post #1477129
Posted Friday, July 26, 2013 7:14 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Friday, August 16, 2013 5:29 AM
Points: 12, Visits: 119
Hi,
Thank U Daniel and Elliott for your valuable input and suggestions.
This issue got reseloved. There were some permission issue with the Sql Server User Login.
So, after gievn permission by admin team this issue got resolved.

Regards,
Pinku Raj
Post #1477990
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse