psexec output behaves differently under Bamboo than command prompt

Short form: When running a tool on a remote machine via psexec, the output of the tool is generated when run from a command prompt, but is missing when invoked from Bamboo.

psexec.exe -accepteula (remote) (tool.exe)

Starting PSEXESVC service on (remote)...
Connecting with PsExec service on (remote)...
Starting (tool.exe) on (remote)...

(tool output shows here in command prompt, is missing in bamboo log...)

(tool.exe) exited on (remote) with error code 0.


Long form:  I have a tool I'm wanting to execute on a remote machine during an automated build.  It works, but every once in a while, it locks up, and in turn would lock up the build, since it never exits.  I've added logging to the console in the tool, in hopes of tracking down what's happening.  If I start up a command prompt using the same identity as the bamboo service, and call psexec (as above), the tool output to the console displays just fine.

Unfortunately, when the same command is called during a bamboo build (via the Bamboo SCRIPT task), the psexec runs the tool, and the tool executes, but none of the console logging is being recorded in the bamboo logs.

I'm using the latest psexec (2.11).  

Anybody have any luck seeing the remotely executed tools output within Bamboo's logs?

Can someone explain to me the apparent idiosyncratic differences between calling psexec via a command prompt versus how Bamboo invokes it within its SCRIPT task? 

1 answer

Hi Eric,

I seem to be having the exact same problem as you, using Bamboo 5.10.3 and psexec 2.11 on my Windows Server 2012 R2 build and deploy server.

I can see that psexec starts successfully in the Bamboo deploy log, but Bamboo doesn't wait for psexec to complete; it only provides partial output before continuing to the next command in my deploy script.

If I run the deploy script in the console on the build server then it operates as expected and waits for the psexec command to complete before running any other commands.

I am tempted to open a support ticket with Atlassian to investigate and find a solution.

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Jan 08, 2019 in Jira

How to Jira for designers

I’m a designer on the Jira team. For a long time, I’ve fielded questions from other designers about how they should be using Jira Software with their design team. I’ve also heard feedback from other ...

812 views 3 9
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you