Start-Transcript not working with octopus

Hi there,

We are trying to log some of the Powershell commands we run on the servers during a release. I know Octopus logs them already on its database, but a customer specifically requested to have them on a file on the tentacle available at any time. So we created the following script using “start-transcript”.


Start-Transcript C:\Transcript\transcript.txt -Append

Write-Output “Hi there!”


The Octopus log shows the script ran ok and i can see the “Hi There!”. But the output back on the tentacle on “transcript.txt” is the following:

Windows PowerShell transcript start
Start time: 20140619022557
Username : OurDomainName\SYSTEM
Machine : AwsomeComputerName (Microsoft Windows NT 6.1.7601 Service Pack 1)

Windows PowerShell transcript end
End time: 20140619022557

We can see that Start and End messages the Transcript cmdlets created. But the code in the middle is not being captured.

This works just fine when manually running the scripts on the server.

Hi Dalmiro,

Thanks for getting in touch!

So I do not have awesome news here. I have been able to replicate what you are seeing. It appears that because Octopus and Tentacle capture the output of powershell to do something it then isn’t available for output to transcript. Unfortunately it also means this is not a bug, and not something we can change, its a limitation of PowerShell.

I did however have a little bit of a result when using Write-Output "stuff" | Out-File $filepath -append . We do understand this isn’t exactly a solution to your problem and Write-Output itself has some limitations.

Sorry it isn’t better news.


I figured that was going to be the answer :confused:

At least we’ll save some time to the next person that tries this.

Thx Vanessa!