avocado-framework / avocado-vt

Avocado VT Plugin
https://avocado-vt.readthedocs.org/
Other
84 stars 243 forks source link

unattended_install ERROR: list index out of range #3380

Open vducuy opened 2 years ago

vducuy commented 2 years ago

I installed fresh Fedora Core 35 on aarch64 and start to install avocado, avocado-vt, bootstrap with Fedora 35 config and kickstart. but when run following command I got issue: ERROR: list index out of range

# avocado run \
        unattended_install.url.http_ks.default_install.aio_native \
        --vt-type qemu \
        --vt-guest-os Fedora.35.aarch64 \
        --vt-machine-type arm64-mmio
JOB ID     : d73b7d447eedb52141579d1000e25cae40c5dc49
JOB LOG    : /root/avocado/job-results/job-2022-03-22T06.30-d73b7d4/job.log
 (1/1) io-github-autotest-qemu.unattended_install.url.http_ks.default_install.aio_native: STARTED
 (1/1) io-github-autotest-qemu.unattended_install.url.http_ks.default_install.aio_native: ERROR: list index out of range (3.75 s)

In debug file can see

[stdlog] 2022-03-22 06:30:53,763 avocado.test ERROR|
[stdlog] 2022-03-22 06:30:53,763 avocado.test ERROR| Reproduced traceback from: /usr/local/lib/python3.10/site-packages/avocado_vt/test.py:275
[stdlog] 2022-03-22 06:30:53,765 avocado.test ERROR| Traceback (most recent call last):
[stdlog] 2022-03-22 06:30:53,765 avocado.test ERROR|   File "/home/avocado/data/avocado-vt/virttest/test-providers.d/downloads/io-github-autotest-qemu/generic/tests/unattended_install.py", line 24, in run
[stdlog] 2022-03-22 06:30:53,765 avocado.test ERROR|     unattended_install.run(test, params, env)
[stdlog] 2022-03-22 06:30:53,765 avocado.test ERROR|   File "/usr/local/lib/python3.10/site-packages/virttest/error_context.py", line 135, in new_fn
[stdlog] 2022-03-22 06:30:53,765 avocado.test ERROR|     return fn(*args, **kwargs)
[stdlog] 2022-03-22 06:30:53,765 avocado.test ERROR|   File "/usr/local/lib/python3.10/site-packages/virttest/tests/unattended_install.py", line 1339, in run
[stdlog] 2022-03-22 06:30:53,765 avocado.test ERROR|     vm.create(params=params)
[stdlog] 2022-03-22 06:30:53,765 avocado.test ERROR|   File "/usr/local/lib/python3.10/site-packages/virttest/error_context.py", line 135, in new_fn
[stdlog] 2022-03-22 06:30:53,766 avocado.test ERROR|     return fn(*args, **kwargs)
[stdlog] 2022-03-22 06:30:53,766 avocado.test ERROR|   File "/usr/local/lib/python3.10/site-packages/virttest/qemu_vm.py", line 2880, in create
[stdlog] 2022-03-22 06:30:53,766 avocado.test ERROR|     self.redirs[guest_port] = host_ports[i]
[stdlog] 2022-03-22 06:30:53,766 avocado.test ERROR| IndexError: list index out of range
[stdlog] 2022-03-22 06:30:53,766 avocado.test ERROR|

I recalled i can run this before, but this time can not run it, Do i missed something?

vducuy commented 2 years ago

after checked on my system and see qemu_vm can not get list of Port redirections

            Handle port redirections
            redir_names = params.objects("redirs")
            host_ports = utils_misc.find_free_ports(
                5000, 5899, len(redir_names))

utils_misc.find_free_port() return empty, the reason is socket error with code 97

vducuy commented 2 years ago

The problem found, removed ipv6.disable=1 in grub.cfg