mcandre / packer-templates

Configurations for generating Vagrant base boxes
66 stars 14 forks source link

sid #355

Closed mcandre closed 5 years ago

mcandre commented 5 years ago

Prior art:

https://github.com/glisignoli/packer-debian-sid/blob/master/http/preseed.cfg

The post-install boot succeeds during the Packer build, including processing provisioning scripts via SSH. However, when the resulting box is instantiated with vagrant up, then that never forms an SSH connection. VirtualBox shows a boot error:

https://i.imgur.com/192lUob.png

Work in progress branch:

https://github.com/mcandre/packer-templates/tree/issue-355

Discussion:

https://www.reddit.com/r/debian/comments/ccipu8/gave_up_waiting_for_suspendresume_device/

Pending https://github.com/hashicorp/packer/issues/7871

mcandre commented 5 years ago

Theories for resolving boot error:

The remaining boot errors complain about an inability to find the root file system. Screenshot:

https://i.imgur.com/CVrmPce.png

mcandre commented 5 years ago

SSH is presenting a local version string, but no prompt. The connection later times out.

$ ssh -vvv vagrant@localhost -p 3945
OpenSSH_7.9p1, LibreSSL 2.7.3
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 48: Applying options for *
debug1: /etc/ssh/ssh_config line 52: Applying options for *
debug1: Connecting to localhost port 3945.
debug1: Connection established.
debug1: identity file /Users/andrew/.ssh/id_rsa type 0
debug1: identity file /Users/andrew/.ssh/id_rsa-cert type -1
debug1: identity file /Users/andrew/.ssh/id_dsa type -1
debug1: identity file /Users/andrew/.ssh/id_dsa-cert type -1
debug1: identity file /Users/andrew/.ssh/id_ecdsa type -1
debug1: identity file /Users/andrew/.ssh/id_ecdsa-cert type -1
debug1: identity file /Users/andrew/.ssh/id_ed25519 type -1
debug1: identity file /Users/andrew/.ssh/id_ed25519-cert type -1
debug1: identity file /Users/andrew/.ssh/id_xmss type -1
debug1: identity file /Users/andrew/.ssh/id_xmss-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_7.9

(a few minutes later)

ssh_exchange_identification: read: Connection reset by peer
mcandre commented 5 years ago

Applying preseed.cfg parameters to disable LVM and UUID mounts:

d-i partman-auto/method string regular
d-i partman-auto/choose_recipe select atomic
d-i partman-partitioning/confirm_write_new_label boolean true
d-i partman/choose_partition select finish
d-i partman/confirm boolean true
d-i partman/confirm_nooverwrite boolean true
d-i partman/mount_style select traditional

However, the installation now fails with:

base-installer: error: exiting on error base-installer/debootstrap-failed
main-menu[203]: WARNING **: Configuring 'bootstrap-base' failed with error code 30

Meh, this is sid. Wait at least one day and retry.

mcandre commented 5 years ago