qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Christian Borntraeger <borntraeger@linux.ibm.com>
To: Hanna Reitz <hreitz@redhat.com>, qemu-block@nongnu.org
Cc: qemu-devel@nongnu.org, Kevin Wolf <kwolf@redhat.com>
Subject: Re: [PATCH v2] tests/stream-under-throttle: New test
Date: Wed, 7 Dec 2022 11:31:23 +0100	[thread overview]
Message-ID: <a917bcb9-a430-3754-8752-d4df09bce710@linux.ibm.com> (raw)
In-Reply-To: <20221114095226.20917-1-hreitz@redhat.com>

Am 14.11.22 um 10:52 schrieb Hanna Reitz:
> Test streaming a base image into the top image underneath two throttle
> nodes.  This was reported to make qemu 7.1 hang
> (https://gitlab.com/qemu-project/qemu/-/issues/1215), so this serves as
> a regression test.
> 
> Signed-off-by: Hanna Reitz <hreitz@redhat.com>
> ---
> Based-on: <20221107151321.211175-1-hreitz@redhat.com>
> 
> v1: https://lists.nongnu.org/archive/html/qemu-block/2022-11/msg00368.html
> 
> v2:
> - Replace `asyncio.exceptions.TimeoutError` by `asyncio.TimeoutError`:
>    Stefan reported that the CI does not recognize the former:
>    https://lists.nongnu.org/archive/html/qemu-block/2022-11/msg00424.html
> 
>    As far as I understand, the latter was basically moved to become the
>    former in Python 3.11, and an alias remains, so both are basically
>    equivalent.  I only have 3.10, though, where the documentation says
>    that both are different, even though using either seems to work fine
>    (i.e. both catch the timeout there).  Not sure about previous
>    versions, but the CI seems pretty certain about not knowing
>    `asyncio.exceptions.TimeoutError`, so use `asyncio.TimeoutError`
>    instead.  (Even though that is deprecated in 3.11, but this is not the
>    first place in the tree to use it, so it should not be too bad.)
> ---
>   .../qemu-iotests/tests/stream-under-throttle  | 121 ++++++++++++++++++
>   .../tests/stream-under-throttle.out           |   5 +
>   2 files changed, 126 insertions(+)
>   create mode 100755 tests/qemu-iotests/tests/stream-under-throttle
>   create mode 100644 tests/qemu-iotests/tests/stream-under-throttle.out

As a heads up, I do get the following on s390. I have not yet looked into that:

+EE
+======================================================================
+ERROR: test_stream (__main__.TestStreamWithThrottle)
+Do a simple stream beneath the two throttle nodes.  Should complete
+----------------------------------------------------------------------
+Traceback (most recent call last):
+  File "qemu/tests/qemu-iotests/tests/stream-under-throttle", line 110, in test_stream
+    self.vm.run_job('stream')
+  File "qemu/tests/qemu-iotests/iotests.py", line 986, in run_job
+    result = self.qmp('query-jobs')
+  File "qemu/python/qemu/machine/machine.py", line 646, in qmp
+    ret = self._qmp.cmd(cmd, args=qmp_args)
+  File "qemu/python/qemu/qmp/legacy.py", line 204, in cmd
+    return self.cmd_obj(qmp_cmd)
+  File "qemu/python/qemu/qmp/legacy.py", line 184, in cmd_obj
+    self._qmp._raw(qmp_cmd, assign_id=False),
+  File "qemu/python/qemu/qmp/protocol.py", line 154, in _wrapper
+    raise StateError(emsg, proto.runstate, required_state)
+qemu.qmp.protocol.StateError: QMPClient is disconnecting. Call disconnect() to return to IDLE state.
+
+======================================================================
+ERROR: test_stream (__main__.TestStreamWithThrottle)
+Do a simple stream beneath the two throttle nodes.  Should complete
+----------------------------------------------------------------------
+Traceback (most recent call last):
+  File "qemu/python/qemu/machine/machine.py", line 533, in _soft_shutdown
+    self.qmp('quit')
+  File "qemu/python/qemu/machine/machine.py", line 646, in qmp
+    ret = self._qmp.cmd(cmd, args=qmp_args)
+  File "qemu/python/qemu/qmp/legacy.py", line 204, in cmd
+    return self.cmd_obj(qmp_cmd)
+  File "qemu/python/qemu/qmp/legacy.py", line 184, in cmd_obj
+    self._qmp._raw(qmp_cmd, assign_id=False),
+  File "qemu/python/qemu/qmp/protocol.py", line 154, in _wrapper
+    raise StateError(emsg, proto.runstate, required_state)
+qemu.qmp.protocol.StateError: QMPClient is disconnecting. Call disconnect() to return to IDLE state.
+
+During handling of the above exception, another exception occurred:
+
+Traceback (most recent call last):
+  File "qemu/python/qemu/machine/machine.py", line 554, in _do_shutdown
+    self._soft_shutdown(timeout)
+  File "qemu/python/qemu/machine/machine.py", line 536, in _soft_shutdown
+    self._close_qmp_connection()
+  File "qemu/python/qemu/machine/machine.py", line 476, in _close_qmp_connection
+    self._qmp.close()
+  File "qemu/python/qemu/qmp/legacy.py", line 277, in close
+    self._sync(
+  File "qemu/python/qemu/qmp/legacy.py", line 94, in _sync
+    return self._aloop.run_until_complete(
+  File "/usr/lib64/python3.10/asyncio/base_events.py", line 649, in run_until_complete
+    return future.result()
+  File "/usr/lib64/python3.10/asyncio/tasks.py", line 408, in wait_for
+    return await fut
+  File "qemu/python/qemu/qmp/protocol.py", line 398, in disconnect
+    await self._wait_disconnect()
+  File "qemu/python/qemu/qmp/protocol.py", line 710, in _wait_disconnect
+    await all_defined_tasks  # Raise Exceptions from the bottom half.
+  File "qemu/python/qemu/qmp/protocol.py", line 861, in _bh_loop_forever
+    await async_fn()
+  File "qemu/python/qemu/qmp/protocol.py", line 899, in _bh_recv_message
+    msg = await self._recv()
+  File "qemu/python/qemu/qmp/protocol.py", line 1000, in _recv
+    message = await self._do_recv()
+  File "qemu/python/qemu/qmp/qmp_client.py", line 402, in _do_recv
+    msg_bytes = await self._readline()
+  File "qemu/python/qemu/qmp/protocol.py", line 968, in _readline
+    raise EOFError
+EOFError
+
+The above exception was the direct cause of the following exception:
+
+Traceback (most recent call last):
+  File "qemu/tests/qemu-iotests/tests/stream-under-throttle", line 94, in tearDown
+    self.vm.shutdown()
+  File "qemu/python/qemu/machine/machine.py", line 583, in shutdown
+    self._do_shutdown(timeout)
+  File "qemu/python/qemu/machine/machine.py", line 557, in _do_shutdown
+    raise AbnormalShutdown("Could not perform graceful shutdown") \
+qemu.machine.machine.AbnormalShutdown: Could not perform graceful shutdown
+
  ----------------------------------------------------------------------
  Ran 1 tests


  reply	other threads:[~2022-12-07 10:32 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-14  9:52 [PATCH v2] tests/stream-under-throttle: New test Hanna Reitz
2022-12-07 10:31 ` Christian Borntraeger [this message]
2022-12-07 12:56   ` Christian Borntraeger
2022-12-07 13:00     ` Christian Borntraeger

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=a917bcb9-a430-3754-8752-d4df09bce710@linux.ibm.com \
    --to=borntraeger@linux.ibm.com \
    --cc=hreitz@redhat.com \
    --cc=kwolf@redhat.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).