On 12/01/2026 21.40, Daniel P. Berrangé wrote:
The I/O test 128 uses 'dmsetup create' to create a device, optionally
using sudo to elevate privileges.

This works in GitLab CI, however, the resulting device never appears
in /dev leading the test to fail:

   1..1
   # running raw 128
   not ok raw 128
   ----------------------------------- stderr 
-----------------------------------
   --- /builds/berrange/qemu/tests/qemu-iotests/128.out
   +++ /builds/berrange/qemu/build/scratch/raw-file-128/128.out.bad
   @@ -1,5 +1,5 @@
    QA output created by 128

    == reading from error device ==
   -read failed: Input/output error
   +qemu-io: can't open device /dev/mapper/eiodev16546: Could not open 
'/dev/mapper/eiodev16546': No such file or directory
    *** done

   (test program exited with status code 1)

Most likely the container environment the tests are being run under
has a hand-populated /dev such that newly created devices from device
mapper won't automatically appear.

Signed-off-by: Daniel P. Berrangé <[email protected]>
---
  tests/qemu-iotests/128 | 2 ++
  1 file changed, 2 insertions(+)

diff --git a/tests/qemu-iotests/128 b/tests/qemu-iotests/128
index d0e00d24b1..b32e03beee 100755
--- a/tests/qemu-iotests/128
+++ b/tests/qemu-iotests/128
@@ -73,6 +73,8 @@ _supported_fmt raw
  _supported_proto file
  _supported_os Linux
+test -n "$GITLAB_CI" && _notrun "dmsetup not functional on GitLab CI runners"
+
  _setup_eiodev
TEST_IMG="/dev/mapper/$devname"

Could we maybe better check for the existance of $TEST_IMG for deciding whether to skip the test? ... so that this is also properly skipped in other container environments where /dev might not be populated right?

 Thomas


Reply via email to