-
Notifications
You must be signed in to change notification settings - Fork 17
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
Occasional Timeout waiting for SSH #79
Comments
Do you observe any failures during the installation process of the macOS? This might be related to |
My vanilla script seems to be timing out as well.
No errors that I can see. |
@sridhar-vadlamani-ck how are you invoking the Packer, from CI, or from a user-interactive Terminal? Also this might be related to the DHCP shortage, please check out https://tart.run/faq/#changing-the-default-dhcp-lease-time. |
It's being invoked in CI, from a non-interactive terminal. This is my source:
Also, it's not the DHCP shortage. Timeout is set to 10mins and the vanilla vm build was basically the first one on these machines. I'm still building it out. |
@sridhar-vadlamani-ck are you trying macOS Sequia Beta 2 host by any chance? We've see this issue on Sequia hosts. |
@fkorotkov I'm building from a |
But what about the host? Just checking this. But please also check @edigaryev's tip about DHCP. |
The host is also a sonoma instance.
These are freshly launched instances with the DHCP lease time set to 10mins per the FAQ already. |
I re-ran it a bunch of times, and of about 12 runs, one has succeeded. Everything else seems to fail with the SSH connection issue. |
Is there anything else you'd like me to rule out? |
Can you connect to the VM using the |
|
The SSH issue is only happening when I build the vanilla image. If I build from another image directly, there are no issues. |
This most likely has to do with Make sure that your |
This started happening to me just now too, but on Sequioa. It happens in the CI environment, but it does not happen when I SSH into the host and run the same commands myself on the terminal. |
I tried this, and I was able to connect right then. But, the CI environment does not connect. |
I just got a new M4 MacBook Pro and it will hang on "Waiting for SSH to become available..." every time while the VM is actually booted and I can do stuff with it. It still works 100% on my old M1 MacBook. Will investigate a bit more, maybe it's more because it's a fresh installation than because of the new hardware? 🤔 Will investigate a bit more...
|
@CodeStage are you invoking Packer from the CI? This is likely related to the newly introduced "Local Network" permission in macOS Sequoia and the fact that Packer binary has no One way to work around this is to either invoke Packer from the Terminal app, or re-built Packer with git clone -b v1.11.2 https://github.com/hashicorp/packer.git
cd packer/
go build -ldflags="-linkmode=external" -o ~/packer . Afterwards, invoke the resulting |
Thanks for that hint! I was actually running it via Warp which is terminal app. Running it via Apple's terminal app works fine. Update: After giving Warp the networking permission it worked too 🙈 |
hashicorp/packer#13214 should fix this in the next Packer release (assuming it'll be merged). |
The fix is now merged into the Packer, however, it will only appear with the next Packer release (1.12.0 or so), scheduled for the January. Meanwhile, you can either rebuild Packer to have |
Hey there! Thanks for all your great work on this!
I sometimes get the following error when building an image from IPSW. My ssh_timeout is set to 180s, and I'm killing the
tart
process before beginning the build to ensure its not a result of too many VMs running (>2).Here is what my source block looks like, its essentially identical to the templates provided in https://github.com/cirruslabs/macos-image-templates/blob/master/templates/vanilla-ventura.pkr.hcl
The text was updated successfully, but these errors were encountered: