6

尝试使用 MSDeploy“runCommand”提供程序在远程计算机上执行 .cmd 文件时遇到错误。预期的运行时间应该是 10 秒左右,但 MSDeploy 只运行了大约 2-3 秒,之后会返回错误详细信息。

这是我正在使用的完整的 MSDeploy“runCommand”命令行文本:

msdeploy.exe -verb:sync -source:runCommand="D:\web deploy tester\test_cmd.cmd",dontUseCommandExe=false,waitAttempts=5,waitInterval=1000 -dest:auto,computername=http://test-machine:89/MsDeployAgentService/,userName=aaa,password=bbb

以下是返回的错误详细信息:

Error 'Error: (4/21/2010 12:19:25 PM) An error occurred when the request was processed on the remote computer.
Error: The process 'C:\WINDOWS\system32\cmd.exe' (command line '/c "D:\web deploy tester\test_cmd.cmd"') was terminated because it exceeded the wait time.
Error count: 1.
' occurred in call to RunCommand

关于为什么会发生这种情况以及如何解决它的任何想法?

4

1 回答 1

6

您应该指定更高的 waitInterval 值。该值以毫秒为单位。您可能想尝试 20000(20 秒)。默认值为 1000。

于 2010-05-01T03:28:45.223 回答