in

Packer Ubuntu 21.10 initramfs unpacking failed write error


I’m trying to create a VMI using the official Ubuntu 21.10 iso using Packer. I’m getting the following error:

I’m using the following configuration (preseed taken from official LTS, not sure if it is suitable for 21.10):

config.json

{
  "builders": [
    {
      "boot_command": [
        "<esc><wait>",
        "<esc><wait>",
        "<enter><wait>",
        "/install/vmlinuz<wait>",
        " initrd=/install/initrd.gz",
        " auto-install/enable=true",
        " debconf/priority=critical",
        " netcfg/get_domain=vm<wait>",
        " netcfg/get_hostname=vagrant<wait>",
        " grub-installer/bootdev=/dev/sda<wait>",
        " preseed/url=http://{{ .HTTPIP }}:{{ .HTTPPort }}/preseed.cfg<wait>",
        " -- <wait>",
        "<enter><wait>"
      ],
      "boot_wait": "10s",
      "guest_os_type": "ubuntu-64",
      "guest_additions_mode": "disable",
      "disk_size": 8192,
      "http_directory": "http",
      "iso_url": "https://releases.ubuntu.com/21.10/ubuntu-21.10-desktop-amd64.iso",
      "iso_checksum": "sha256:f8d3ab0faeaecb5d26628ae1aa21c9a13e0a242c381aa08157db8624d574b830",
      "shutdown_command": "echo 'vagrant' | sudo -S shutdown -P now",
      "ssh_password": "vagrant",
      "ssh_username": "vagrant",
      "ssh_wait_timeout": "10000s",
      "type": "virtualbox-iso",
      "vm_name": "test-ubuntu"
    }
  ],
  "post-processors": [
    { "type": "vagrant",  
      "compression_level": 1,  
      "override": {    
        "virtualbox": {      
          "compression_level": 0    
        }  
      }
    }
  ]
}

./http/preseed.cfg

d-i debian-installer/locale string en_US
d-i console-setup/ask_detect boolean false
d-i keyboard-configuration/xkb-keymap select us
d-i netcfg/choose_interface select auto
d-i netcfg/get_hostname string unassigned-hostname
d-i netcfg/get_domain string unassigned-domain
d-i netcfg/wireless_wep string
d-i mirror/country string manual
d-i mirror/http/hostname string archive.ubuntu.com
d-i mirror/http/directory string /ubuntu
d-i mirror/http/proxy string
d-i user-setup/encrypt-home boolean false
d-i clock-setup/utc boolean true
d-i time/zone string US/Eastern
d-i clock-setup/ntp boolean true
d-i partman-auto/method string lvm
d-i partman-lvm/device_remove_lvm boolean true
d-i partman-md/device_remove_md boolean true
d-i partman-lvm/confirm boolean true
d-i partman-lvm/confirm_nooverwrite boolean true
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-md/confirm boolean true
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
tasksel tasksel/first multiselect ubuntu-desktop
d-i grub-installer/only_debian boolean true
d-i grub-installer/with_other_os boolean true
d-i finish-install/reboot_in_progress note

I’m pretty sure the problem is in something petty, but I can’t figure it out.



Source: https://stackoverflow.com/questions/70535775/packer-ubuntu-21-10-initramfs-unpacking-failed-write-error

Google Assistant and Lens had a quiet 2021 as foundational advancements remain in the wings thumbnail

Google Assistant and Lens had a quiet 2021 as foundational advancements remain in the wings

Python Wrapper for interacting with the Flutterwave API