Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 SSIS and Import/Export (2005)
 SSIS Job failing (No obvious reason)

Author  Topic 

masterdineen
Aged Yak Warrior

550 Posts

Posted - 2011-06-23 : 04:33:46
Hello everyone.

I have a SSIS scheduled job that has been working for months and months. Now it has stopped with no obvious reason. I have mannualy fire it off from SSIS and it works fine. But when i fire the job off from the Scheduled agent job. It fails. i cannot see what the problem is. The SSIS packacge consists of a send mail task. With my work email address. ( to confirm the job is working ok ) and the destination email address. Now when i take out the destination email address. The job works fine from agents jobs. But when fired off manually from SSIS with the destination email address intact. Then it works fine.

the error i am getting in the history Log is

The job failed. The job was invoked by user mydomain\username1.
The last step to run was step 1 (step_name)
Executed as user mydomain\username2 The package execution failed.
The step failed.

We have not made any changes to domain accounts that are relevant to our sql server.

Any ideas please??????

Kind Regards

Rob

MCTS / MCITP certified

nigelrivett
Master Smack Fu Yak Hacker

3385 Posts

Posted - 2011-06-24 : 04:59:36
Put the send email in another step in the job - always good to isolate emails.

If you want ot find out what's wrond with the ssis task try running it using the same account as when scheduled. Might mean logging the user from the package.

==========================================
Cursors are useful if you don't know sql.
SSIS can be used in a similar way.
Beer is not cold and it isn't fizzy.
Go to Top of Page

masterdineen
Aged Yak Warrior

550 Posts

Posted - 2011-06-24 : 05:07:29
HOw would i do that. I only have one agent step to fire off a SSIS package that consists of one data flow, and one email task.

I have noticed that email addresses outside my company wont work when the agent job is fired off. but when i use an outside email address in my ssis package and then fire off from ssis. ITs works ok.

Go to Top of Page

nigelrivett
Master Smack Fu Yak Hacker

3385 Posts

Posted - 2011-06-24 : 05:35:20
Can't you use your external email address - it's not resolving the internal address.

Do you know howto add another step to a job? What are you doing if it fails - you should also be alerting on that.
Separate the dataflow from the email and put them in separate steps - the email is likely to change and be problematic and it's useful to be able to run a package without sending emails.


==========================================
Cursors are useful if you don't know sql.
SSIS can be used in a similar way.
Beer is not cold and it isn't fizzy.
Go to Top of Page

masterdineen
Aged Yak Warrior

550 Posts

Posted - 2011-06-24 : 06:45:48
The email task sends out a csv to a client of ours. so we do need the email task. This has been working for ages.
And now all of a sudden. Its so strange.
Go to Top of Page

masterdineen
Aged Yak Warrior

550 Posts

Posted - 2011-06-24 : 06:52:47
could you give me an example of how to seperate. Basically. I have one dataflow. and one email task
Go to Top of Page

nigelrivett
Master Smack Fu Yak Hacker

3385 Posts

Posted - 2011-06-24 : 07:02:22
>> Do you know howto add another step to a job?

Go to the agent and find the job - depends on how you added it but probably has the name of teh package.
right click on the job and you will see the steps and schedules - you can add another step after the one you are executing to send the email.

Presumably the client has an external email address so that's not a problem?


==========================================
Cursors are useful if you don't know sql.
SSIS can be used in a similar way.
Beer is not cold and it isn't fizzy.
Go to Top of Page

masterdineen
Aged Yak Warrior

550 Posts

Posted - 2011-06-24 : 07:12:47
For testing. I have disabled the dataflow task. So i only have the email task. When manually fire with both my work email address and external email address. It Fails. when i fire with only my work address. It works.
Go to Top of Page

masterdineen
Aged Yak Warrior

550 Posts

Posted - 2011-06-24 : 07:34:51
Hello there. I have changed the SMTP address and it has started working now. Its a bit of a windup. ITs working now.

thank you very much for your help. Its so annoying when something fails over and then its so hard to is what had caused it to happen.
Go to Top of Page
   

- Advertisement -