将 SSIS 包从服务器 A 部署到服务器 B

Deploying SSIS Package from Server A to Server B

我正在使用 VS 2017 SSDT 15.9.20 创建一个 SSIS 包。该包最初是在安装了 SSDT 的服务器 A 中创建的,SQL 服务器驻留在服务器 A 中。所以我可以在服务器 A 中创建该包。我在服务器 A 中创建了一个 SQL 作业,并且直接链接到 运行 DTSX 文件而不部署它。

我的包裹的作用:

在服务器 A 中,我的包将读取位置 C:\Users\xxx\Documents\myproj\excelfile.xls 中的 excel 并将在 C:\Users\xxx\Documents\myproj\files\ 文件夹中创建 excel 个工作表。

部署:

现在我想将这个包部署到服务器 B。我的包将在 \ServerB\S:\Documents\myproj\excelfile.xls 位置读取 excel 并将在 \ServerB\S:\Documents\myproj\files\ 文件夹中创建 excel 个工作表。

我的问题:

  1. 我应该部署我的项目来创建 dtsx 文件吗?我的项目文件夹中已经有一个 dtsx 文件。我不能只将该文件移动到服务器 B 并更改连接字符串和路径吗?那样行得通吗?

  2. 服务器 A 中的 SSIS 部署工具对我不起作用。它无法识别目标 servers.How 可以简化部署吗?如何更改目标路径?

  3. 服务器 A 安装了 SSDT,并且 SQL 数据库驻留在同一台服务器上。但是目标服务器B是数据库服务器,里面没有SSDT。我将在服务器 B 的 SQL 服务器中安排一个作业,该作业将调用我的 dtsx 包并执行它。

我是 SSIS 新手。所以请不要关闭这个问题,如果有人能帮助我解决这些问题,那就太好了。谢谢!

不知道SQL的版本,我会给出两个答案:

Should I deploy my project to create dtsx file? There is already a dtsx file inside my project folder. Can I not just move that file to server B and change the connection string and paths? Will it work that way?

低于 SQL 2012 的版本: 将项目中的 dtsx 文件复制到目标服务器上的文件夹中。可以在 SQL 代理作业的配置中或通过使用包配置更改连接字符串:

https://docs.microsoft.com/en-us/sql/integration-services/lesson-5-add-ssis-package-configurations-for-the-package-deployment-model?view=sql-server-ver15

更高版本 SQL 2012: 在目标服务器上创建 ssis 目录:

https://docs.microsoft.com/en-us/sql/integration-services/create-the-ssis-catalog?view=sql-server-2014

右击项目,使用向导部署到目标服务器。可以在 SQL Agent 中修改连接字符串,如上所述,或者您可以使用参数:

https://docs.microsoft.com/en-us/sql/integration-services/lesson-6-using-parameters-with-the-project-deployment-model-in-ssis?view=sql-server-ver15

起初我觉得后者工作量更大,但它有很多好处,是首选的做事方式

SSIS deployent tool does not work for me from server A. It does not identify the destination servers.How can be deployment made easy? How can I change the destination paths?

按照上面提到的任何一种部署方法。打包部署(将文件复制到文件夹)在更高版本中仍然有效,但管理起来不太容易,为您做的事情也更少比如保护配置和设置日志记录。

Server A has both SSDT installed and SQL database resides in same server. But the target server B is a database server and does not have SSDT in it. I will schedule a job in SQL server of server B that will call my dtsx package and execute it.

SSDT 与 SSIS 无关,但 Integration Services 有。SSDT 是一种开发人员工具,实际上只应安装在开发人员机器上以用于创建包和测试。最好不要在服务器上安装它,因为它鼓励在那里进行开发,并让开发人员像登录他们的笔记本电脑一样登录服务器。 Integration Services 是 SQL Server 自带的服务,用于执行包。如果你想从 SQL Agent 执行包,你需要将此服务添加到实例中。 link 对此进行了解释并提供了有关在本地安装 SSDT 的指导:

https://docs.microsoft.com/en-us/sql/integration-services/install-windows/install-integration-services?view=sql-server-ver15