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

SSH error while building image with CentOS stream 9 cloud images #11656

Closed
kashifest opened this issue Mar 11, 2022 · 25 comments · Fixed by #11754
Closed

SSH error while building image with CentOS stream 9 cloud images #11656

kashifest opened this issue Mar 11, 2022 · 25 comments · Fixed by #11754

Comments

@kashifest
Copy link

When filing a bug, please include the following headings if possible. Any
example text in this template can be deleted.

Overview of the Issue

While building an image on CentOS stream 9 cloud image, we are facing the following error:

2022/03/11 11:36:55 packer-builder-openstack plugin: [INFO] Waiting for SSH, up to timeout: 10m0s
2022/03/11 11:36:55 packer-builder-openstack plugin: [DEBUG] Using floating IP 89.42.141.82 to connect
2022/03/11 11:37:02 packer-builder-openstack plugin: [DEBUG] TCP connection to SSH ip/port failed: dial tcp 89.42.141.82:22: connect: connection refused
2022/03/11 11:37:07 packer-builder-openstack plugin: [DEBUG] Using floating IP 89.42.141.82 to connect
2022/03/11 11:37:07 packer-builder-openstack plugin: [INFO] Attempting SSH connection to 89.42.141.82:22...
2022/03/11 11:37:07 packer-builder-openstack plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/03/11 11:37:07 packer-builder-openstack plugin: [DEBUG] handshaking with SSH
2022/03/11 11:37:07 packer-builder-openstack plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/03/11 11:37:07 packer-builder-openstack plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/03/11 11:37:14 packer-builder-openstack plugin: [DEBUG] Using floating IP 89.42.141.82 to connect
2022/03/11 11:37:14 packer-builder-openstack plugin: [INFO] Attempting SSH connection to 89.42.141.82:22...
2022/03/11 11:37:14 packer-builder-openstack plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/03/11 11:37:14 packer-builder-openstack plugin: [DEBUG] handshaking with SSH
2022/03/11 11:37:15 packer-builder-openstack plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/03/11 11:37:15 packer-builder-openstack plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/03/11 11:37:22 packer-builder-openstack plugin: [DEBUG] Using floating IP 89.42.141.82 to connect
2022/03/11 11:37:22 packer-builder-openstack plugin: [INFO] Attempting SSH connection to 89.42.141.82:22...
2022/03/11 11:37:22 packer-builder-openstack plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/03/11 11:37:22 packer-builder-openstack plugin: [DEBUG] handshaking with SSH
2022/03/11 11:37:22 packer-builder-openstack plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/03/11 11:37:22 packer-builder-openstack plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/03/11 11:37:29 packer-builder-openstack plugin: [DEBUG] Using floating IP 89.42.141.82 to connect
2022/03/11 11:37:29 packer-builder-openstack plugin: [INFO] Attempting SSH connection to 89.42.141.82:22...
2022/03/11 11:37:29 packer-builder-openstack plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/03/11 11:37:29 packer-builder-openstack plugin: [DEBUG] handshaking with SSH
2022/03/11 11:37:29 packer-builder-openstack plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/03/11 11:37:29 packer-builder-openstack plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/03/11 11:37:36 packer-builder-openstack plugin: [DEBUG] Using floating IP 89.42.141.82 to connect
2022/03/11 11:37:36 packer-builder-openstack plugin: [INFO] Attempting SSH connection to 89.42.141.82:22...
2022/03/11 11:37:36 packer-builder-openstack plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/03/11 11:37:36 packer-builder-openstack plugin: [DEBUG] handshaking with SSH
2022/03/11 11:37:37 packer-builder-openstack plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/03/11 11:37:37 packer-builder-openstack plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/03/11 11:37:44 packer-builder-openstack plugin: [DEBUG] Using floating IP 89.42.141.82 to connect
2022/03/11 11:37:44 packer-builder-openstack plugin: [INFO] Attempting SSH connection to 89.42.141.82:22...
2022/03/11 11:37:44 packer-builder-openstack plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/03/11 11:37:44 packer-builder-openstack plugin: [DEBUG] handshaking with SSH
2022/03/11 11:37:44 packer-builder-openstack plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/03/11 11:37:44 packer-builder-openstack plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/03/11 11:37:51 packer-builder-openstack plugin: [DEBUG] Using floating IP 89.42.141.82 to connect
2022/03/11 11:37:51 packer-builder-openstack plugin: [INFO] Attempting SSH connection to 89.42.141.82:22...
2022/03/11 11:37:51 packer-builder-openstack plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/03/11 11:37:51 packer-builder-openstack plugin: [DEBUG] handshaking with SSH
2022/03/11 11:37:51 packer-builder-openstack plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/03/11 11:37:51 packer-builder-openstack plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/03/11 11:37:58 packer-builder-openstack plugin: [DEBUG] Using floating IP 89.42.141.82 to connect
2022/03/11 11:37:58 packer-builder-openstack plugin: [INFO] Attempting SSH connection to 89.42.141.82:22...
2022/03/11 11:37:58 packer-builder-openstack plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/03/11 11:37:58 packer-builder-openstack plugin: [DEBUG] handshaking with SSH
2022/03/11 11:37:59 packer-builder-openstack plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/03/11 11:37:59 packer-builder-openstack plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/03/11 11:38:06 packer-builder-openstack plugin: [DEBUG] Using floating IP 89.42.141.82 to connect
2022/03/11 11:38:06 packer-builder-openstack plugin: [INFO] Attempting SSH connection to 89.42.141.82:22...
2022/03/11 11:38:06 packer-builder-openstack plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/03/11 11:38:06 packer-builder-openstack plugin: [DEBUG] handshaking with SSH
2022/03/11 11:38:06 packer-builder-openstack plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/03/11 11:38:06 packer-builder-openstack plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/03/11 11:38:13 packer-builder-openstack plugin: [DEBUG] Using floating IP 89.42.141.82 to connect
2022/03/11 11:38:13 packer-builder-openstack plugin: [INFO] Attempting SSH connection to 89.42.141.82:22...
2022/03/11 11:38:13 packer-builder-openstack plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/03/11 11:38:13 packer-builder-openstack plugin: [DEBUG] handshaking with SSH
2022/03/11 11:38:13 packer-builder-openstack plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/03/11 11:38:13 packer-builder-openstack plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
==> openstack: 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
2022/03/11 11:38:13 packer-builder-openstack plugin: Error asking for input: no available tty
==> openstack: 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
==> openstack: Step "StepConnect" failed
==> openstack: Deleted temporary floating IP '9679e2b2-ff90-4ea4-a241-14e7169f1d88' (89.42.141.82)
==> openstack: Terminating the source server: a4978b1a-77be-4eb2-ac7e-96c3ba75009e ...
2022/03/11 11:38:16 packer-builder-openstack plugin: Waiting for state to become: [DELETED]
2022/03/11 11:38:16 packer-builder-openstack plugin: Waiting for state to become: [DELETED] currently ACTIVE (0%)
2022/03/11 11:38:19 packer-builder-openstack plugin: Waiting for state to become: [DELETED] currently ACTIVE (0%)
2022/03/11 11:38:21 packer-builder-openstack plugin: [INFO] 404 on ServerStateRefresh, returning DELETED
2022/03/11 11:38:21 [INFO] (telemetry) ending openstack
==> Wait completed after 1 minute 51 seconds
2022/03/11 11:38:21 machine readable: error-count []string{"1"}
==> Some builds didn't complete successfully and had errors:
2022/03/11 11:38:21 machine readable: openstack,error []string{"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"}
==> Builds finished but no artifacts were created.
2022/03/11 11:38:21 [INFO] (telemetry) Finalizing.
Build 'openstack' errored after 1 minute 51 seconds: 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

==> Wait completed after 1 minute 51 seconds

==> Some builds didn't complete successfully and had errors:
--> openstack: 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

==> Builds finished but no artifacts were created.
2022/03/11 11:38:22 waiting for all plugin processes to complete...
2022/03/11 11:38:22 /bin/packer: plugin process exited
2022/03/11 11:38:22 /bin/packer: plugin process exited
2022/03/11 11:38:22 /bin/packer: plugin process exited

If we only change to CentOS stream 8 cloud image in the whole process, the build is passing. It seems packer is facing issues while SSH handshake in CentOS stream 9.

Packer version

From packer version

1.6.5

Operating system and Environment details

OS, Architecture, and any other information you can provide about the
environment.
https://cloud.centos.org/centos/9-stream/x86_64/images/CentOS-Stream-GenericCloud-9-20220309.0.x86_64.qcow2

@kashifest kashifest added the bug label Mar 11, 2022
@pavelpikta
Copy link

Hi @kashifest
We have same issue but with Amazon Linux 2. #11623 (comment)
Rebuild with new AMI helped us.
I also recommended you try to build with new Centos 9 image

@kashifest
Copy link
Author

Hi @kashifest We have same issue but with Amazon Linux 2. #11623 (comment) Rebuild with new AMI helped us. I also recommended you try to build with new Centos 9 image

Thanks for the reply, strangely that didnt help for us, still facing the same issue.

@goeranu
Copy link

goeranu commented Mar 17, 2022

We have the same issue with the RHEL 9 beta images.

It seems to be related to the stronger crypto policy requirements on recent OS releases. By running packer in debug mode, we paused after the VM was created, but before packer tries to connect to it using SSH.

While packer is waiting we connect to the machine with ssh (regular OpenSSH, which works just fine) and run update-crypto-policies --set LEGACY.

After that we continue the packer process which now works just fine. Packer can connect with SSH and starts to do the tasks in our packer file.

Our conclusion is that the internal SSH agent used by packer is not up to date with contemporary requirements. It can't handle the DEFAULT policy on RHEL/CentOS (and presumably Fedora). The LEGACY policy, as the name suggests, allows also older less secure algorithms.

@DanielViard
Copy link

Same issue here with daily build Ubuntu 22.04 image (https://cloud-images.ubuntu.com/jammy/current/jammy-server-cloudimg-amd64.img).
As workaround adding PubkeyAcceptedKeyTypes=+ssh-rsa in /etc/ssh/sshd_config unblock packer.

But we need a fix in packer to be able to use it properly with that future Ubuntu release.

@breisig
Copy link

breisig commented Mar 31, 2022

This is really important to fix.

@marcottedan
Copy link

marcottedan commented Apr 6, 2022

We have the same issue with a Windows Server 2019 image patched with the latest Windows Updates.

==> amazon-ebs.base: 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

Packer version 1.8.0

@lizthegrey
Copy link

Same problem -- Packer cannot build images based on 22.04. I incorrectly blamed cloud-init, but it turns out Packer's SSH keys are too insecure for 22.04 to accept. https://bugs.launchpad.net/cloud-init/+bug/1968360

@lizthegrey
Copy link

Here's a workaround based on #11656 (comment):

{
  "builders": [
    {
      "type": "amazon-ebs",
      "user_data": "#!/bin/sh\necho PubkeyAcceptedKeyTypes=+ssh-rsa >> /etc/ssh/sshd_config; service ssh reload",
      [...]

@mhahl
Copy link

mhahl commented Apr 19, 2022

Currently using this workaround for CentOS 9 Stream on OpenStack:

{
    "builders": [
      {
            "type": "openstack",
	    "user_data_file": "cloud-config.txt",
    [...]

Where cloud-config.txt contains:

#cloud-config
runcmd:
  - [ /bin/update-crypto-policies, --set, LEGACY ]

@jpbuecken
Copy link

At least hashicorp developers should be aware about this, because terraform is affected as well.

I assume packer and terraform uses the same golang code base:

I post the terraform issue here, because it contains a good bug description and some links to the state in the go project

hashicorp/terraform#30134

And maybe hashicorp sees that both of their projects are affected and can synergize their ressources.

@kashifest
Copy link
Author

Thanks a lot everyone for the suggestions, I have already got it in a working shop following your suggestions, I just wonder when will a maintainer acknowledge this issue and try to land a fix in packer.

@jpbuecken
Copy link

jpbuecken commented Apr 19, 2022

In my case I was able to use a ssh key based on elliptic curve instead of rsa.
So I don't need to enable legacy security policies:

Example with linux ssh keygen

ssh-keygen -t ed25519

Looks like the go / packer code is ok with that.

@sc250024
Copy link

sc250024 commented Apr 21, 2022

Having the same problem with Ubuntu 22.04, but with virtualbox-iso as the builder. What's funny if I pass -on-error='ask', and wait for the ISO build to finish, Ubuntu 22.04 actually boots successfully.

EDIT: I tried one of the workaround for the virtualbox-iso build, but the problem is that Ubuntu 22.04 LTS is using the new Subiquity autoinstall interface. Based on the schema (https://ubuntu.com/server/docs/install/autoinstall-reference), you can either use early-commands or late-commands to put in the following fix from above: #11656 (comment).

However, early-commands occurs at a point in the install process where SSH is not yet installed (nor is anything else AFAICT), and late-commands never has a chance to run because Packer fails before then.

In short, it seems for certain *-iso builds, you're SOL until the fix.

@lorengordon
Copy link

Likely the same root cause as this issue: #8609

@asottile
Copy link

at least for amazon-ebs I was able to get this working by using "temporary_key_pair_type": "ed25519", in my builder configuration

@lizthegrey
Copy link

confirmed, didn't know the temporary_key_pair_type option was an option! working now instead of the cloud-init userdata script.

@sc250024
Copy link

sc250024 commented Apr 22, 2022

Would be nice to use temporary_key_pair_type 😢 . I tried setting ssh_key_exchange_algorithms = ["ecdh-sha2-nistp384"], but it didn't work. I also tried generating a private key file of the same type (ED25519), but that also didn't work; Packer just fails. The following are the local trace logs:

Local Virtualbox ISO build
2022/04/22 17:51:50 [INFO] Packer version: 1.8.0 [go1.17.8 darwin amd64]
2022/04/22 17:51:50 Old default config directory found: /path/to/my/home/folder/.packer.d
2022/04/22 17:51:50 [TRACE] discovering plugins in /usr/local/bin
2022/04/22 17:51:50 Old default config directory found: /path/to/my/home/folder/.packer.d
2022/04/22 17:51:50 [TRACE] discovering plugins in /path/to/my/home/folder/.packer.d/plugins
2022/04/22 17:51:50 [TRACE] discovering plugins in .
2022/04/22 17:51:50 [INFO] PACKER_CONFIG env var not set; checking the default config file path
2022/04/22 17:51:50 [INFO] PACKER_CONFIG env var set; attempting to open config file: /path/to/my/home/folder/.packerconfig
2022/04/22 17:51:50 [WARN] Config file doesn't exist: /path/to/my/home/folder/.packerconfig
2022/04/22 17:51:50 Old default config directory found: /path/to/my/home/folder/.packer.d
2022/04/22 17:51:50 [INFO] Setting cache directory: /path/to/my/home/folder/.cache/packer
2022/04/22 17:51:50 Old default config directory found: /path/to/my/home/folder/.packer.d
2022/04/22 17:51:50 [TRACE] listing potential installations for "github.com/hashicorp/amazon" that match "~> 1.0". plugingetter.ListInstallationsOptions{FromFolders:[]string{"/usr/local/bin/packer", ".", "/path/to/my/home/folder/.packer.d/plugins"}, BinaryInstallationOptions:plugingetter.BinaryInstallationOptions{APIVersionMajor:"5", APIVersionMinor:"0", OS:"darwin", ARCH:"amd64", Ext:"", Checksummers:[]plugingetter.Checksummer{plugingetter.Checksummer{Type:"sha256", Hash:(*sha256.digest)(0xc00048e000)}}}}
2022/04/22 17:51:50 [TRACE] Found the following "github.com/hashicorp/amazon" installations: [{/path/to/my/home/folder/.packer.d/plugins/github.com/hashicorp/amazon/packer-plugin-amazon_v1.0.0_x5.0_darwin_amd64 v1.0.0}]
2022/04/22 17:51:50 [INFO] found external [chroot ebs ebssurrogate ebsvolume instance] builders from amazon plugin
2022/04/22 17:51:50 [INFO] found external [import] post-processors from amazon plugin
2022/04/22 17:51:50 found external [ami secretsmanager] datasource from amazon plugin
2022/04/22 17:51:50 [TRACE] validateValue: not active for image_disk_size, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for ssh_pty, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for ssh_wait_timeout, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for vmimport_secret, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for vmimport_bucket, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for format, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for boot_wait, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for ssh_port, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for ubuntu_password, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for ubuntu_ssh_user, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for vmimport_access, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for image_cpus, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for ubuntu_mirror_url, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for ubuntu_2204_iso_name, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for ubuntu_2204_mirror_directory, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for virtualbox_version_file, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for image_memory, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for virtualbox_guest_os_version, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for ubuntu_2204_iso_checksum, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for vmimport_env, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for headless, so skipping
2022/04/22 17:51:50 [TRACE] validateValue: not active for http_directory, so skipping
2022/04/22 17:51:50 [TRACE] Starting internal plugin packer-builder-virtualbox-iso
2022/04/22 17:51:50 Starting plugin: /usr/local/bin/packer []string{"/usr/local/bin/packer", "plugin", "packer-builder-virtualbox-iso"}
2022/04/22 17:51:50 Waiting for RPC address for: /usr/local/bin/packer
2022/04/22 17:51:50 packer-builder-virtualbox-iso plugin: [INFO] Packer version: 1.8.0 [go1.17.8 darwin amd64]
2022/04/22 17:51:50 packer-builder-virtualbox-iso plugin: Old default config directory found: /path/to/my/home/folder/.packer.d
2022/04/22 17:51:50 packer-builder-virtualbox-iso plugin: [INFO] PACKER_CONFIG env var not set; checking the default config file path
2022/04/22 17:51:50 packer-builder-virtualbox-iso plugin: [INFO] PACKER_CONFIG env var set; attempting to open config file: /path/to/my/home/folder/.packerconfig
2022/04/22 17:51:50 packer-builder-virtualbox-iso plugin: [WARN] Config file doesn't exist: /path/to/my/home/folder/.packerconfig
2022/04/22 17:51:50 packer-builder-virtualbox-iso plugin: Old default config directory found: /path/to/my/home/folder/.packer.d
2022/04/22 17:51:50 packer-builder-virtualbox-iso plugin: [INFO] Setting cache directory: /path/to/my/home/folder/.cache/packer
2022/04/22 17:51:50 packer-builder-virtualbox-iso plugin: args: []string{"packer-builder-virtualbox-iso"}
2022/04/22 17:51:50 packer-builder-virtualbox-iso plugin: Old default config directory found: /path/to/my/home/folder/.packer.d
2022/04/22 17:51:50 packer-builder-virtualbox-iso plugin: Plugin address: unix /var/folders/nq/6mm8fvrx1d51xhkh2ky2cyjm0000gs/T/packer-plugin3841255669
2022/04/22 17:51:50 packer-builder-virtualbox-iso plugin: Waiting for connection...
2022/04/22 17:51:50 Received unix RPC address for /usr/local/bin/packer: addr is /var/folders/nq/6mm8fvrx1d51xhkh2ky2cyjm0000gs/T/packer-plugin3841255669
2022/04/22 17:51:50 packer-builder-virtualbox-iso plugin: Serving a plugin connection...
2022/04/22 17:51:52 [TRACE] Starting internal plugin packer-provisioner-file
2022/04/22 17:51:52 Starting plugin: /usr/local/bin/packer []string{"/usr/local/bin/packer", "plugin", "packer-provisioner-file"}
2022/04/22 17:51:52 Waiting for RPC address for: /usr/local/bin/packer
2022/04/22 17:51:52 packer-provisioner-file plugin: [INFO] Packer version: 1.8.0 [go1.17.8 darwin amd64]
2022/04/22 17:51:52 packer-provisioner-file plugin: Old default config directory found: /path/to/my/home/folder/.packer.d
2022/04/22 17:51:52 packer-provisioner-file plugin: [INFO] PACKER_CONFIG env var not set; checking the default config file path
2022/04/22 17:51:52 packer-provisioner-file plugin: [INFO] PACKER_CONFIG env var set; attempting to open config file: /path/to/my/home/folder/.packerconfig
2022/04/22 17:51:52 packer-provisioner-file plugin: [WARN] Config file doesn't exist: /path/to/my/home/folder/.packerconfig
2022/04/22 17:51:52 packer-provisioner-file plugin: Old default config directory found: /path/to/my/home/folder/.packer.d
2022/04/22 17:51:52 packer-provisioner-file plugin: [INFO] Setting cache directory: /path/to/my/home/folder/.cache/packer
2022/04/22 17:51:52 packer-provisioner-file plugin: Old default config directory found: /path/to/my/home/folder/.packer.d
2022/04/22 17:51:52 packer-provisioner-file plugin: args: []string{"packer-provisioner-file"}
2022/04/22 17:51:52 packer-provisioner-file plugin: Plugin address: unix /var/folders/nq/6mm8fvrx1d51xhkh2ky2cyjm0000gs/T/packer-plugin2040462781
2022/04/22 17:51:52 Received unix RPC address for /usr/local/bin/packer: addr is /var/folders/nq/6mm8fvrx1d51xhkh2ky2cyjm0000gs/T/packer-plugin2040462781
2022/04/22 17:51:52 packer-provisioner-file plugin: Waiting for connection...
2022/04/22 17:51:52 packer-provisioner-file plugin: Serving a plugin connection...
2022/04/22 17:51:52 [TRACE] Starting internal plugin packer-provisioner-shell
2022/04/22 17:51:52 Starting plugin: /usr/local/bin/packer []string{"/usr/local/bin/packer", "plugin", "packer-provisioner-shell"}
2022/04/22 17:51:52 Waiting for RPC address for: /usr/local/bin/packer
2022/04/22 17:51:52 packer-provisioner-shell plugin: [INFO] Packer version: 1.8.0 [go1.17.8 darwin amd64]
2022/04/22 17:51:52 packer-provisioner-shell plugin: Old default config directory found: /path/to/my/home/folder/.packer.d
2022/04/22 17:51:52 packer-provisioner-shell plugin: [INFO] PACKER_CONFIG env var not set; checking the default config file path
2022/04/22 17:51:52 packer-provisioner-shell plugin: [INFO] PACKER_CONFIG env var set; attempting to open config file: /path/to/my/home/folder/.packerconfig
2022/04/22 17:51:52 packer-provisioner-shell plugin: [WARN] Config file doesn't exist: /path/to/my/home/folder/.packerconfig
2022/04/22 17:51:52 packer-provisioner-shell plugin: Old default config directory found: /path/to/my/home/folder/.packer.d
2022/04/22 17:51:52 packer-provisioner-shell plugin: [INFO] Setting cache directory: /path/to/my/home/folder/.cache/packer
2022/04/22 17:51:52 packer-provisioner-shell plugin: Old default config directory found: /path/to/my/home/folder/.packer.d
2022/04/22 17:51:52 packer-provisioner-shell plugin: args: []string{"packer-provisioner-shell"}
2022/04/22 17:51:52 packer-provisioner-shell plugin: Plugin address: unix /var/folders/nq/6mm8fvrx1d51xhkh2ky2cyjm0000gs/T/packer-plugin863159107
2022/04/22 17:51:52 packer-provisioner-shell plugin: Waiting for connection...
2022/04/22 17:51:52 Received unix RPC address for /usr/local/bin/packer: addr is /var/folders/nq/6mm8fvrx1d51xhkh2ky2cyjm0000gs/T/packer-plugin863159107
2022/04/22 17:51:52 packer-provisioner-shell plugin: Serving a plugin connection...
2022/04/22 17:51:52 Build debug mode: false
2022/04/22 17:51:52 Force build: false
2022/04/22 17:51:52 On error: ask
2022/04/22 17:51:52 Waiting on builds to complete...
2022/04/22 17:51:52 Starting build run: ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base
2022/04/22 17:51:52 Running builder:
2022/04/22 17:51:52 [INFO] (telemetry) Starting builder virtualbox-iso.ubuntu-2204-amd64-base
ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: output will be in this color.

2022/04/22 17:51:52 packer-builder-virtualbox-iso plugin: VBoxManage path: /usr/local/bin/VBoxManage
2022/04/22 17:51:52 packer-builder-virtualbox-iso plugin: VBoxManage --version output: 6.1.32r149290
2022/04/22 17:51:52 packer-builder-virtualbox-iso plugin: VirtualBox version: 6.1.32
2022/04/22 17:51:52 packer-builder-virtualbox-iso plugin: guest_additions_url is blank; querying driver for iso.
2022/04/22 17:51:52 packer-builder-virtualbox-iso plugin: Found Default Guest Additions ISO: /Applications/VirtualBox.app/Contents/MacOS/VBoxGuestAdditions.iso
2022/04/22 17:51:52 packer-builder-virtualbox-iso plugin: Guest additions URL: /Applications/VirtualBox.app/Contents/MacOS/VBoxGuestAdditions.iso
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Retrieving Guest additions
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Trying /Applications/VirtualBox.app/Contents/MacOS/VBoxGuestAdditions.iso
2022/04/22 17:51:52 packer-builder-virtualbox-iso plugin: Acquiring lock for: /Applications/VirtualBox.app/Contents/MacOS/VBoxGuestAdditions.iso (/path/to/my/home/folder/.cache/packer/7784a55a71d48a1e9b5c487431438fef0f19d87f.iso.lock)
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Trying /Applications/VirtualBox.app/Contents/MacOS/VBoxGuestAdditions.iso
2022/04/22 17:51:52 packer-builder-virtualbox-iso plugin: Leaving retrieve loop for Guest additions
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: /Applications/VirtualBox.app/Contents/MacOS/VBoxGuestAdditions.iso => /Applications/VirtualBox.app/Contents/MacOS/VBoxGuestAdditions.iso
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Retrieving ISO
2022/04/22 17:51:52 packer-builder-virtualbox-iso plugin: Acquiring lock for: https://releases.ubuntu.com/22.04/ubuntu-22.04-live-server-amd64.iso?checksum=sha256%3A84aeaf7823c8c61baa0ae862d0a06b03409394800000b3235854a6b38eb4856f (/path/to/my/home/folder/.cache/packer/b9441068de828d36573e1274dfe77f69aebda15a.iso.lock)
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Trying https://releases.ubuntu.com/22.04/ubuntu-22.04-live-server-amd64.iso
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Trying https://releases.ubuntu.com/22.04/ubuntu-22.04-live-server-amd64.iso?checksum=sha256%3A84aeaf7823c8c61baa0ae862d0a06b03409394800000b3235854a6b38eb4856f
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Leaving retrieve loop for ISO
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: https://releases.ubuntu.com/22.04/ubuntu-22.04-live-server-amd64.iso?checksum=sha256%3A84aeaf7823c8c61baa0ae862d0a06b03409394800000b3235854a6b38eb4856f => /path/to/my/home/folder/.cache/packer/b9441068de828d36573e1274dfe77f69aebda15a.iso
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: No floppy files specified. Floppy disk will not be made.
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: No CD files specified. CD disk will not be made.
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Found available port: 8045 on IP: 0.0.0.0
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Starting HTTP server on port 8045
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Suppressing annoying messages in VirtualBox
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"setextradata", "global", "GUI/UpdateDate", "1 d, 2023-01-01, stable"}
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"setextradata", "global", "GUI/RegistrationData", "triesLeft=0"}
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"setextradata", "global", "GUI/SuppressMessages", "confirmInputCapture,remindAboutAutoCapture,remindAboutMouseIntegrationOff,remindAboutMouseIntegrationOn,remindAboutWrongColorDepth"}
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"setextradata", "global", "GUI/UpdateCheckCount", "60"}
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stderr:
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Creating virtual machine...
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"createvm", "--name", "the-name-of-my-vm", "--ostype", "Ubuntu_64", "--register"}
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stdout: Virtual machine 'the-name-of-my-vm' is created and registered.
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: UUID: 54b89aa0-5bbd-43bf-a5e1-5088c9b7fc4e
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Settings file: '/path/to/my/home/folder/VirtualBox VMs/the-name-of-my-vm/the-name-of-my-vm.vbox'
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"modifyvm", "the-name-of-my-vm", "--boot1", "disk", "--boot2", "dvd", "--boot3", "none", "--boot4", "none"}
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"modifyvm", "the-name-of-my-vm", "--cpus", "1"}
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"modifyvm", "the-name-of-my-vm", "--memory", "512"}
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"modifyvm", "the-name-of-my-vm", "--usb", "off"}
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"modifyvm", "the-name-of-my-vm", "--audio", "none", "--audiocontroller", "ac97"}
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"modifyvm", "the-name-of-my-vm", "--chipset", "piix3"}
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"modifyvm", "the-name-of-my-vm", "--firmware", "bios"}
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"modifyvm", "the-name-of-my-vm", "--nictype1", "82540EM", "--nictype2", "82540EM", "--nictype3", "82540EM", "--nictype4", "82540EM", "--nictype5", "82540EM", "--nictype6", "82540EM", "--nictype7", "82540EM", "--nictype8", "82540EM"}
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"modifyvm", "the-name-of-my-vm", "--graphicscontroller", "vboxvga", "--vram", "4"}
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:56 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"modifyvm", "the-name-of-my-vm", "--rtcuseutc", "off"}
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"modifyvm", "the-name-of-my-vm", "--accelerate3d", "off"}
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stderr:
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Creating hard drive output-ubuntu-2204-amd64-base/the-name-of-my-vm.vdi with size 102400 MiB...
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"createhd", "--filename", "output-ubuntu-2204-amd64-base/the-name-of-my-vm.vdi", "--size", "102400", "--format", "VDI", "--variant", "Standard"}
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stdout: Medium created. UUID: f6fadbed-3889-4c24-8c4d-95caac34f8e2
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stderr: 0%...10%...20%...30%...40%...50%...60%...70%...80%...90%...100%
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"storagectl", "the-name-of-my-vm", "--name", "IDE Controller", "--add", "ide"}
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"storageattach", "the-name-of-my-vm", "--storagectl", "IDE Controller", "--port", "0", "--device", "0", "--type", "hdd", "--medium", "output-ubuntu-2204-amd64-base/the-name-of-my-vm.vdi", "--nonrotational", "off", "--discard", "off"}
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stderr:
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Mounting ISOs...
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: Not attaching guest additions since we're uploading.
    ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Mounting boot ISO...
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"storageattach", "the-name-of-my-vm", "--storagectl", "IDE Controller", "--port", "0", "--device", "1", "--type", "dvddrive", "--medium", "/path/to/my/home/folder/.cache/packer/b9441068de828d36573e1274dfe77f69aebda15a.iso"}
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: Looking for available port between 5900 and 6000 on 127.0.0.1
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: Found available port: 5931 on IP: 127.0.0.1
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"modifyvm", "the-name-of-my-vm", "--vrdeaddress", "127.0.0.1", "--vrdeauthtype", "null", "--vrde", "on", "--vrdeport", "5931"}
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: No floppy disk, not attaching.
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: Looking for available communicator (SSH, WinRM, etc) port between 2222 and 4444
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: Found available port: 3757 on IP: 127.0.0.1
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"modifyvm", "the-name-of-my-vm", "--nic1", "nat"}
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"modifyvm", "the-name-of-my-vm", "--natpf1", "packercomm,tcp,127.0.0.1,3757,,22"}
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Creating forwarded port mapping for communicator (SSH, WinRM, etc) (host port 3757)
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stderr:
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Executing custom VBoxManage commands...
    ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Executing: modifyvm the-name-of-my-vm --memory 4096
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"modifyvm", "the-name-of-my-vm", "--memory", "4096"}
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stderr:
    ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Executing: modifyvm the-name-of-my-vm --cpus 4
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"modifyvm", "the-name-of-my-vm", "--cpus", "4"}
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stderr:
    ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Executing: modifyvm the-name-of-my-vm --audio none
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"modifyvm", "the-name-of-my-vm", "--audio", "none"}
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: stderr:
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Starting the virtual machine...
2022/04/22 17:51:57 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"startvm", "the-name-of-my-vm", "--type", "gui"}
2022/04/22 17:52:00 packer-builder-virtualbox-iso plugin: stdout: Waiting for VM "the-name-of-my-vm" to power on...
2022/04/22 17:52:00 packer-builder-virtualbox-iso plugin: VM "the-name-of-my-vm" has been successfully started.
2022/04/22 17:52:00 packer-builder-virtualbox-iso plugin: stderr:
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Waiting 12s for boot...
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Typing the boot command...
2022/04/22 17:52:12 packer-builder-virtualbox-iso plugin: Sending char ' ', code '39b9', shift false
2022/04/22 17:52:12 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "39", "b9"}
2022/04/22 17:52:12 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:12 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:12 packer-builder-virtualbox-iso plugin: [INFO] Waiting 1s
2022/04/22 17:52:13 packer-builder-virtualbox-iso plugin: Sending char ' ', code '39b9', shift false
2022/04/22 17:52:13 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "39", "b9"}
2022/04/22 17:52:13 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:13 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:13 packer-builder-virtualbox-iso plugin: [INFO] Waiting 1s
2022/04/22 17:52:14 packer-builder-virtualbox-iso plugin: Sending char ' ', code '39b9', shift false
2022/04/22 17:52:14 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "39", "b9"}
2022/04/22 17:52:14 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:14 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:14 packer-builder-virtualbox-iso plugin: [INFO] Waiting 1s
2022/04/22 17:52:15 packer-builder-virtualbox-iso plugin: Sending char ' ', code '39b9', shift false
2022/04/22 17:52:15 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "39", "b9"}
2022/04/22 17:52:15 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:15 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:15 packer-builder-virtualbox-iso plugin: [INFO] Waiting 1s
2022/04/22 17:52:16 packer-builder-virtualbox-iso plugin: Sending char ' ', code '39b9', shift false
2022/04/22 17:52:16 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "39", "b9"}
2022/04/22 17:52:16 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:16 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:17 packer-builder-virtualbox-iso plugin: [INFO] Waiting 1s
2022/04/22 17:52:18 packer-builder-virtualbox-iso plugin: Sending char 'c', code '2eae', shift false
2022/04/22 17:52:18 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "2e", "ae"}
2022/04/22 17:52:18 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:18 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:18 packer-builder-virtualbox-iso plugin: [INFO] Waiting 1s
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char 's', code '1f9f', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char 'e', code '1292', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char 't', code '1494', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char ' ', code '39b9', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char 'g', code '22a2', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char 'f', code '21a1', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char 'x', code '2dad', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char 'p', code '1999', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char 'a', code '1e9e', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char 'y', code '1595', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char 'l', code '26a6', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char 'o', code '1898', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char 'a', code '1e9e', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char 'd', code '20a0', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char '=', code '0d8d', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char 'k', code '25a5', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char 'e', code '1292', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char 'e', code '1292', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Sending char 'p', code '1999', shift false
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Special code 'Press' '<enter>' found, replacing with: &{[1c] [9c]}
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "1f", "9f", "12", "92", "14", "94", "39", "b9", "22", "a2", "21", "a1", "2d", "ad", "19", "99", "1e", "9e", "15", "95", "26", "a6", "18", "98"}
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "1e", "9e", "20", "a0", "0d", "8d", "25", "a5", "12", "92", "12", "92", "19", "99", "1c", "9c"}
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:19 packer-builder-virtualbox-iso plugin: [INFO] Waiting 1s
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'l', code '26a6', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'i', code '1797', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'n', code '31b1', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'u', code '1696', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'x', code '2dad', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char ' ', code '39b9', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char '/', code '35b5', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'c', code '2eae', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'a', code '1e9e', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 's', code '1f9f', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'p', code '1999', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'e', code '1292', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'r', code '1393', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char '/', code '35b5', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'v', code '2faf', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'm', code '32b2', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'l', code '26a6', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'i', code '1797', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'n', code '31b1', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'u', code '1696', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'z', code '2cac', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char ' ', code '39b9', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'q', code '1090', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'u', code '1696', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'i', code '1797', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 'e', code '1292', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Sending char 't', code '1494', shift false
2022/04/22 17:52:20 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "26", "a6", "17", "97", "31", "b1", "16", "96", "2d", "ad", "39", "b9", "35", "b5", "2e", "ae", "1e", "9e", "1f", "9f", "19", "99", "12", "92"}
2022/04/22 17:52:21 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:21 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:21 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "13", "93", "35", "b5", "2f", "af", "32", "b2", "26", "a6", "17", "97", "31", "b1", "16", "96", "2c", "ac", "39", "b9", "10", "90", "16", "96"}
2022/04/22 17:52:21 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:21 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:21 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "17", "97", "12", "92", "14", "94"}
2022/04/22 17:52:21 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:21 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:22 packer-builder-virtualbox-iso plugin: [INFO] Waiting 1s
2022/04/22 17:52:23 packer-builder-virtualbox-iso plugin: Sending char ' ', code '39b9', shift false
2022/04/22 17:52:23 packer-builder-virtualbox-iso plugin: Sending char 'a', code '1e9e', shift false
2022/04/22 17:52:23 packer-builder-virtualbox-iso plugin: Sending char 'u', code '1696', shift false
2022/04/22 17:52:23 packer-builder-virtualbox-iso plugin: Sending char 't', code '1494', shift false
2022/04/22 17:52:23 packer-builder-virtualbox-iso plugin: Sending char 'o', code '1898', shift false
2022/04/22 17:52:23 packer-builder-virtualbox-iso plugin: Sending char 'i', code '1797', shift false
2022/04/22 17:52:23 packer-builder-virtualbox-iso plugin: Sending char 'n', code '31b1', shift false
2022/04/22 17:52:23 packer-builder-virtualbox-iso plugin: Sending char 's', code '1f9f', shift false
2022/04/22 17:52:23 packer-builder-virtualbox-iso plugin: Sending char 't', code '1494', shift false
2022/04/22 17:52:23 packer-builder-virtualbox-iso plugin: Sending char 'a', code '1e9e', shift false
2022/04/22 17:52:23 packer-builder-virtualbox-iso plugin: Sending char 'l', code '26a6', shift false
2022/04/22 17:52:23 packer-builder-virtualbox-iso plugin: Sending char 'l', code '26a6', shift false
2022/04/22 17:52:23 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "39", "b9", "1e", "9e", "16", "96", "14", "94", "18", "98", "17", "97", "31", "b1", "1f", "9f", "14", "94", "1e", "9e", "26", "a6", "26", "a6"}
2022/04/22 17:52:23 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:23 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:23 packer-builder-virtualbox-iso plugin: [INFO] Waiting 1s
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: Sending char ' ', code '39b9', shift false
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: Sending char 'd', code '20a0', shift false
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: Sending char 's', code '1f9f', shift false
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: Sending char '=', code '0d8d', shift false
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: Sending char 'n', code '31b1', shift false
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: Sending char 'o', code '1898', shift false
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: Sending char 'c', code '2eae', shift false
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: Sending char 'l', code '26a6', shift false
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: Sending char 'o', code '1898', shift false
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: Sending char 'u', code '1696', shift false
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: Sending char 'd', code '20a0', shift false
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: Sending char '-', code '0c8c', shift false
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: Sending char 'n', code '31b1', shift false
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: Sending char 'e', code '1292', shift false
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: Sending char 't', code '1494', shift false
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "39", "b9", "20", "a0", "1f", "9f", "0d", "8d", "31", "b1", "18", "98", "2e", "ae", "26", "a6", "18", "98", "16", "96", "20", "a0", "0c", "8c"}
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:24 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "31", "b1", "12", "92", "14", "94"}
2022/04/22 17:52:25 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:25 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:25 packer-builder-virtualbox-iso plugin: [INFO] Waiting 1s
2022/04/22 17:52:26 packer-builder-virtualbox-iso plugin: Sending char '\', code '2bab', shift false
2022/04/22 17:52:26 packer-builder-virtualbox-iso plugin: Sending char ';', code '27a7', shift false
2022/04/22 17:52:26 packer-builder-virtualbox-iso plugin: Sending char 's', code '1f9f', shift false
2022/04/22 17:52:26 packer-builder-virtualbox-iso plugin: Sending char '=', code '0d8d', shift false
2022/04/22 17:52:26 packer-builder-virtualbox-iso plugin: Sending char 'h', code '23a3', shift false
2022/04/22 17:52:26 packer-builder-virtualbox-iso plugin: Sending char 't', code '1494', shift false
2022/04/22 17:52:26 packer-builder-virtualbox-iso plugin: Sending char 't', code '1494', shift false
2022/04/22 17:52:26 packer-builder-virtualbox-iso plugin: Sending char 'p', code '1999', shift false
2022/04/22 17:52:26 packer-builder-virtualbox-iso plugin: Sending char ':', code '2a27a7aa', shift true
2022/04/22 17:52:26 packer-builder-virtualbox-iso plugin: Sending char '/', code '35b5', shift false
2022/04/22 17:52:26 packer-builder-virtualbox-iso plugin: Sending char '/', code '35b5', shift false
2022/04/22 17:52:26 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "2b", "ab", "27", "a7", "1f", "9f", "0d", "8d", "23", "a3", "14", "94", "14", "94", "19", "99", "2a", "27", "a7", "aa", "35", "b5", "35", "b5"}
2022/04/22 17:52:26 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:26 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:26 packer-builder-virtualbox-iso plugin: [INFO] Waiting 1s
2022/04/22 17:52:27 packer-builder-virtualbox-iso plugin: Sending char '1', code '0282', shift false
2022/04/22 17:52:27 packer-builder-virtualbox-iso plugin: Sending char '0', code '0b8b', shift false
2022/04/22 17:52:27 packer-builder-virtualbox-iso plugin: Sending char '.', code '34b4', shift false
2022/04/22 17:52:27 packer-builder-virtualbox-iso plugin: Sending char '0', code '0b8b', shift false
2022/04/22 17:52:27 packer-builder-virtualbox-iso plugin: Sending char '.', code '34b4', shift false
2022/04/22 17:52:27 packer-builder-virtualbox-iso plugin: Sending char '2', code '0383', shift false
2022/04/22 17:52:27 packer-builder-virtualbox-iso plugin: Sending char '.', code '34b4', shift false
2022/04/22 17:52:27 packer-builder-virtualbox-iso plugin: Sending char '2', code '0383', shift false
2022/04/22 17:52:27 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "02", "82", "0b", "8b", "34", "b4", "0b", "8b", "34", "b4", "03", "83", "34", "b4", "03", "83"}
2022/04/22 17:52:27 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:27 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:27 packer-builder-virtualbox-iso plugin: [INFO] Waiting 1s
2022/04/22 17:52:28 packer-builder-virtualbox-iso plugin: Sending char ':', code '2a27a7aa', shift true
2022/04/22 17:52:28 packer-builder-virtualbox-iso plugin: Sending char '8', code '0989', shift false
2022/04/22 17:52:28 packer-builder-virtualbox-iso plugin: Sending char '0', code '0b8b', shift false
2022/04/22 17:52:28 packer-builder-virtualbox-iso plugin: Sending char '4', code '0585', shift false
2022/04/22 17:52:28 packer-builder-virtualbox-iso plugin: Sending char '5', code '0686', shift false
2022/04/22 17:52:28 packer-builder-virtualbox-iso plugin: Sending char '/', code '35b5', shift false
2022/04/22 17:52:28 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "2a", "27", "a7", "aa", "09", "89", "0b", "8b", "05", "85", "06", "86", "35", "b5"}
2022/04/22 17:52:29 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:29 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:29 packer-builder-virtualbox-iso plugin: [INFO] Waiting 1s
2022/04/22 17:52:30 packer-builder-virtualbox-iso plugin: Sending char ' ', code '39b9', shift false
2022/04/22 17:52:30 packer-builder-virtualbox-iso plugin: Sending char '-', code '0c8c', shift false
2022/04/22 17:52:30 packer-builder-virtualbox-iso plugin: Sending char '-', code '0c8c', shift false
2022/04/22 17:52:30 packer-builder-virtualbox-iso plugin: Sending char '-', code '0c8c', shift false
2022/04/22 17:52:30 packer-builder-virtualbox-iso plugin: Special code 'Press' '<enter>' found, replacing with: &{[1c] [9c]}
2022/04/22 17:52:30 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "39", "b9", "0c", "8c", "0c", "8c", "0c", "8c", "1c", "9c"}
2022/04/22 17:52:30 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:30 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:30 packer-builder-virtualbox-iso plugin: [INFO] Waiting 1s
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 'i', code '1797', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 'n', code '31b1', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 'i', code '1797', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 't', code '1494', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 'r', code '1393', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 'd', code '20a0', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char ' ', code '39b9', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char '/', code '35b5', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 'c', code '2eae', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 'a', code '1e9e', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 's', code '1f9f', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 'p', code '1999', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 'e', code '1292', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 'r', code '1393', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char '/', code '35b5', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 'i', code '1797', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 'n', code '31b1', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 'i', code '1797', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 't', code '1494', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 'r', code '1393', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Sending char 'd', code '20a0', shift false
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "17", "97", "31", "b1", "17", "97", "14", "94", "13", "93", "20", "a0", "39", "b9", "35", "b5", "2e", "ae", "1e", "9e", "1f", "9f", "19", "99"}
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:31 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "12", "92", "13", "93", "35", "b5", "17", "97", "31", "b1", "17", "97", "14", "94", "13", "93", "20", "a0"}
2022/04/22 17:52:32 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:32 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:32 packer-builder-virtualbox-iso plugin: [INFO] Waiting 1s
2022/04/22 17:52:33 packer-builder-virtualbox-iso plugin: Special code 'Press' '<enter>' found, replacing with: &{[1c] [9c]}
2022/04/22 17:52:33 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "1c", "9c"}
2022/04/22 17:52:33 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:33 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:33 packer-builder-virtualbox-iso plugin: [INFO] Waiting 1s
2022/04/22 17:52:34 packer-builder-virtualbox-iso plugin: Sending char 'b', code '30b0', shift false
2022/04/22 17:52:34 packer-builder-virtualbox-iso plugin: Sending char 'o', code '1898', shift false
2022/04/22 17:52:34 packer-builder-virtualbox-iso plugin: Sending char 'o', code '1898', shift false
2022/04/22 17:52:34 packer-builder-virtualbox-iso plugin: Sending char 't', code '1494', shift false
2022/04/22 17:52:34 packer-builder-virtualbox-iso plugin: Special code 'Press' '<enter>' found, replacing with: &{[1c] [9c]}
2022/04/22 17:52:34 packer-builder-virtualbox-iso plugin: Executing VBoxManage: []string{"controlvm", "the-name-of-my-vm", "keyboardputscancode", "30", "b0", "18", "98", "18", "98", "14", "94", "1c", "9c"}
2022/04/22 17:52:34 packer-builder-virtualbox-iso plugin: stdout:
2022/04/22 17:52:34 packer-builder-virtualbox-iso plugin: stderr:
2022/04/22 17:52:34 packer-builder-virtualbox-iso plugin: [INFO] Waiting 1s
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Using SSH communicator to connect: 127.0.0.1
2022/04/22 17:52:35 packer-builder-virtualbox-iso plugin: [INFO] Waiting for SSH, up to timeout: 30m0s
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Waiting for SSH to become available...
2022/04/22 17:52:35 packer-builder-virtualbox-iso plugin: [INFO] Attempting SSH connection to 127.0.0.1:3757...
2022/04/22 17:52:35 packer-builder-virtualbox-iso plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/04/22 17:52:35 packer-builder-virtualbox-iso plugin: [DEBUG] handshaking with SSH
2022/04/22 17:52:55 packer-builder-virtualbox-iso plugin: [DEBUG] SSH handshake err: ssh: handshake failed: read tcp 127.0.0.1:51825->127.0.0.1:3757: read: connection reset by peer
2022/04/22 17:53:02 packer-builder-virtualbox-iso plugin: [INFO] Attempting SSH connection to 127.0.0.1:3757...
2022/04/22 17:53:02 packer-builder-virtualbox-iso plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/04/22 17:53:02 packer-builder-virtualbox-iso plugin: [DEBUG] handshaking with SSH
2022/04/22 17:53:05 packer-builder-virtualbox-iso plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
2022/04/22 17:53:05 packer-builder-virtualbox-iso plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/04/22 17:53:12 packer-builder-virtualbox-iso plugin: [INFO] Attempting SSH connection to 127.0.0.1:3757...
2022/04/22 17:53:12 packer-builder-virtualbox-iso plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/04/22 17:53:12 packer-builder-virtualbox-iso plugin: [DEBUG] handshaking with SSH
2022/04/22 17:53:15 packer-builder-virtualbox-iso plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
2022/04/22 17:53:15 packer-builder-virtualbox-iso plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/04/22 17:53:22 packer-builder-virtualbox-iso plugin: [INFO] Attempting SSH connection to 127.0.0.1:3757...
2022/04/22 17:53:22 packer-builder-virtualbox-iso plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/04/22 17:53:22 packer-builder-virtualbox-iso plugin: [DEBUG] handshaking with SSH
2022/04/22 17:53:24 packer-builder-virtualbox-iso plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
2022/04/22 17:53:24 packer-builder-virtualbox-iso plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/04/22 17:53:31 packer-builder-virtualbox-iso plugin: [INFO] Attempting SSH connection to 127.0.0.1:3757...
2022/04/22 17:53:31 packer-builder-virtualbox-iso plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/04/22 17:53:31 packer-builder-virtualbox-iso plugin: [DEBUG] handshaking with SSH
2022/04/22 17:53:33 packer-builder-virtualbox-iso plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
2022/04/22 17:53:33 packer-builder-virtualbox-iso plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/04/22 17:53:40 packer-builder-virtualbox-iso plugin: [INFO] Attempting SSH connection to 127.0.0.1:3757...
2022/04/22 17:53:40 packer-builder-virtualbox-iso plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/04/22 17:53:40 packer-builder-virtualbox-iso plugin: [DEBUG] handshaking with SSH
2022/04/22 17:53:43 packer-builder-virtualbox-iso plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
2022/04/22 17:53:43 packer-builder-virtualbox-iso plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/04/22 17:53:50 packer-builder-virtualbox-iso plugin: [INFO] Attempting SSH connection to 127.0.0.1:3757...
2022/04/22 17:53:50 packer-builder-virtualbox-iso plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/04/22 17:53:50 packer-builder-virtualbox-iso plugin: [DEBUG] handshaking with SSH
2022/04/22 17:53:53 packer-builder-virtualbox-iso plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
2022/04/22 17:53:53 packer-builder-virtualbox-iso plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/04/22 17:54:00 packer-builder-virtualbox-iso plugin: [INFO] Attempting SSH connection to 127.0.0.1:3757...
2022/04/22 17:54:00 packer-builder-virtualbox-iso plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/04/22 17:54:00 packer-builder-virtualbox-iso plugin: [DEBUG] handshaking with SSH
2022/04/22 17:54:02 packer-builder-virtualbox-iso plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
2022/04/22 17:54:02 packer-builder-virtualbox-iso plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/04/22 17:54:09 packer-builder-virtualbox-iso plugin: [INFO] Attempting SSH connection to 127.0.0.1:3757...
2022/04/22 17:54:09 packer-builder-virtualbox-iso plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/04/22 17:54:09 packer-builder-virtualbox-iso plugin: [DEBUG] handshaking with SSH
2022/04/22 17:54:12 packer-builder-virtualbox-iso plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
2022/04/22 17:54:12 packer-builder-virtualbox-iso plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/04/22 17:54:19 packer-builder-virtualbox-iso plugin: [INFO] Attempting SSH connection to 127.0.0.1:3757...
2022/04/22 17:54:19 packer-builder-virtualbox-iso plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/04/22 17:54:19 packer-builder-virtualbox-iso plugin: [DEBUG] handshaking with SSH
2022/04/22 17:54:21 packer-builder-virtualbox-iso plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
2022/04/22 17:54:21 packer-builder-virtualbox-iso plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/04/22 17:54:26 packer-builder-virtualbox-iso plugin: [INFO] Attempting SSH connection to 127.0.0.1:3757...
2022/04/22 17:54:26 packer-builder-virtualbox-iso plugin: [DEBUG] reconnecting to TCP connection for SSH
2022/04/22 17:54:26 packer-builder-virtualbox-iso plugin: [DEBUG] handshaking with SSH
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: 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 password], no supported methods remain
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: 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 password], no supported methods remain
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: Step "StepConnect" failed
2022/04/22 17:54:28 packer-builder-virtualbox-iso plugin: [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
2022/04/22 17:54:28 packer-builder-virtualbox-iso plugin: [DEBUG] Detected authentication error. Increasing handshake attempts.
==> ubuntu-2204-amd64-virtualbox.virtualbox-iso.ubuntu-2204-amd64-base: [c] Clean up and exit, [a] abort without cleanup, or [r] retry step (build may fail even if retry succeeds)?

@marcottedan
Copy link

temporary_key_pair_type did not work for me as well with a Windows 2019 server box.

@sc250024
Copy link

Found a solution for *-iso builds (tested on virtualbox-iso) => #11733 (comment)

@nywilken
Copy link
Member

nywilken commented May 5, 2022

Hi folks a potential fix for this issue has been merged into Packer main. It is scheduled to be released next week but will be available in the next nightly release. The SSH communication is handled by the Packer Plugin SDK within each of the builders. So even though Packer has the latest SDK the plugin responsible for executing the builder will need to be updated as well in order for the fix to work. We are tracking individual plugin updates in #11761.

To download the latest plugin you can run packer init against a HCL file that is using the required_plugins{...} block with the updated plugin version. Or you can run the packer plugins install command to get the latest version for a given plugin. For example you can run packer plugins install github.com/hashicorp/docker to install the latest version of Docker.

note: The latest nightly has the fix #11712 which should help folks using JSON

@nywilken
Copy link
Member

nywilken commented May 5, 2022

Oh one more thing 😄

If you are still running into issues with the proposed fix please feel free to drop a comment on the thread and we will gladly reopen. Thanks again to everyone for providing workarounds and for your patience.

@onematchfox
Copy link
Contributor

If you are still running into issues with the proposed fix please feel free to drop a comment on the thread and we will gladly reopen. Thanks again to everyone for providing workarounds and for your patience.

@nywilken I seem to still be running into issues with the virtualbox-vm builder despite upgrading the plugin to version 1.0.2 as per the changes in #11761. VM is Ubuntu 22.04.

Config as follows:

source "virtualbox-vm" "my_vm" {
  communicator         = "ssh"
  format               = "ova"
  guest_additions_mode = "disable"
  headless             = true
  output_directory     = "./builds-vm"
  shutdown_command     = "sudo shutdown -h now"
  ssh_private_key_file = "..."
  ssh_username         = "..."
  vm_name              = "my_vm"
}

Logs as follows:

2022/05/24 12:49:02 [INFO] Packer version: 1.8.0 [go1.17.8 linux amd64]
2022/05/24 12:49:02 Old default config directory found: /home/me/.packer.d
2022/05/24 12:49:02 [TRACE] discovering plugins in /home/me/.asdf/installs/packer/1.8.0/bin
2022/05/24 12:49:02 Old default config directory found: /home/me/.packer.d
2022/05/24 12:49:02 [TRACE] discovering plugins in /home/me/.packer.d/plugins
2022/05/24 12:49:02 [TRACE] discovering plugins in .
2022/05/24 12:49:02 [INFO] PACKER_CONFIG env var not set; checking the default config file path
2022/05/24 12:49:02 [INFO] PACKER_CONFIG env var set; attempting to open config file: /home/me/.packerconfig
2022/05/24 12:49:02 [WARN] Config file doesn't exist: /home/me/.packerconfig
2022/05/24 12:49:02 Old default config directory found: /home/me/.packer.d
2022/05/24 12:49:02 [INFO] Setting cache directory: /home/me/.cache/packer
2022/05/24 12:49:02 Old default config directory found: /home/me/.packer.d
2022/05/24 12:49:02 [TRACE] listing potential installations for "github.com/hashicorp/virtualbox" that match ">= 1.0.2". plugingetter.ListInstallationsOptions{FromFolders:[]string{"/home/me/.asdf/installs/packer/1.8.0/bin/packer", ".", "/home/me/.packer.d/plugins"}, BinaryInstallationOptions:plugingetter.BinaryInstallationOptions{APIVersionMajor:"5", APIVersionMinor:"0", OS:"linux", ARCH:"amd64", Ext:"", Checksummers:[]plugingetter.Checksummer{plugingetter.Checksummer{Type:"sha256", Hash:(*sha256.digest)(0xc0000e0000)}}}}
2022/05/24 12:49:02 [TRACE] Found the following "github.com/hashicorp/virtualbox" installations: [{/home/me/.packer.d/plugins/github.com/hashicorp/virtualbox/packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 v1.0.2}]
2022/05/24 12:49:02 [INFO] found external [iso ovf vm] builders from virtualbox plugin
2022/05/24 12:49:02 [TRACE] validateValue: not active for box_name, so skipping
2022/05/24 12:49:02 [TRACE] validateValue: not active for version, so skipping
2022/05/24 12:49:02 [TRACE] Starting external plugin /home/me/.packer.d/plugins/github.com/hashicorp/virtualbox/packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 start builder vm
2022/05/24 12:49:02 Starting plugin: /home/me/.packer.d/plugins/github.com/hashicorp/virtualbox/packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 []string{"/home/me/.packer.d/plugins/github.com/hashicorp/virtualbox/packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64", "start", "builder", "vm"}
2022/05/24 12:49:02 Waiting for RPC address for: /home/me/.packer.d/plugins/github.com/hashicorp/virtualbox/packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 Plugin address: unix /tmp/packer-plugin2266929284
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 Waiting for connection...
2022/05/24 12:49:02 Received unix RPC address for /home/me/.packer.d/plugins/github.com/hashicorp/virtualbox/packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64: addr is /tmp/packer-plugin2266929284
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 Serving a plugin connection...
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 [TRACE] starting builder vm
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 PostShutdownDelay: 2s
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 VBoxManage path: /usr/bin/VBoxManage
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 Executing LoadSnapshots: VM: my_vm
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 Executing VBoxManage: []string{"snapshot", "my_vm", "list", "--machinereadable"}
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 stdout: This machine does not have any snapshots
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 stderr:
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 Snapshots loaded from VM my_vm
2022/05/24 12:49:02 [TRACE] Starting internal plugin packer-post-processor-amazon-import
2022/05/24 12:49:02 Starting plugin: /home/me/.asdf/installs/packer/1.8.0/bin/packer []string{"/home/me/.asdf/installs/packer/1.8.0/bin/packer", "plugin", "packer-post-processor-amazon-import"}
2022/05/24 12:49:02 Waiting for RPC address for: /home/me/.asdf/installs/packer/1.8.0/bin/packer
2022/05/24 12:49:02 packer-post-processor-amazon-import plugin: [INFO] Packer version: 1.8.0 [go1.17.8 linux amd64]
2022/05/24 12:49:02 packer-post-processor-amazon-import plugin: Old default config directory found: /home/me/.packer.d
2022/05/24 12:49:02 packer-post-processor-amazon-import plugin: [INFO] PACKER_CONFIG env var not set; checking the default config file path
2022/05/24 12:49:02 packer-post-processor-amazon-import plugin: [INFO] PACKER_CONFIG env var set; attempting to open config file: /home/me/.packerconfig
2022/05/24 12:49:02 packer-post-processor-amazon-import plugin: [WARN] Config file doesn't exist: /home/me/.packerconfig
2022/05/24 12:49:02 packer-post-processor-amazon-import plugin: Old default config directory found: /home/me/.packer.d
2022/05/24 12:49:02 packer-post-processor-amazon-import plugin: [INFO] Setting cache directory: /home/me/.cache/packer
2022/05/24 12:49:02 packer-post-processor-amazon-import plugin: args: []string{"packer-post-processor-amazon-import"}
2022/05/24 12:49:02 packer-post-processor-amazon-import plugin: Old default config directory found: /home/me/.packer.d
2022/05/24 12:49:02 packer-post-processor-amazon-import plugin: Plugin address: unix /tmp/packer-plugin774002955
2022/05/24 12:49:02 packer-post-processor-amazon-import plugin: Waiting for connection...
2022/05/24 12:49:02 Received unix RPC address for /home/me/.asdf/installs/packer/1.8.0/bin/packer: addr is /tmp/packer-plugin774002955
2022/05/24 12:49:02 packer-post-processor-amazon-import plugin: Serving a plugin connection...
2022/05/24 12:49:02 packer-post-processor-amazon-import plugin: [INFO] (aws): No AWS timeout and polling overrides have been set. Packer will default to waiter-specific delays and timeouts. If you would like to customize the length of time between retries and max number of retries you may do so by setting the environment variables AWS_POLL_DELAY_SECONDS and AWS_MAX_ATTEMPTS or the configuration options aws_polling_delay_seconds and aws_polling_max_attempts to your desired values.
2022/05/24 12:49:02 packer-post-processor-amazon-import plugin: [INFO] (aws): No AWS timeout and polling overrides have been set. Packer will default to waiter-specific delays and timeouts. If you would like to customize the length of time between retries and max number of retries you may do so by setting the environment variables AWS_POLL_DELAY_SECONDS and AWS_MAX_ATTEMPTS or the configuration options aws_polling_delay_seconds and aws_polling_max_attempts to your desired values.
2022/05/24 12:49:02 packer-post-processor-amazon-import plugin: {{my_vm virtualbox-vm 1.8.0 false false  map[] []} { { 0   []  map[] []}   false false 10   ca-central-1  false false  <nil> {   } 0xc000772270 <nil> 0xc000ec2000} [redacted] virtualbox-vm 1.8.0 }}
2022/05/24 12:49:02 Build debug mode: false
2022/05/24 12:49:02 Force build: false
2022/05/24 12:49:02 On error: 
2022/05/24 12:49:02 Waiting on builds to complete...
virtualbox-vm.vbox: output will be in this color.

2022/05/24 12:49:02 Starting build run: virtualbox-vm.vbox
2022/05/24 12:49:02 Running builder: 
2022/05/24 12:49:02 [INFO] (telemetry) Starting builder virtualbox-vm.vbox
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 VBoxManage path: /usr/bin/VBoxManage
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 Suppressing annoying messages in VirtualBox
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 Executing VBoxManage: []string{"setextradata", "global", "GUI/UpdateDate", "1 d, 2023-01-01, stable"}
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 stdout:
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 stderr:
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 Executing VBoxManage: []string{"setextradata", "global", "GUI/RegistrationData", "triesLeft=0"}
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 stdout:
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 stderr:
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 Executing VBoxManage: []string{"setextradata", "global", "GUI/SuppressMessages", "confirmInputCapture,remindAboutAutoCapture,remindAboutMouseIntegrationOff,remindAboutMouseIntegrationOn,remindAboutWrongColorDepth"}
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 stdout:
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 stderr:
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 Executing VBoxManage: []string{"setextradata", "global", "GUI/UpdateCheckCount", "60"}
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 stdout:
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 stderr:
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 No floppy files specified. Floppy disk will not be made.
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 No CD files specified. CD disk will not be made.
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 Executing LoadSnapshots: VM: my_vm
2022/05/24 12:49:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:02 Executing VBoxManage: []string{"snapshot", "my_vm", "list", "--machinereadable"}
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 stdout: This machine does not have any snapshots
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 stderr:
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 Not downloading guest additions since it is disabled.
==> virtualbox-vm.vbox: Mounting ISOs...
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 Not attaching guest additions since we're uploading.
    virtualbox-vm.vbox: No ISOs to mount; continuing...
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 Looking for available port between 5900 and 6000 on 127.0.0.1
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 Found available port: 5944 on IP: 127.0.0.1
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 Executing VBoxManage: []string{"modifyvm", "my_vm", "--vrdeaddress", "127.0.0.1", "--vrdeauthtype", "null", "--vrde", "on", "--vrdeport", "5944"}
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 stdout:
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 stderr:
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 No floppy disk, not attaching.
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 Looking for available communicator (SSH, WinRM, etc) port between 2222 and 4444
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 Found available port: 3441 on IP: 127.0.0.1
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 Executing VBoxManage: []string{"modifyvm", "my_vm", "--nic1", "nat"}
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 stdout:
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 stderr:
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 Executing VBoxManage: []string{"modifyvm", "my_vm", "--natpf1", "packercomm,tcp,127.0.0.1,3441,,22"}
==> virtualbox-vm.vbox: Creating forwarded port mapping for communicator (SSH, WinRM, etc) (host port 3441)
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 stdout:
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 stderr: VBoxManage: error: A NAT rule of this name already exists
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: VBoxManage: error: Details: code NS_ERROR_INVALID_ARG (0x80070057), component NATEngineWrap, interface INATEngine, callee nsISupports
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: VBoxManage: error: Context: "AddRedirect(Bstr(strName).raw(), proto, Bstr(strHostIp).raw(), RTStrToUInt16(strHostPort), Bstr(strGuestIp).raw(), RTStrToUInt16(strGuestPort))" at line 1923 of file VBoxManageModifyVM.cpp
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 A packer NAT rule already exists. Trying to delete ...
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 Executing VBoxManage: []string{"modifyvm", "my_vm", "--natpf1", "delete", "packercomm"}
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 stdout:
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 stderr:
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 Executing VBoxManage: []string{"modifyvm", "my_vm", "--natpf1", "packercomm,tcp,127.0.0.1,3441,,22"}
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 stdout:
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 stderr:
==> virtualbox-vm.vbox: Starting the virtual machine...
    virtualbox-vm.vbox: view the screen of the VM, connect via VRDP without a password to
    virtualbox-vm.vbox: rdp://127.0.0.1:5944
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 Executing VBoxManage: []string{"startvm", "my_vm", "--type", "headless"}
    virtualbox-vm.vbox: The VM will be run headless, without a GUI. If you want to
    virtualbox-vm.vbox: view the screen of the VM, connect via VRDP without a password to
    virtualbox-vm.vbox: rdp://127.0.0.1:5944
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 stdout: Waiting for VM "my_vm" to power on...
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: VM "my_vm" has been successfully started.
2022/05/24 12:49:03 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:03 stderr:
==> virtualbox-vm.vbox: Waiting 10s for boot...
==> virtualbox-vm.vbox: Typing the boot command...
==> virtualbox-vm.vbox: Using SSH communicator to connect: 127.0.0.1
2022/05/24 12:49:13 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:13 [INFO] Waiting for SSH, up to timeout: 5m0s
==> virtualbox-vm.vbox: Waiting for SSH to become available...
2022/05/24 12:49:13 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:13 [INFO] Attempting SSH connection to 127.0.0.1:3441...
2022/05/24 12:49:13 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:13 [DEBUG] reconnecting to TCP connection for SSH
2022/05/24 12:49:13 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:13 [DEBUG] handshaking with SSH
2022/05/24 12:49:13 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:13 [DEBUG] SSH handshake err: ssh: handshake failed: read tcp 127.0.0.1:32934->127.0.0.1:3441: read: connection reset by peer
2022/05/24 12:49:20 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:20 [INFO] Attempting SSH connection to 127.0.0.1:3441...
2022/05/24 12:49:20 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:20 [DEBUG] reconnecting to TCP connection for SSH
2022/05/24 12:49:20 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:20 [DEBUG] handshaking with SSH
2022/05/24 12:49:20 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:20 [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/05/24 12:49:20 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:20 [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/05/24 12:49:27 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:27 [INFO] Attempting SSH connection to 127.0.0.1:3441...
2022/05/24 12:49:27 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:27 [DEBUG] reconnecting to TCP connection for SSH
2022/05/24 12:49:27 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:27 [DEBUG] handshaking with SSH
2022/05/24 12:49:27 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:27 [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/05/24 12:49:27 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:27 [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/05/24 12:49:34 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:34 [INFO] Attempting SSH connection to 127.0.0.1:3441...
2022/05/24 12:49:34 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:34 [DEBUG] reconnecting to TCP connection for SSH
2022/05/24 12:49:34 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:34 [DEBUG] handshaking with SSH
2022/05/24 12:49:34 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:34 [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/05/24 12:49:34 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:34 [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/05/24 12:49:41 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:41 [INFO] Attempting SSH connection to 127.0.0.1:3441...
2022/05/24 12:49:41 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:41 [DEBUG] reconnecting to TCP connection for SSH
2022/05/24 12:49:41 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:41 [DEBUG] handshaking with SSH
2022/05/24 12:49:41 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:41 [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/05/24 12:49:41 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:41 [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/05/24 12:49:48 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:48 [INFO] Attempting SSH connection to 127.0.0.1:3441...
2022/05/24 12:49:48 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:48 [DEBUG] reconnecting to TCP connection for SSH
2022/05/24 12:49:48 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:48 [DEBUG] handshaking with SSH
2022/05/24 12:49:48 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:48 [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/05/24 12:49:48 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:48 [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/05/24 12:49:55 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:55 [INFO] Attempting SSH connection to 127.0.0.1:3441...
2022/05/24 12:49:55 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:55 [DEBUG] reconnecting to TCP connection for SSH
2022/05/24 12:49:55 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:55 [DEBUG] handshaking with SSH
2022/05/24 12:49:55 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:55 [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/05/24 12:49:55 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:49:55 [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/05/24 12:50:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:02 [INFO] Attempting SSH connection to 127.0.0.1:3441...
2022/05/24 12:50:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:02 [DEBUG] reconnecting to TCP connection for SSH
2022/05/24 12:50:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:02 [DEBUG] handshaking with SSH
2022/05/24 12:50:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:02 [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/05/24 12:50:02 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:02 [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/05/24 12:50:09 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:09 [INFO] Attempting SSH connection to 127.0.0.1:3441...
2022/05/24 12:50:09 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:09 [DEBUG] reconnecting to TCP connection for SSH
2022/05/24 12:50:09 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:09 [DEBUG] handshaking with SSH
2022/05/24 12:50:09 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:09 [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/05/24 12:50:09 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:09 [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/05/24 12:50:16 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:16 [INFO] Attempting SSH connection to 127.0.0.1:3441...
2022/05/24 12:50:16 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:16 [DEBUG] reconnecting to TCP connection for SSH
2022/05/24 12:50:16 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:16 [DEBUG] handshaking with SSH
2022/05/24 12:50:17 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:17 [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/05/24 12:50:17 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:17 [DEBUG] Detected authentication error. Increasing handshake attempts.
2022/05/24 12:50:24 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:24 [INFO] Attempting SSH connection to 127.0.0.1:3441...
2022/05/24 12:50:24 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:24 [DEBUG] reconnecting to TCP connection for SSH
2022/05/24 12:50:24 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:24 [DEBUG] handshaking with SSH
2022/05/24 12:50:24 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:24 [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey], no supported methods remain
2022/05/24 12:50:24 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:24 [DEBUG] Detected authentication error. Increasing handshake attempts.
==> virtualbox-vm.vbox: 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
2022/05/24 12:50:24 packer-plugin-virtualbox_v1.0.2_x5.0_linux_amd64 plugin: 2022/05/24 12:50:24 Executing VBoxManage: []string{"controlvm", "my_vm", "poweroff"}

Would be grateful for any pointers if you think the issue might lie on my end :)

@nywilken
Copy link
Member

@nywilken I seem to still be running into issues with the virtualbox-vm builder despite upgrading the plugin to version 1.0.2 as per the changes in #11761. VM is Ubuntu 22.04.

@onematchfox we released a new version of packer-plugin-virtualbox today that should fix this issue. You can install the latest version of the plugin by updating the pinned version in your template and running packer init.

There will be a new nightly release of Packer in a few minutes that has been updated with all of the newly released plugins as well. We are planning to ship 1.8.1 soon.

@onematchfox
Copy link
Contributor

@onematchfox we released a new version of packer-plugin-virtualbox today that should fix this issue. You can install the latest version of the plugin by updating the pinned version in your template and running packer init.

There will be a new nightly release of Packer in a few minutes that has been updated with all of the newly released plugins as well. We are planning to ship 1.8.1 soon.

Thanks for this. I can confirm that it works fine now.

@github-actions
Copy link

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.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 26, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.