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

Failing with 21.11 #74

Open
PierreR opened this issue Dec 10, 2021 · 5 comments
Open

Failing with 21.11 #74

PierreR opened this issue Dec 10, 2021 · 5 comments

Comments

@PierreR
Copy link
Collaborator

PierreR commented Dec 10, 2021

If I use

{
  "variables": {
    "disk_size": "72000",
    "memory": "6800",
    "version": "21.11",
    "build": "334139.1bd4bbd49be",
    "checksum": "8259e4a841c624c98a02e24f35e8dfe3363af821cd31831c22b79414454e9379"
  },

The build is failing with

==> virtualbox-iso: Waiting 45s for boot...
==> virtualbox-iso: Typing the boot command...
==> virtualbox-iso: Using ssh communicator to connect: 127.0.0.1
==> virtualbox-iso: Waiting for SSH to become available...
==> virtualbox-iso: Error waiting for SSH: Packer experienced an authentication error when trying to connect via SSH. This can happen if your username/password are wrong. You may want to double-check your credentials as part of your debugging process. original error: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain

If I revert back to 21.05 it works again.

Any idea about what would cause this failure ?

Thanks

@PierreR
Copy link
Collaborator Author

PierreR commented Dec 11, 2021

I wonder if this is not related to the update to openssh 8.8:

https://www.openssh.com/releasenotes.html
hashicorp/packer#10074

@zimbatm is it possible to change the rsa vagrant public key ?

@zimbatm
Copy link
Member

zimbatm commented Dec 11, 2021

Can you try setting services.openssh.extraConfig to

HostkeyAlgorithms +ssh-rsa
PubkeyAcceptedAlgorithms +ssh-rsa

and see if it fixes it?

@zimbatm
Copy link
Member

zimbatm commented Dec 11, 2021

I'm not really using nixbox and would be willing to pass on maintainership.

@PierreR
Copy link
Collaborator Author

PierreR commented Dec 13, 2021

It doesn't work probably because the ssh connection needs to be set up before configuration.nix is used

@stephank
Copy link

stephank commented Dec 14, 2021

I'm not using nixbox, but am using Packer with EC2, and just PubkeyAcceptedAlgorithms is sufficient. I was able to solve it on EC2 with user_data, but not sure a similar mechanism exists for VirtualBox.

Maybe adding "temporary_key_pair_type": "ed25519" to the Packer builder config works? There's an open issue for the EC2 builder that this option is broken there, but maybe it doesn't affect VirtualBox or other builders. (hashicorp/packer-plugin-amazon#144)

k2s added a commit to k2s/nixbox that referenced this issue Jan 10, 2022
… to fix nix-community#74

chore: urls to latest ISOs with existing iso_urls_update.rb script
PierreR pushed a commit to PierreR/devbox that referenced this issue Mar 29, 2022
Generate self generated ssh keys with no passphrase

`ssh-keygen -t ed25519`

nix-community/nixbox#74
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants