1
votes

I have build an SSIS package which is working well within BIDS. The package runs successfully.

I'm now trying to execute the same package, with the same config from the command line, but it fails to acquire a connection (error 0xC0208452 : DTS_E_ADODESTFAILEDTOACQUIRECONNECTION).

The failing connection is a ADO.Net connection to an access file that holds all failures (as I said, directly within BIDS, it works).

I use the following command line (in a .cmd file). The X86 flag is set as I'm also using a connection to an Excel file:

@echo off
set dtexec=%programfiles%\Microsoft SQL Server\100\DTS\Binn\dtexec.exe
"%dtexec%" /X86 /f "myPackage.dtsx" 

The output is :

Error: 2011-12-05 09:47:38.94
   Code: 0xC0208452
   Source: Output Errors to access file [162]
   Description: ADO NET Destination has failed to acquire the connection {19CC1EA2-BD93-4006-919E-39A80E828BB1}. The connection may have been corrupted.
End Error

The connection string used for this connection is :

Data Source=c:\path\to\errors.mdb;Provider=Microsoft.Jet.OLEDB.4.0

So the default mode for sharing connection is applied (16 : ShareDenyNode).

Finally, my platform is :

  • W2K8 R2 x64
  • SQL 2K8 R2 x64

I don't see what's going wrong with this command line. I'd appreciate some help.

PS: just in case, I tried running as administrator, but the behavior is identical.

[Edit] Don't know if it can help, but here is the error log when using /ConsoleLog flag :

Log:
     Name: Diagnostic
     Computer: mycomputer
     Operator: domain\me
     Source Name: Jet Errors
     Source GUID: {19CC1EA2-BD93-4006-919E-39A80E828BB1}
     Execution GUID: {90BCE5BA-CF8B-49FC-8275-1F1FF70720CB}
     Message: ExternalRequest_pre: The object is ready to make the following external request: 'IDbConnection.Open(ConnectionType: System.Data.OleDb.OleDbConnection,
 System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
ConnectionString: Data Source="c:\Path\to\errors.mdb";Provider=Microsoft.Jet.OLEDB.4.0;)'.
     Start Time: 2011-12-05 09:58:57
     End Time: 2011-12-05 09:58:57
End Log
Log:
     Name: Diagnostic
     Computer: mycomputer
     Operator: domain\me
     Source Name: Jet Errors
     Source GUID: {19CC1EA2-BD93-4006-919E-39A80E828BB1}
     Execution GUID: {90BCE5BA-CF8B-49FC-8275-1F1FF70720CB}
     Message: ExternalRequest_post: 'IDbConnection.Open failed'. The external request has completed.
     Start Time: 2011-12-05 09:58:57
     End Time: 2011-12-05 09:58:57
End Log
Log:
     Name: OnError
     Computer: mycomputer
     Operator: domain\me
     Source Name: Categories
     Source GUID: {6DD5D6E3-2256-43D5-84B8-E9C27E02694B}
     Execution GUID: {90BCE5BA-CF8B-49FC-8275-1F1FF70720CB}
     Message: ADO NET Destination has failed to acquire the connection {19CC1EA2-BD93-4006-919E-39A80E828BB1}. The connection may have been corrupted.

     Start Time: 2011-12-05 09:58:57
     End Time: 2011-12-05 09:58:57
End Log
Error: 2011-12-05 09:58:57.62
   Code: 0xC0208452
   Source: Categories To Categories Errors [162]
   Description: ADO NET Destination has failed to acquire the connection {19CC1EA2-BD93-4006-919E-39A80E828BB1}. The connection may have been corrupted.
End Error
Log:
     Name: OnError
     Computer: mycomputer
     Operator: domain\me
     Source Name: Categories
     Source GUID: {6DD5D6E3-2256-43D5-84B8-E9C27E02694B}
     Execution GUID: {90BCE5BA-CF8B-49FC-8275-1F1FF70720CB}
     Message: component "To Categories Errors" (162) failed validation and returned error code 0xC0208452.

     Start Time: 2011-12-05 09:58:57
     End Time: 2011-12-05 09:58:57
End Log
Error: 2011-12-05 09:58:57.64
   Code: 0xC0047017
   Source: Categories SSIS.Pipeline
   Description: component "To Categories Errors" (162) failed validation and returned error code 0xC0208452.
End Error

And here is the definition of the connection from the dtsx file itself :

<DTS:ConnectionManager>
    <DTS:Property DTS:Name="DelayValidation">0</DTS:Property>
    <DTS:Property DTS:Name="ObjectName">Jet Errors</DTS:Property>
    <DTS:Property DTS:Name="DTSID">{19CC1EA2-BD93-4006-919E-39A80E828BB1}</DTS:Property>
    <DTS:Property DTS:Name="Description"></DTS:Property>
    <DTS:Property DTS:Name="CreationName">ADO.NET:System.Data.OleDb.OleDbConnection, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</DTS:Property>
    <DTS:ObjectData>
        <DTS:ConnectionManager>
            <DTS:Property DTS:Name="Retain">0</DTS:Property>
            <DTS:Password DTS:Name="Password" Sensitive="1" Encrypted="1">AQAAANCMnd8BFdERjHoAwE/Cl+sBAAAAeUySei4110aSwp/Lg9Ry2wAAAAAIAAAARABUAFMAAAADZgAAwAAAABAAAABIrrL+3ppbrbI4ELkWjVMvAAAAAASAAACgAAAAEAAAAMgk6OFh+lWGPpsFZ0dK9k8IAAAA1HCWmIm7dIsUAAAAjjx5q2XUdjp2o+FxWAaPCEgv94M</DTS:Password>
            <DTS:Property DTS:Name="ConnectionString">Data Source=c:\Path\To\errors.mdb;Provider=Microsoft.Jet.OLEDB.4.0;</DTS:Property>
        </DTS:ConnectionManager>
    </DTS:ObjectData>
</DTS:ConnectionManager>
1

1 Answers

1
votes

Some peoples gave me the answer on this Microsoft forum thread.

I have to use the 32 bit version of DTEXEC instead of the 64 bits version, even if I set the X86 flag.

My batch file is now :

@echo off
set dtexec=%programfiles(x86)%\Microsoft SQL Server\100\DTS\Binn\dtexec.exe
"%dtexec%" /X86 /f "myPackage.dtsx" 

and is working...