0

I have built an SSIS Packaage that imports data on a daily basis.

i have tested it in BIDS and it runs fine, i have deployed it to the the SSIS server and it runs fine, but when i schedule it to run as a job it Errors out. i get the errors below. i've added the srvSQLagent account to the the correct group to have access to the folder that causing the problem.. am i missing something stupid here?

===================================================================

Date 03/07/2013 14:55:06 Log Job History (Import SN2 Data)

Step ID 1 Server STX-RPT Job Name Import SN2 Data Step Name Run Import Package Duration 00:00:09 Sql Severity 0 Sql Message ID 0 Operator Emailed
Operator Net sent
Operator Paged
Retries Attempted 0

Message Executed as user: INT\srvSQLagent. Microsoft (R) SQL Server Execute Package Utility Version 10.50.1600.1 for 32-bit Copyright (C) Microsoft Corporation 2010. All rights reserved.
Started: 14:55:06
Error: 2013-07-03 14:55:15.69
Code: 0xC001401E
Source: Servicenet Data Import Connection manager "Downloaded"
Description: The file name "\\FILE\Groups\ISG\England\Servicenet Data\Downloaded" specified in the connection was not valid. End Error
Error: 2013-07-03 14:55:15.69
Code: 0xC0202070
Source: Servicenet Data Import Connection manager "Downloaded"
Description: The file name property is not valid. The file name is a device or contains invalid characters. End Error
Error: 2013-07-03 14:55:15.69
Code: 0xC0029163
Source: File System Task File System Task
Description: File or directory "\\FILE\Groups\ISG\England\Servicenet Data\Downloaded" represented by connection "Downloaded" does not exist. End Error
DTExec: The package execution returned DTSER_FAILURE (1).
Started: 14:55:06
Finished: 14:55:15
Elapsed: 9 seconds.
The package execution failed.
The step failed.

4

3 回答 3

0

这绝对是文件夹权限问题。

请给每个人适当的权利。

Alpesh Dhori 专业软件

于 2013-07-29T12:33:47.797 回答
0

我想下一个解决方案会帮助你:

假设我们需要 使用 SSIS 通过 SQL 代理作业和非管理员代理帐户 MyDomain\TestAccount写入\\serv\share\dir1..\dirN\targetDir\somefile.txt

1) MyDomain\TestAccount 需要读/写权限才能共享\\serv\share

2) MyDomain\TestAccount 至少需要所有文件夹的 FILE_READ_DATA 权限(sharedir1,.. dirN

3) MyDomain\TestAccount 需要文件夹targetDir的 CHANGE 权限 + FILE_DELETE_CHILD 权限

(cacls 应显示此权限,如下所示:

DELETE
READ_CONTROL
SYNCHRONIZE
FILE_GENERIC_READ
FILE_GENERIC_WRITE
FILE_GENERIC_EXECUTE
FILE_READ_DATA
FILE_WRITE_DATA
FILE_APPEND_DATA
FILE_READ_EA
FILE_WRITE_EA
FILE_EXECUTE
FILE_DELETE_CHILD
FILE_READ_ATTRIBUTES
FILE_WRITE_ATTRIBUTES

)

当然,targetDir的全部权限就足够了。

如果targetDir没有 FILE_DELETE_CHILD 权限,那么我们会在 SSIS 中看到平面文件连接的这种奇怪行为。用户 MyDomain\TestAccount 可以使用标准 Windows 工具对文件somefile.txt执行任何操作(读取、写入、删除)。但 SSIS 作业无法覆盖此文件并失败。

于 2015-01-26T14:12:31.940 回答
0

该问题源于使用文件系统任务清除所有文件的文件夹。

我从来没有找到问题的根源,我只是找到了一种删除所需文件的不同方法。

于 2013-07-04T13:57:13.283 回答