Solved

SSIS Package containing XCopy will not run as Job in Mgmt Studio

Posted on 2008-06-22
6
1,111 Views
Last Modified: 2012-05-05
I have an SSIS package which runs fine thru BIDS, as well as when I log on to Mgmt Studio and Execute it manually as a Package.  However when set up as a Job, it doesn't seem to run, although it does not fail.  It just continues to display "Executing."  Research thus far seems to indicate that it is related to the particular step within the package which contains a literal filename path (I'm performing an XCopy).  I've tried all different encryption options within the package security settings but it still doesn't run as a job.  Does anyone know if I need to set up a Proxy Account, and if so, can you explain exactly how to do this?  I am more of a developer than a DBA, but I'm hoping I can at least get enough information to work with our DBA toward a resolution.
0
Comment
Question by:VDanner
  • 3
  • 2
6 Comments
 
LVL 13

Expert Comment

by:rickchild
ID: 21841762
What account is the SQL Service (MSSQLSERVER) and the SQL Agent running as?
Are they set to the default of something like "NT Network Service".

You could try running thes services as a user with permission to access the file path.
0
 
LVL 6

Expert Comment

by:DocCan11
ID: 21841855
ok.. this is actually a three step process..

1) I would create a user account that has permission to the directories in question..
2) go in to SQL 2005 Managment Studio(MS), under security, credentials right click and choose new credential.. fill in a name and then link to the user account you created in step 1.. Fill in the password..
3)  in SQL MS click on sql server agent, proxies, Operating System. Right click and and choose new proxy, fill in a name and point to the credential you created in step 2..

now all you need to do is allow the user who is running the job access to the proxy by clicking on principals and choosing who can use it..

This will give your code the needed permissions to run an OS step.. by linking it up to the credential..

If you tell me how you run the step I will try and help you with that as well
0
 

Author Comment

by:VDanner
ID: 21842170
DocCan11 - thanks for your response.  Remember I'm not much on security so here are my questions:
Since I have access to this path can I not just use my Windows user account?  I'm hoping that I can although the way I have attempted it thus far hasn't worked.  Not sure how to create a new user account.
Whatever account I do use in Step 2, do I precede this with the DOMAIN?  ie DOMAIN\User?
In Step 3 I also added option to Run SSIS packages, because when editing the Job, in the Step page, I can change from  "Run As SQL Server Agent" to "Run As proxyname".  
Do I need to change anything else within the Job properties, such as name of owner?
0
Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

 
LVL 6

Accepted Solution

by:
DocCan11 earned 500 total points
ID: 21842469
If you are not worried about security you can use your own account.. and it should be a domain account (although you can use a local account depending on what the package does).. you would enter it in the format domain\user.
 
you should not need to change anything else .. but if you run into problems we can deal with that..
0
 

Author Comment

by:VDanner
ID: 21850680
DocCan11: In working more with our DBA, we tried another approach.  The troublesome task within the package seemed to be the one running an executable bat file.  The bat file is on the same machine as SQL Server.  When building the SSIS package on MY machine, I included the full UNC pathname to the file, tested it, then deployed it to the Server machine's SSIS Package Store.  It ran fine as a package, but not as a Job.  Our DBA tried redoing the package, modifying the bat file pathname to just the drive letter and filename, then saving out to the file system of the server machine.  It now runs as a job!
I don't understand why the UNC approach would not work, but at least we have the problem fixed.
Thank you for your time and thoughts on a resolution.
0
 

Author Closing Comment

by:VDanner
ID: 31469564
I'm not sure if your approach would have worked since I needed to go with what our DBA recommended, but thanks very much for your help.
0

Featured Post

Backup Your Microsoft Windows Server®

Backup all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Dataset not reading table data 12 46
SQL Server 208R2 not recognizing DBF file in linked Server 11 51
Need help creating a stored procedure 4 56
How to check data in sql table 11 45
by Mark Wills Attending one of Rob Farley's seminars the other day, I heard the phrase "The Accidental DBA" and fell in love with it. It got me thinking about the plight of the newcomer to SQL Server...  So if you are the accidental DBA, or, simp…
In this article we will get to know that how can we recover deleted data if it happens accidently. We really can recover deleted rows if we know the time when data is deleted by using the transaction log.
This tutorial gives a high-level tour of the interface of Marketo (a marketing automation tool to help businesses track and engage prospective customers and drive them to purchase). You will see the main areas including Marketing Activities, Design …
In this video I am going to show you how to back up and restore Office 365 mailboxes using CodeTwo Backup for Office 365. Learn more about the tool used in this video here: http://www.codetwo.com/backup-for-office-365/ (http://www.codetwo.com/ba…

911 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

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now