Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Powershell provisioner hangs when the console output is HUGE! #8126

Closed
baghbidi opened this issue Sep 18, 2019 · 2 comments
Closed

Powershell provisioner hangs when the console output is HUGE! #8126

baghbidi opened this issue Sep 18, 2019 · 2 comments

Comments

@baghbidi
Copy link

  • Packer version from packer version: 1.4.3
  • Host platform: Windows Server 2016

So Powershell provisioner was hanging on a msbuild command, tried the commands that have been running in the provisioner on a VM and they worked well - no console prompts, ... .

Set PACKER_LOG=1 and here is the last message I got before hanging forever:

2019/09/18 20:05:00 packer.exe: 2019/09/18 20:05:00 [INFO] command 'powershell -executionpolicy bypass -file "C:/Windows/Temp/packer-elevated-shell-5d828b94-aeeb-4c54-5ea6-364893a9458a.ps1"' exited with code: 0
2019/09/18 20:05:00 packer.exe: 2019/09/18 20:05:00 [INFO] RPC endpoint: Communicator ended with: 0

After investigating for a whole day, realized that the msbuild log before that RPC endpoint message was HUGE... around 200KB. Imagine a line of log that is 200KB. So I changed my msbuild command parameters and added /v:q (which means quiet) and it worked!

Not sure if it's an issue on WinRM side or Packer.

@azr
Copy link
Contributor

azr commented Sep 20, 2019

Hello there thanks for reporting; I think this is due to winrm being very very slow.
A related issue: #2648

And if I am being correct then there is nothing we can do about this issue.
Explanation here.

So I will close this issue. Again please comment here if you think I am wrong; we'll reopen.

@azr azr closed this as completed Sep 20, 2019
@ghost
Copy link

ghost commented Jan 23, 2020

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@ghost ghost locked and limited conversation to collaborators Jan 23, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants