On 2022-01-02 16:21, Christian Kastner wrote:
> It looks as if one of the necessary consoles is not set up properly on
> armhf (it worked fine for me on arm64):

Addendum: I'm now occasionally also seeing this with arm64 when using
sbuild with --chroot-mode=autopkgtest. I'd say it's 50/50 between
success and failure.

>   | host login: autopkgtest-virt-qemu: DBG: expect: found "'login prompt on 
> serial console'"
>   | autopkgtest-virt-qemu: DBG: expect: b'ok'
>   | autopkgtest-virt-qemu: DBG: setup_shell(): no default shell on hvc1 or 
> ttyS1
>   | qemu-system-arm: terminating on signal 15 from pid 1316826 
> (/usr/bin/python3)
>   | autopkgtest-virt-qemu: DBG: cleanup...
>   | <VirtSubproc>: failure: The VM does not start a root shell on ttyS1 or 
> hvc1 already. The only other supported login mechanism is through --user and 
> --password on the guest ttyS0


With just autopkgtest, so far it's been 100% success with arm64 and 100%
failure with armhf.

I have no idea why success or failure isn't deterministic with
sbuild+autopkgtest; the invocation is always the same. The failure seems
to happen in check_root_shell() of /usr/bin/autopkgtest-virt-qemu.
There's a 1s timeout in there, I increased it to 10s but that didn't
change anything.

This is what I see with a successful execution:

> autopkgtest-virt-qemu: DBG: expect: b' login: '
> autopkgtest-virt-qemu: DBG: expect: found "'login prompt on serial console'"
> autopkgtest-virt-qemu: DBG: expect: b'ok'
> autopkgtest-virt-qemu: DBG: expect: found "b'ok'"
> autopkgtest-virt-qemu: DBG: setup_shell(): there already is a shell on hvc1

This is what I see when execution fails:

> autopkgtest-virt-qemu: DBG: expect: b' login: '
> autopkgtest-virt-qemu: DBG: expect: found "'login prompt on serial console'"
> autopkgtest-virt-qemu: DBG: expect: b'ok'
> autopkgtest-virt-qemu: DBG: setup_shell(): no default shell on hvc1 or ttyS1
> qemu-system-aarch64: terminating on signal 15 from pid 2939437 
> (/usr/bin/python3)
> autopkgtest-virt-qemu: DBG: cleanup...
> <VirtSubproc>: failure: The VM does not start a root shell on ttyS1 or hvc1 
> already. The only other supported login mechanism is through --user and 
> --password on the guest ttyS0
> Undefined return value after 'open'

This is how I invoke sbuild with autopkgtest chroot mode:

$ sbuild --arch arm64 --dist unstable \
        --bd-uninstallable-explainer apt \
        --chroot-mode=autopkgtest --autopkgtest-virt-server=qemu \
        --autopkgtest-virt-server-opt --overlay-dir=/tmp \
        --autopkgtest-virt-server-opt --qemu-architecture=aarch64 \
        --autopkgtest-virt-server-opt --ram-size=2048 \
        --autopkgtest-virt-server-opt --cpus=4 \
        --autopkgtest-virt-server-opt=--debug \
        --autopkgtest-virt-server-opt IMAGEFILE src.dsc

Reply via email to