hashicorp / hashicorp/packer-plugin-sdk

ssh hang when remote reboot

Open
#94 0 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
Go
Stars
42
Forks
62
Avg merge
29m
Merged PRs (30d)
2

Description

#### Overview of the Issue

the code will hang on func newSession() in communicator/ssh/communicator.go
sometimes when rebooting remote server.

#### Reproduction Steps

1. the provisioner config is as follow and the reboot.sh will reboot the remote system.

`
"provisioners": [
{
"type": "shell",
"scripts": [
"reboot.sh"
],
"expect_disconnect": true
},
.....
]
`

2. when rebootting the remote system, the the packer will hang on newSession()
sometimes.

### Packer Plugin SDK version

v0.2.11

### Operating system and Environment details

it's a copy of golang/go#50604
and after view the the issue golang/go#26643
maybe we deal with the problem on sdk level.

### Log Fragments and crash.log files

Include appropriate log fragments. If the log is longer than a few dozen lines,
please include the URL to the [gist](https://gist.github.com/) of the log or
use the [Github detailed format](https://gist.github.com/ericclemmons/b146fe5da72ca1f706b2ef72a20ac39d) instead of posting it directly in the issue.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.