-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
Failed to send shutdown command: handshake failed EOF #1029
Comments
I'm also seeing this problem now (this has worked with a previous version of packer). Trying to debug it now. |
Some relevant logs:
Hanging after the last message. |
I've created a patch that fixes this. Will send a pull request soon. Basically we just need to add a timeout for the handshake, otherwise it just waits for it forever. This can happen if the TCP connection succeeds but SSH isn't at the other end (at least that's my guess as to what's happening, didn't dig too deeply into the why). |
@SephVelut I think I may have jumped the gun in declaring that we're experiencing the same problem (haven't completely ruled it out though). Sorry about that. Does your problem disappear if you split your scripts into two separate provisioning blocks? I think packer will only gracefully handle restarts in between separate shell provisioners. I believe my problem is due to some odd interactions between openvz's installer and my firewall configuration. |
@brownhead Thanks for the tip! I can confirm that separating scripts into two shell provision blocks was a solution to my particular problem. I'll close this issue now. |
Issue is possibly related to: #921
virtualbox-iso: Failed to send shutdown command: handshake failed: EOF
Packer.json: https://gist.github.com/10507611
Provision Scripts: https://gist.github.com/10507453
Packer Log: https://gist.github.com/10507491
CentOS Kickstart file: https://gist.github.com/10508015
Removing reboot from the centos_start.sh provision script dissolves the problem. Does packer support bash script reboot?
It appears that packer attempts to re-establish an ssh session the second the vm shuts down but doesn't continue to retry as it normally would. This happens everytime I run packer build.
The text was updated successfully, but these errors were encountered: