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 2008 Forums
 SQL Server Administration (2008)
 Nee to Force Job to Run Under My Login

Author  Topic 

jbates99
Constraint Violating Yak Guru

396 Posts

Posted - 2013-11-05 : 15:32:48
Hi everyone,

We run our SQL Agent service under a domain account reserved for that purpose.

However, I have created a new job which runs an SSIS package to send files to a secured ftp site (uses a 3rd party SFTP tool).

It's a long story but the scheduled job (SQL Agent) fails when it runs as a scheduled job. I briefly changed the Agent service to run under my domain account and the job then ran successfully.

** How can I force this job to execute under my domain account? **
Thanks for any ideas. Jack

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2013-11-05 : 15:37:19
You can use the Run As feature in the job step. You'll need to setup a credential (pointing to your account) and a proxy, and then modify the job step to use that proxy.

But why not just fix the permissions so that the domain account can run it?

Tara Kizer
SQL Server MVP since 2007
http://weblogs.sqlteam.com/tarad/
Go to Top of Page

jbates99
Constraint Violating Yak Guru

396 Posts

Posted - 2013-11-05 : 17:28:38
Thanks, Tara. Yes I knew about the proxy option.

And fixing the permissions for the windows service account is the best way to go.... I just don't know what it needs because that account as well as mine have sysadmin and local admin rights.

I'm using WinSCP tool for sending to a secured FTP site. The SSIS task which executes WinSCP fails when the job runs with Agent service set to the usual account. If I change the Agent service to logon as MY account, bounce the service.... then the job will run successfully from a schedule.

More info than you wanted I;m sure :-)
Go to Top of Page
   

- Advertisement -