Ubuntu – virt-install preseed not working

ansibleinstallationUbuntuvirsh

I have setup a pre-seed for the vm install but it still asks me for location first.

My vm install is being trigger by a bash script create_vm.sh:

virt-install --name test \
    --boot uefi \
    --machine q35 \
    --ram 16384 \
    --disk path=/mnt/vms/images.img,format-qcow2 \
    --vcpus 4 \
    --os-type linux \
    --network bridge:br0,model=virtio \
    --graphics none \
    --console pty,target_type=serial \
    --location='http://au.archive.ubuntu.com/ubuntu/dists/xenial/main/installer-amd64/' \
    --extra-args='ks=file:/preseed_test.cfg console=tty50,115200n8 serial' \
    --initrd-inject=/tmp/preseed_test.cfg \
    --virt-type kvm

in my preseed, I have:

### localisation
d-i debian-installer/language string en
d-i debian-installer/country string AU
d-i debian-installer/locale string en_GB.UTF-8

but these questions still pop up?
why is that?

the rest of the preseed seems to work though.

Best Answer

I had the same issue just now.. I believe that locale sets the country and language - and it looks like you're setting the country using the country field differently to the country used in the locale field

I didn't test setting all 3 options at once, I just moved to setting only the locale to en_AU.UTF-8