0

I have made some ssis packages dtsx into my local system, and wanted to execute using a powershell script. I tried this code

dtexec /File c:\ssisExample.dts

This resulted in an error of

unable to load the package as XML because of package does not have a valid XML format

2
  • Which version of SQL Server Integration Services are you running on your machine? Cloud you please add the about first 20-30 lines of the source text of your package? There is a difference in running your package from Visual Studio and have Integration Services run it. Commented Apr 6, 2017 at 14:27
  • SQL Server Integration Services 13.0 . Ran through a error called Access denied now. Commented Apr 6, 2017 at 14:39

4 Answers 4

4

First Scenario: Directly executing a file using command in PowerShell

1) Dtexec /FILE ‘\FILE_PATH_NAME\ssisPackage.dtsx’

Errors recorded: 
1) The XML is not in correct format/Unable to load the packages
2) Specified File path is not proper
3) At least one of the DTS, SQL, ISServer or File options must be specified

Resolutions

1. Make sure you put path in single quotes as dtexec /FILE ‘FILE_PATH/ssisPackage.dtsx’. Copy the path from the properties under SSIS package which is created in Visual Studio.

2. Give access to SSIS packages to be remotely acess from a third party. For that, run Dcomcnfg.exe (requires Local Administrator)

a) Go to Component Services->Computers->DCOM Config->Microsoft SQL Server Integration Services 13.0 (whatever version is installed).

b) Right click ->properties->Security tab->Launch and Activation permission -> Check remote launch and remote activation

c) Same for Access Permission

3. Make sure that system has Microsoft.SqlServer.ManagedDTS package

a) To check that try going to folder In run command C:\Windows\assembly\gac_msil

b) Move to folder name Microsoft.SqlServer.ManagedDTS and check for the package versionr

c) Once done try giving access to these DTS packages

d) Run Dcomcnfg.exe (requires Local Administrator)

e) Go to Component Services->DCOM Config->MsDtsServer100

f) Right click to properties and onto the security tab press Edit for Launch and Activation Permission. Allow for Remote Launch and Remote Activation. Close

g) Press Edit for Access Permission -> Allow Remote Access

Sign up to request clarification or add additional context in comments.

Comments

0

Your package should have the .dtsx file extension. Try this

dtexec /File c:\ssisExample.dtsx

2 Comments

Are you sure the package is at that file path? Does the package run in the debugger in visual studio?
Yes it does..And the package executes too
0

/De[crypt] password ! If you saved your package on local file system and used the wizard to create them MS tools usually encrypt the password on file. make sure decrypt the password with /de argument

Comments

0

You should try this it works for me.

EXEC xp_cmdshell 'dtexec /f "c:\ssisExample.dtsx"'

2 Comments

EXEC : The term 'EXEC' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
This would be for if you wanted to run it from a T-SQL script.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.