2017-10-12 54 views
0

我得到一個超時選擇我的SSIS包中的行...(完整的錯誤細節如下)。有沒有辦法增加SQL Azure的遠程查詢超時而不增加DTU?

  • 該查詢在SSMS中運行3分鐘。
  • 我的SQL Azure服務器有一個Standard1標度(20DTU)。
  • 經過的時間總是30秒。
  • 我沒有固定「連接超時」,並設置爲300(5分鐘)的值
  • 我不能運行

    版EXEC sp_configure遠程查詢超時',300;

    因爲它是一個SQL Azure。

除了增加DTU,有沒有辦法將遠程連接擴展到天青服務器? 我唯一的目的就是偶爾運行一些大的疑問在SSIS ...

Error: System.Data.SqlClient.SqlException (0x80131904): Execution Timeout Expired. The timeout period elapsed prior to completion of the operation or the server is not responding. ---> System.ComponentModel.Win32Exception (0x80004005): The wait operation timed out at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action 1 wrapCloseInAction) at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection, Action 1 wrapCloseInAction) at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose) at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady) at System.Data.SqlClient.SqlDataReader.TryConsumeMetaData() at System.Data.SqlClient.SqlDataReader.get_MetaData() at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption) at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest) at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry) at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method) at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method) at System.Data.SqlClient.SqlCommand.ExecuteDbDataReader(CommandBehavior behavior) at System.Data.Common.DbCommand.System.Data.IDbCommand.ExecuteReader(CommandBehavior behavior) at Microsoft.SqlServer.Dts.Pipeline.DataReaderSourceAdapter.PreExecute() at Microsoft.SqlServer.Dts.Pipeline.ManagedComponentHost.HostPreExecute(IDTSManagedComponentWrapper100 wrapper)

回答

4

對於I/O密集型工作負載,你應該使用的高級層次。在運行這些工作負載之前進行擴展,並在SSIS包完成時縮減到標準。請檢查運行SSIS包時的DTU消耗情況,您可能會發現工作負載正在達到層限制併發生限制。

也請將異步處理設爲真。有關它的更多信息,請點擊here。將連接超時設置爲零。

希望這會有所幫助。

+0

我剛剛從Ado.Net數據源切換到OLE DB。除此之外,我現在正在使用參數化連接字符串。現在我的查詢在沒有30秒問題的情況下在DEBUG上運行良好。我不知道爲什麼...... – Oyen

+0

感謝您與我們分享您的發現。讓我試着調查並與更多人分享。如果我得到答案,我會更新這個線程。 –

+1

嗨Oyen。我想我現在知道你爲什麼沒有看到與OLEDB相同的行爲。 OLEDB源的默認連接超時時間爲零。 –

相關問題