Azure Runbook在测试窗格中运行,而不是按计划运行

Azure Runbook在测试窗格中运行,而不是按计划运行,azure,stored-procedures,automation,Azure,Stored Procedures,Automation,我们在Azure Automation中创建了一个runbook,它在测试窗格中成功,但在计划时失败。这是一个PowerShell脚本 存储过程中包含命令超时 存储过程应该是删除索引的,当调度时也会成功。我们收到以下错误: Exception calling "ExecuteNonQuery" with "0" argument(s): "Execution Timeout Expired. The timeout period elapsed prior to completion of

我们在Azure Automation中创建了一个runbook,它在测试窗格中成功,但在计划时失败。这是一个PowerShell脚本

存储过程中包含命令超时

存储过程应该是删除索引的,当调度时也会成功。我们收到以下错误:

Exception calling "ExecuteNonQuery" with "0" argument(s): "Execution Timeout Expired. The timeout period elapsed prior 
 to completion of the operation or the server is not responding."
 At SQL_Agent_SprocJob:26 char:26
 + 
 + CategoryInfo : NotSpecified: (:) [], MethodInvocationException
 + FullyQualifiedErrorId : SqlException
试试看这是否管用

$SQLCommand.CommandTimeout=0 
有时,当DTU太低时也会发生这种情况,请尝试将其放大。

如果可行,请尝试

$SQLCommand.CommandTimeout=0 

有时,当DTU太低时也会发生这种情况,请尝试将其放大。

编辑了我的答案。请检查DTU放大。编辑我的答案。请检查DTU放大。