Hi,
Quoting Johannes Schauer (2020-02-22 08:14:55)
> Quoting Francesco Poli (2020-02-21 23:14:12)
> > I modified my script (see the current version attached to this message) and
> > tried again.
> >
> > $ env | grep SOURCE
> > SOURCE_DATE_EPOCH=1582320746
> > $ mmdebstrap-autopkgtest-qemu
> > [...]
> > I: removing tempdir ${HOME}/Downloads/TEST/mmdebstrap.vt5NxWQb_6...
> > libguestfs: error: /usr/bin/supermin exited with error status 1.
> > To see full error messages you may need to enable debugging.
> > Do:
> > export LIBGUESTFS_DEBUG=1 LIBGUESTFS_TRACE=1
> > and run the command again. For further information, read:
> > http://libguestfs.org/guestfs-faq.1.html#debugging-libguestfs
> > You can also run 'libguestfs-test-tool' and post the *complete* output
> > into a bug report or message to the libguestfs mailing list.
>
> did you try running guestfish with these env variables to figure out what's
> wrong?
>
> > The qcow2 image is suspiciously small:
> >
> > $ ls --si -l debian-unstable.*
> > -rw-rw---- 1 $USER $GROUP 2.2G Feb 21 22:34 debian-unstable.img
> > -rw-r----- 1 $USER $GROUP 197k Feb 21 22:34 debian-unstable.qcow2
> > -rw-r--r-- 1 $USER $GROUP 629M Feb 21 22:34 debian-unstable.tar
> >
> > and actually fails to boot (but for different reasons, with respect to
> > the previous attempt), see the attached screenshot.
> > I tried both the qcow2 image and the raw image:
> >
> > $ qemu-system-x86_64 -enable-kvm -m 512 -serial
> > unix:/tmp/ttyS0,server,nowait -drive
> > "file=./debian-unstable.qcow2,cache=unsafe,if=virtio,index=0"
> > $ qemu-system-x86_64 -enable-kvm -m 512 -serial
> > unix:/tmp/ttyS0,server,nowait -drive
> > "file=./debian-unstable.img,format=raw,cache=unsafe,if=virtio,index=0"
> >
> > with identical results: after attempting all possible boot devices
> > (including a network boot!), it bails out with "No bootable device"
> > error message.
> >
> > I also tried:
> >
> > $ export LIBGUESTFS_DEBUG=1 LIBGUESTFS_TRACE=1
> > $ SIZE="2GiB"
> > $ guestfish --new debian-unstable_DEBUG.img=disk:"$SIZE" -- \
> > part-disk /dev/sda mbr : \
> > part-set-bootable /dev/sda 1 true : \
> > mkfs ext2 /dev/sda1 : mount /dev/sda1 / : \
> > tar-in debian-unstable.tar / : \
> > extlinux / : \
> > copy-in extlinux.conf / : \
> > sync : umount / : shutdown
> >
> > which produced an unmanageable quantity of output strings, with an
> > apparently endless stream line pairs identical to:
> >
> > guestfsd: receive_file: reading length word
> > guestfsd: receive_file: got chunk: cancel = 0x0, len = 8192, buf =
> > 0x560e1b866690
> >
> > until I hit [Ctrl+C]...
> >
> > Does it make any sense?
>
> No, it doesn't I have never seen the effects you see.
>
> I have more ideas but I think you first somehow have to fix the guestfish
> problems that you are experiencing. What version of Debian and guestfish are
> you running?for what it's worth I'm attaching the script I am using to re-generate my autopkgtest qemu image. I uploaded a few packages today and just successfully used that script so I can confirm it working. Thanks! cheers, josch
#!/bin/sh set -exu #sudo vmdebootstrap --verbose --serial-console --distribution=sid --customize=/usr/share/autopkgtest/setup-commands/setup-testbed --user=test/test --size=2000000000 --grub --mirror=http://127.0.0.1:3142/httpredir.debian.org/debian/ --configure-apt --apt-mirror=http://10.0.2.2:3142/httpredir.debian.org/debian/ --image=autopkgtest-sid.raw #qemu-img convert -O qcow2 autopkgtest-sid.raw autopkgtest-sid.img #qemu-system-x86_64 -m 500M -enable-kvm /srv/qemu/unstable-amd64-autopkgtest.qcow2 ./mmdebstrap --mode=unshare --variant=important --include=linux-image-amd64 --customize-hook='chroot "$1" passwd --delete root' --customize-hook='chroot "$1" useradd --home-dir /home/user --create-home user' --customize-hook='chroot "$1" passwd --delete user' --customize-hook='echo host > "$1/etc/hostname"' --customize-hook='echo "127.0.0.1 localhost host" > "$1/etc/hosts"' --customize-hook=/usr/share/autopkgtest/setup-commands/setup-testbed unstable debian-unstable.tar cat << END > extlinux.conf default linux timeout 0 label linux kernel /vmlinuz append initrd=/initrd.img root=/dev/vda1 rw console=ttyS0 END guestfish -N debian-unstable.img=disk:2G -- part-disk /dev/sda mbr : part-set-bootable /dev/sda 1 true : mkfs ext2 /dev/sda1 : mount /dev/sda1 / : tar-in debian-unstable.tar / : extlinux / : copy-in extlinux.conf / qemu-img convert -O qcow2 debian-unstable.img debian-unstable.qcow2 sudo mv debian-unstable.qcow2 /srv/qemu/unstable-amd64-autopkgtest.qcow2 rm debian-unstable.img debian-unstable.tar
signature.asc
Description: signature

