开发者

psexec failing with return code 122 when used from Windows service

I've written a WCF service as a wrapper around a C# utility we've written that uses the SysInternals psexec utility to run jobs on a remote system. psexec is invoked from C# with command-line parameters that specify the domain, user and password to开发者_JAVA技巧 use.

All works fine when I invoke the C# utility from PowerShell locally.

However, when I run the utility from the WCF service we see a return code of 122, which corresponds to (?) "The data area passed to a system call is too small".

psexec is running against Windows Server 2008. The credentials I'm passing are local administrator, in the same domain as the machine that hosts the service wrapping the utility.


So it turns out that this was most likely a bug fixed with PSExec version 1.97. This version appears to work just fine in this circumstance.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜