Psexec + teamcity(Version 6.0.3 (build 15925)) not working

I am facing problem in running Psexec from teamcity. I tried the following ways  but none of them worked.

  1. Use command line as build runner and in command wrote psexec \\machine cmd /c "echo. | powershell dir *.txt"
  2. Put the above command in a batch file and tried running it using command line build runner
  3. Search on teamcity forums, applied the redirection trick: psexe \\machinename cmd /c "echo .| powershell dir *.txt" < nul 1>stdout.txtx 2>stderr.txt

All the above commands work well from my machine but doesn't work with teamcity. the build hangs after connecting to the machine. Is there any other alternatives to run remote scripts from teamcity that works well with teamcity. I tried romcom.exe but even that doesn't seem to work.
Any help or suggestion would be highly appreciated.

1 comment
Comment actions Permalink


Could you please list details of your environment:

  1. OS versions (with service pack) and editions (x86 or x64) on both TeamCity agent and remote machine.
  2. pstools version
  3. a screentshot of build step settings
  4. full build log

I appreciate if you help us finally catch this mysterious issue.



Please sign in to leave a comment.