OpenBSD: Block layer fixes (was 'Enable qtesting')
v3 cover OpenBSD: Block layer fixes (was 'Enable qtesting')
Various fixes I encountered while trying to run QEMU test suite on OpenBSD.
This is the 'block' part of the v2.
Most non-RFC patches are reviewed and could be applied.
Since v2:
- Added R-b tags
- Addressed Eric's comments (in code and commit descriptions)
Since v1:
- various qemu-block fixes and notes.
Regards,
Phil.
v2: https://lists.gnu.org/archive/html/qemu-devel/2019-01/msg07513.html
v1: https://lists.gnu.org/archive/html/qemu-devel/2019-01/msg06676.html
Philippe Mathieu-Daudé (8):
ahci-test: Add dependency to qemu-img tool
qemu-iotests: Add dependency to qemu-nbd tool
qemu-iotests: Improve portability by searching bash in the $PATH
qemu-iotests: Ensure GNU sed is used
iotests: Let verify_platform() check for unsupported platforms RFC iotests: Disable 208 on OpenBSD
RFC iotests: Disable 209 on OpenBSD
RFC iotests: Disable 236 and 238 on OpenBSD
tests/Makefile.include | 4 ++-- tests/qemu-iotests/001 | 2 +- tests/qemu-iotests/002 | 2 +- tests/qemu-iotests/003 | 2 +- tests/qemu-iotests/004 | 2 +- tests/qemu-iotests/005 | 2 +- tests/qemu-iotests/007 | 2 +- tests/qemu-iotests/008 | 2 +- tests/qemu-iotests/009 | 2 +- tests/qemu-iotests/010 | 2 +- tests/qemu-iotests/011 | 2 +- tests/qemu-iotests/012 | 2 +- tests/qemu-iotests/013 | 2 +- tests/qemu-iotests/014 | 2 +- tests/qemu-iotests/015 | 2 +- tests/qemu-iotests/017 | 2 +- tests/qemu-iotests/018 | 2 +- tests/qemu-iotests/019 | 2 +- tests/qemu-iotests/020 | 2 +- tests/qemu-iotests/021 | 2 +- tests/qemu-iotests/022 | 2 +- tests/qemu-iotests/023 | 2 +- tests/qemu-iotests/024 | 2 +- tests/qemu-iotests/025 | 2 +- tests/qemu-iotests/026 | 2 +- tests/qemu-iotests/027 | 2 +- tests/qemu-iotests/028 | 2 +- tests/qemu-iotests/029 | 2 +- tests/qemu-iotests/031 | 2 +- tests/qemu-iotests/032 | 2 +- tests/qemu-iotests/033 | 2 +- tests/qemu-iotests/034 | 2 +- tests/qemu-iotests/035 | 2 +- tests/qemu-iotests/036 | 2 +- tests/qemu-iotests/037 | 2 +- tests/qemu-iotests/038 | 2 +- tests/qemu-iotests/039 | 2 +- tests/qemu-iotests/042 | 2 +- tests/qemu-iotests/043 | 2 +- tests/qemu-iotests/046 | 2 +- tests/qemu-iotests/047 | 2 +- tests/qemu-iotests/048 | 2 +- tests/qemu-iotests/049 | 2 +- tests/qemu-iotests/050 | 2 +- tests/qemu-iotests/051 | 2 +- tests/qemu-iotests/052 | 2 +- tests/qemu-iotests/053 | 2 +- tests/qemu-iotests/054 | 2 +- tests/qemu-iotests/058 | 2 +- tests/qemu-iotests/059 | 2 +- tests/qemu-iotests/060 | 2 +- tests/qemu-iotests/061 | 2 +- tests/qemu-iotests/062 | 2 +- tests/qemu-iotests/063 | 2 +- tests/qemu-iotests/064 | 2 +- tests/qemu-iotests/066 | 2 +- tests/qemu-iotests/067 | 2 +- tests/qemu-iotests/068 | 2 +- tests/qemu-iotests/069 | 2 +- tests/qemu-iotests/070 | 2 +- tests/qemu-iotests/071 | 2 +- tests/qemu-iotests/072 | 2 +- tests/qemu-iotests/073 | 2 +- tests/qemu-iotests/074 | 2 +- tests/qemu-iotests/075 | 2 +- tests/qemu-iotests/076 | 2 +- tests/qemu-iotests/077 | 2 +- tests/qemu-iotests/078 | 2 +- tests/qemu-iotests/079 | 2 +- tests/qemu-iotests/080 | 2 +- tests/qemu-iotests/081 | 2 +- tests/qemu-iotests/082 | 2 +- tests/qemu-iotests/083 | 2 +- tests/qemu-iotests/084 | 2 +- tests/qemu-iotests/085 | 2 +- tests/qemu-iotests/086 | 2 +- tests/qemu-iotests/087 | 2 +- tests/qemu-iotests/088 | 2 +- tests/qemu-iotests/089 | 2 +- tests/qemu-iotests/090 | 2 +- tests/qemu-iotests/091 | 2 +- tests/qemu-iotests/092 | 2 +- tests/qemu-iotests/094 | 2 +- tests/qemu-iotests/095 | 2 +- tests/qemu-iotests/097 | 2 +- tests/qemu-iotests/098 | 2 +- tests/qemu-iotests/099 | 2 +- tests/qemu-iotests/101 | 2 +- tests/qemu-iotests/102 | 2 +- tests/qemu-iotests/103 | 2 +- tests/qemu-iotests/104 | 2 +- tests/qemu-iotests/105 | 2 +- tests/qemu-iotests/106 | 2 +- tests/qemu-iotests/107 | 2 +- tests/qemu-iotests/108 | 2 +- tests/qemu-iotests/109 | 2 +- tests/qemu-iotests/110 | 2 +- tests/qemu-iotests/111 | 2 +- tests/qemu-iotests/112 | 2 +- tests/qemu-iotests/113 | 2 +- tests/qemu-iotests/114 | 2 +- tests/qemu-iotests/115 | 2 +- tests/qemu-iotests/116 | 2 +- tests/qemu-iotests/117 | 2 +- tests/qemu-iotests/119 | 2 +- tests/qemu-iotests/120 | 2 +- tests/qemu-iotests/121 | 2 +- tests/qemu-iotests/122 | 2 +- tests/qemu-iotests/123 | 2 +- tests/qemu-iotests/125 | 2 +- tests/qemu-iotests/126 | 2 +- tests/qemu-iotests/127 | 2 +- tests/qemu-iotests/128 | 2 +- tests/qemu-iotests/130 | 2 +- tests/qemu-iotests/131 | 2 +- tests/qemu-iotests/133 | 2 +- tests/qemu-iotests/134 | 2 +- tests/qemu-iotests/135 | 2 +- tests/qemu-iotests/137 | 2 +- tests/qemu-iotests/138 | 2 +- tests/qemu-iotests/140 | 2 +- tests/qemu-iotests/141 | 2 +- tests/qemu-iotests/142 | 2 +- tests/qemu-iotests/143 | 2 +- tests/qemu-iotests/144 | 2 +- tests/qemu-iotests/145 | 2 +- tests/qemu-iotests/146 | 2 +- tests/qemu-iotests/150 | 2 +- tests/qemu-iotests/153 | 2 +- tests/qemu-iotests/154 | 2 +- tests/qemu-iotests/156 | 2 +- tests/qemu-iotests/157 | 2 +- tests/qemu-iotests/158 | 2 +- tests/qemu-iotests/159 | 2 +- tests/qemu-iotests/160 | 2 +- tests/qemu-iotests/161 | 2 +- tests/qemu-iotests/162 | 2 +- tests/qemu-iotests/170 | 2 +- tests/qemu-iotests/171 | 2 +- tests/qemu-iotests/172 | 2 +- tests/qemu-iotests/173 | 2 +- tests/qemu-iotests/174 | 2 +- tests/qemu-iotests/175 | 2 +- tests/qemu-iotests/176 | 2 +- tests/qemu-iotests/177 | 2 +- tests/qemu-iotests/178 | 2 +- tests/qemu-iotests/179 | 2 +- tests/qemu-iotests/181 | 2 +- tests/qemu-iotests/182 | 2 +- tests/qemu-iotests/183 | 2 +- tests/qemu-iotests/184 | 2 +- tests/qemu-iotests/185 | 2 +- tests/qemu-iotests/186 | 2 +- tests/qemu-iotests/187 | 2 +- tests/qemu-iotests/188 | 2 +- tests/qemu-iotests/189 | 2 +- tests/qemu-iotests/190 | 2 +- tests/qemu-iotests/191 | 2 +- tests/qemu-iotests/192 | 2 +- tests/qemu-iotests/195 | 2 +- tests/qemu-iotests/197 | 2 +- tests/qemu-iotests/198 | 2 +- tests/qemu-iotests/200 | 2 +- tests/qemu-iotests/201 | 2 +- tests/qemu-iotests/204 | 2 +- tests/qemu-iotests/208 | 1 + tests/qemu-iotests/209 | 1 + tests/qemu-iotests/214 | 2 +- tests/qemu-iotests/215 | 2 +- tests/qemu-iotests/217 | 2 +- tests/qemu-iotests/220 | 2 +- tests/qemu-iotests/221 | 2 +- tests/qemu-iotests/223 | 2 +- tests/qemu-iotests/225 | 2 +- tests/qemu-iotests/226 | 2 +- tests/qemu-iotests/227 | 2 +- tests/qemu-iotests/229 | 2 +- tests/qemu-iotests/231 | 2 +- tests/qemu-iotests/232 | 2 +- tests/qemu-iotests/233 | 2 +- tests/qemu-iotests/236 | 1 + tests/qemu-iotests/238 | 2 ++ tests/qemu-iotests/check | 2 +- tests/qemu-iotests/common.config | 2 +- tests/qemu-iotests/common.filter | 38 +++++++++++++++---------------- tests/qemu-iotests/common.nbd | 2 +- tests/qemu-iotests/common.pattern | 2 +- tests/qemu-iotests/common.qemu | 2 +- tests/qemu-iotests/common.rc | 15 +++++++++++- tests/qemu-iotests/common.tls | 2 +- tests/qemu-iotests/iotests.py | 4 +++- 191 files changed, 226 insertions(+), 206 deletions(-)
Signature · 1 line
2.20.1
PATCH v3 1/8 ahci-test: Add dependency to qemu-img tool
Since the ahci-test uses qemu-img, add a dependency to build it before using it.
This fixes:
$ gmake check-qtest V=1 QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/ahci-test Failed to execute child process "/tmp/qemu-test.19tMRF/qemu-img" (No such file or directory) ERROR:tests/libqos/libqos.c:192:mkimg: assertion failed: (ret && !err)
---
Slighly related is when vm-tests expect qemu-img available:
https://lists.gnu.org/archive/html/qemu-devel/2018-06/msg08415.html
$ make vm-build-ubuntu.i386
Traceback (most recent call last):
File "source/qemu/tests/vm/basevm.py", line 236, in main
return vm.build_image(args.image)
File "tests/vm/ubuntu.i386", line 67, in build_image
subprocess.check_call(["qemu-img", "resize", img_tmp, "50G"])
OSError: [Errno 2] No such file or directory
tests/vm/Makefile.include:23: recipe for target 'tests/vm/ubuntu.i386.img' failed
make: *** [tests/vm/ubuntu.i386.img] Error 2A better fix would be checking those tools via ./configure...
--- tests/Makefile.include | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
tests/Makefile.include +1 -1
@@ -708,7 +708,7 @@ tests/prom-env-test$(EXESUF): tests/prom-env-test.o $(libqos-obj-y) tests/rtas-test$(EXESUF): tests/rtas-test.o $(libqos-spapr-obj-y) tests/fdc-test$(EXESUF): tests/fdc-test.o tests/ide-test$(EXESUF): tests/ide-test.o $(libqos-pc-obj-y) -tests/ahci-test$(EXESUF): tests/ahci-test.o $(libqos-pc-obj-y) +tests/ahci-test$(EXESUF): tests/ahci-test.o $(libqos-pc-obj-y) qemu-img$(EXESUF) tests/ipmi-kcs-test$(EXESUF): tests/ipmi-kcs-test.o tests/ipmi-bt-test$(EXESUF): tests/ipmi-bt-test.o tests/hd-geo-test$(EXESUF): tests/hd-geo-test.o
Signature · 1 line
2.20.1
Re: [Qemu-devel] [PATCH v3 1/8] ahci-test: Add dependency to qemu-img tool
Quoted 35 lines · Philippe Mathieu-Daudé
Since the ahci-test uses qemu-img, add a dependency to build it before using it.
This fixes:$ gmake check-qtest V=1 QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/ahci-test Failed to execute child process "/tmp/qemu-test.19tMRF/qemu-img" (No such file or directory) ERROR:tests/libqos/libqos.c:192:mkimg: assertion failed: (ret && !err)Reviewed-by John Snow <[email protected]>Signed-off-by Philippe Mathieu-Daudé <[email protected]>---
Slighly related is when vm-tests expect qemu-img available:
https://lists.gnu.org/archive/html/qemu-devel/2018-06/msg08415.html$ make vm-build-ubuntu.i386 Traceback (most recent call last): File "source/qemu/tests/vm/basevm.py", line 236, in main return vm.build_image(args.image) File "tests/vm/ubuntu.i386", line 67, in build_image subprocess.check_call(["qemu-img", "resize", img_tmp, "50G"]) OSError: [Errno 2] No such file or directory tests/vm/Makefile.include:23: recipe for target 'tests/vm/ubuntu.i386.img' failed make: *** [tests/vm/ubuntu.i386.img] Error 2A better fix would be checking those tools via ./configure...
--- tests/Makefile.include | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)tests/Makefile.include +0
-0
tests/Makefile.include tests/prom-env-test$(EXESUF): tests/prom-env-test.o $(libqos-obj-y) · line 711
Quoted 5 lines
tests/Makefile.include +1
-1@@ -708,7 +708,7 @@ tests/prom-env-test$(EXESUF): tests/prom-env-test.o $(libqos-obj-y) tests/rtas-test$(EXESUF): tests/rtas-test.o $(libqos-spapr-obj-y) tests/fdc-test$(EXESUF): tests/fdc-test.o tests/ide-test$(EXESUF): tests/ide-test.o $(libqos-pc-obj-y) -tests/ahci-test$(EXESUF): tests/ahci-test.o $(libqos-pc-obj-y) +tests/ahci-test$(EXESUF): tests/ahci-test.o $(libqos-pc-obj-y) qemu-img$(EXESUF)
In [*] Cleber noticed if we configure using --disable-tools, qemu-img is still built by when running "make check-block" due to this rule.
I think this is OK because
- at least a test requires it, so this test will run (which is what we want)
- while the tool is available in the build directory, it still won't be installed by "make install"
[*] https://lists.gnu.org/archive/html/qemu-devel/2019-02/msg01947.html
Quoted 4 lines
tests/Makefile.include +0
-0tests/ipmi-kcs-test$(EXESUF): tests/ipmi-kcs-test.o tests/ipmi-bt-test$(EXESUF): tests/ipmi-bt-test.o tests/hd-geo-test$(EXESUF): tests/hd-geo-test.o
Re: [Qemu-devel] [PATCH v3 1/8] ahci-test: Add dependency to qemu-img tool
Quoted 45 lines · Philippe Mathieu-Daudé
Quoted 35 lines · Philippe Mathieu-Daudé
Since the ahci-test uses qemu-img, add a dependency to build it before using it.
This fixes:$ gmake check-qtest V=1 QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/ahci-test Failed to execute child process "/tmp/qemu-test.19tMRF/qemu-img" (No such file or directory) ERROR:tests/libqos/libqos.c:192:mkimg: assertion failed: (ret && !err)Reviewed-by John Snow <[email protected]>Signed-off-by Philippe Mathieu-Daudé <[email protected]>---
Slighly related is when vm-tests expect qemu-img available:
https://lists.gnu.org/archive/html/qemu-devel/2018-06/msg08415.html$ make vm-build-ubuntu.i386 Traceback (most recent call last): File "source/qemu/tests/vm/basevm.py", line 236, in main return vm.build_image(args.image) File "tests/vm/ubuntu.i386", line 67, in build_image subprocess.check_call(["qemu-img", "resize", img_tmp, "50G"]) OSError: [Errno 2] No such file or directory tests/vm/Makefile.include:23: recipe for target 'tests/vm/ubuntu.i386.img' failed make: *** [tests/vm/ubuntu.i386.img] Error 2A better fix would be checking those tools via ./configure...
--- tests/Makefile.include | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)tests/Makefile.include +0
-0tests/Makefile.include tests/prom-env-test$(EXESUF): tests/prom-env-test.o $(libqos-obj-y) · line 711
Quoted 5 lines
tests/Makefile.include +1
-1@@ -708,7 +708,7 @@ tests/prom-env-test$(EXESUF): tests/prom-env-test.o $(libqos-obj-y) tests/rtas-test$(EXESUF): tests/rtas-test.o $(libqos-spapr-obj-y) tests/fdc-test$(EXESUF): tests/fdc-test.o tests/ide-test$(EXESUF): tests/ide-test.o $(libqos-pc-obj-y) -tests/ahci-test$(EXESUF): tests/ahci-test.o $(libqos-pc-obj-y) +tests/ahci-test$(EXESUF): tests/ahci-test.o $(libqos-pc-obj-y) qemu-img$(EXESUF)In [*] Cleber noticed if we configure using --disable-tools, qemu-img is still built by when running "make check-block" due to this rule.
Quoted 5 lines
I think this is OK because
- at least a test requires it, so this test will run (which is what we want)
- while the tool is available in the build directory, it still won't be installed by "make install"
I guess you could also introduce a CONFIG_TOOLS switch and only run the ahci test for CONFIG_TOOLS=y ? ... not that important, but in case you respin the series, maybe worth a try.
Thomas
Re: [Qemu-devel] [PATCH v3 1/8] ahci-test: Add dependency to qemu-img tool
Quoted 52 lines · Thomas Huth
Quoted 45 lines · Philippe Mathieu-Daudé
Quoted 35 lines · Philippe Mathieu-Daudé
Since the ahci-test uses qemu-img, add a dependency to build it before using it.
This fixes:$ gmake check-qtest V=1 QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/ahci-test Failed to execute child process "/tmp/qemu-test.19tMRF/qemu-img" (No such file or directory) ERROR:tests/libqos/libqos.c:192:mkimg: assertion failed: (ret && !err)Reviewed-by John Snow <[email protected]>Signed-off-by Philippe Mathieu-Daudé <[email protected]>---
Slighly related is when vm-tests expect qemu-img available:
https://lists.gnu.org/archive/html/qemu-devel/2018-06/msg08415.html$ make vm-build-ubuntu.i386 Traceback (most recent call last): File "source/qemu/tests/vm/basevm.py", line 236, in main return vm.build_image(args.image) File "tests/vm/ubuntu.i386", line 67, in build_image subprocess.check_call(["qemu-img", "resize", img_tmp, "50G"]) OSError: [Errno 2] No such file or directory tests/vm/Makefile.include:23: recipe for target 'tests/vm/ubuntu.i386.img' failed make: *** [tests/vm/ubuntu.i386.img] Error 2A better fix would be checking those tools via ./configure...
--- tests/Makefile.include | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)tests/Makefile.include +0
-0tests/Makefile.include tests/prom-env-test$(EXESUF): tests/prom-env-test.o $(libqos-obj-y) · line 711
Quoted 5 lines
tests/Makefile.include +1
-1@@ -708,7 +708,7 @@ tests/prom-env-test$(EXESUF): tests/prom-env-test.o $(libqos-obj-y) tests/rtas-test$(EXESUF): tests/rtas-test.o $(libqos-spapr-obj-y) tests/fdc-test$(EXESUF): tests/fdc-test.o tests/ide-test$(EXESUF): tests/ide-test.o $(libqos-pc-obj-y) -tests/ahci-test$(EXESUF): tests/ahci-test.o $(libqos-pc-obj-y) +tests/ahci-test$(EXESUF): tests/ahci-test.o $(libqos-pc-obj-y) qemu-img$(EXESUF)In [*] Cleber noticed if we configure using --disable-tools, qemu-img is still built by when running "make check-block" due to this rule.
Quoted 5 lines
I think this is OK because
- at least a test requires it, so this test will run (which is what we want)
- while the tool is available in the build directory, it still won't be installed by "make install"
Quoted 6 lines
I guess you could also introduce a
CONFIG_TOOLSswitch and only run the ahci test forCONFIG_TOOLS=y? ... not that important, but in case you respin the series, maybe worth a try.Thomas
Is this necessary?
You can run ahci-test by itself without building tools, but you need to export QTEST_QEMU_IMG yourself, which you can absolutely point to some other copy you have.
If you run "make check" though, it's going to use the built copy of qemu-img no matter what, isn't it? so what's so great about preserving a configuration where you ask it not to build tools and then intentionally try to execute tests that will necessarily fail because they can't find the qemu-img binary?
This seems fine the way it is, because you are asking the computer:
1. Not to build tools, please
2. Actually, please make the tools so I can run the tests
Convince me otherwise?
--js
Re: [Qemu-devel] [PATCH v3 1/8] ahci-test: Add dependency to qemu-img tool
Quoted 72 lines · John Snow
Quoted 52 lines · Thomas Huth
Quoted 45 lines · Philippe Mathieu-Daudé
Quoted 35 lines · Philippe Mathieu-Daudé
Since the ahci-test uses qemu-img, add a dependency to build it before using it.
This fixes:$ gmake check-qtest V=1 QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64 QTEST_QEMU_IMG=qemu-img tests/ahci-test Failed to execute child process "/tmp/qemu-test.19tMRF/qemu-img" (No such file or directory) ERROR:tests/libqos/libqos.c:192:mkimg: assertion failed: (ret && !err)Reviewed-by John Snow <[email protected]>Signed-off-by Philippe Mathieu-Daudé <[email protected]>---
Slighly related is when vm-tests expect qemu-img available:
https://lists.gnu.org/archive/html/qemu-devel/2018-06/msg08415.html$ make vm-build-ubuntu.i386 Traceback (most recent call last): File "source/qemu/tests/vm/basevm.py", line 236, in main return vm.build_image(args.image) File "tests/vm/ubuntu.i386", line 67, in build_image subprocess.check_call(["qemu-img", "resize", img_tmp, "50G"]) OSError: [Errno 2] No such file or directory tests/vm/Makefile.include:23: recipe for target 'tests/vm/ubuntu.i386.img' failed make: *** [tests/vm/ubuntu.i386.img] Error 2A better fix would be checking those tools via ./configure...
--- tests/Makefile.include | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)tests/Makefile.include +0
-0tests/Makefile.include tests/prom-env-test$(EXESUF): tests/prom-env-test.o $(libqos-obj-y) · line 711
Quoted 5 lines
tests/Makefile.include +1
-1@@ -708,7 +708,7 @@ tests/prom-env-test$(EXESUF): tests/prom-env-test.o $(libqos-obj-y) tests/rtas-test$(EXESUF): tests/rtas-test.o $(libqos-spapr-obj-y) tests/fdc-test$(EXESUF): tests/fdc-test.o tests/ide-test$(EXESUF): tests/ide-test.o $(libqos-pc-obj-y) -tests/ahci-test$(EXESUF): tests/ahci-test.o $(libqos-pc-obj-y) +tests/ahci-test$(EXESUF): tests/ahci-test.o $(libqos-pc-obj-y) qemu-img$(EXESUF)In [*] Cleber noticed if we configure using --disable-tools, qemu-img is still built by when running "make check-block" due to this rule.
Quoted 5 lines
I think this is OK because
- at least a test requires it, so this test will run (which is what we want)
- while the tool is available in the build directory, it still won't be installed by "make install"Quoted 6 lines
I guess you could also introduce a
CONFIG_TOOLSswitch and only run the ahci test forCONFIG_TOOLS=y? ... not that important, but in case you respin the series, maybe worth a try.Thomas
Is this necessary?
You can run ahci-test by itself without building tools, but you need to export
QTEST_QEMU_IMGyourself, which you can absolutely point to some other copy you have.If you run "make check" though, it's going to use the built copy of qemu-img no matter what, isn't it? so what's so great about preserving a configuration where you ask it not to build tools and then intentionally try to execute tests that will necessarily fail because they can't find the qemu-img binary?
Quoted 4 lines
This seems fine the way it is, because you are asking the computer:
1. Not to build tools, please
2. Actually, please make the tools so I can run the tests
I understand it the same way (although not being a computer).
I wanted to check if what Cleber noticed could bother someone else, but I think the current behavior is the correct one.
Also I wouldn't worry much about this corner case, the combination of having someone:
- willing to run iotests
AND
(
- doesn't have qemu-img distrib-installed
OR
- ran configure with --disable-tools
)
is *very* unlikely, as only 2 person reported this and both encountered this while working on QEMU testing.
Quoted 3 lines
Convince me otherwise?
--js
PATCH v3 2/8 qemu-iotests: Add dependency to qemu-nbd tool
In reply to Philippe Mathieu-DaudéSince a9660664fde, some iotests use qemu-nbd.
Add a dependency to build it before using it.
This fixes:
$ make check-block
GEN qemu-img-cmds.h
CC qemu-img.o
LINK qemu-img
CC qemu-io.o
LINK qemu-io
CC tests/qemu-iotests/socket_scm_helper.o
LINK tests/qemu-iotests/socket_scm_helper
tests/qemu-iotests-quick.sh
check: qemu-nbd not found
make: *** [tests/Makefile.include:1059: check-tests/qemu-iotests-quick.sh] Error 1--- tests/Makefile.include | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
tests/Makefile.include +1 -1
@@ -1057,7 +1057,7 @@ clean-tcg: $(CLEAN_TCG_TARGET_RULES) QEMU_IOTESTS_HELPERS-$(call land,$(CONFIG_SOFTMMU),$(CONFIG_LINUX)) = tests/qemu-iotests/socket_scm_helper$(EXESUF) .PHONY: check-tests/qemu-iotests-quick.sh -check-tests/qemu-iotests-quick.sh: tests/qemu-iotests-quick.sh qemu-img$(EXESUF) qemu-io$(EXESUF) $(QEMU_IOTESTS_HELPERS-y) +check-tests/qemu-iotests-quick.sh: tests/qemu-iotests-quick.sh qemu-img$(EXESUF) qemu-io$(EXESUF) qemu-nbd$(EXESUF) $(QEMU_IOTESTS_HELPERS-y) $< .PHONY: $(patsubst %, check-%, $(check-qapi-schema-y))
Signature · 1 line
2.20.1
PATCH v3 3/8 qemu-iotests: Improve portability by searching bash in the $PATH
In reply to Philippe Mathieu-DaudéBash is not always installed as /bin/bash. In particular on OpenBSD, the package installs it in /usr/local/bin.
Use the 'env' shebang to search bash in the $PATH.
Patch created mechanically by running:
$ git grep -lE '#! ?/bin/bash' -- tests/qemu-iotests \
| while read f; do \
sed -i 's|^#!.\?/bin/bash$|#!/usr/bin/env bash|' $f; \
done--- tests/qemu-iotests/001 | 2 +- tests/qemu-iotests/002 | 2 +- tests/qemu-iotests/003 | 2 +- tests/qemu-iotests/004 | 2 +- tests/qemu-iotests/005 | 2 +- tests/qemu-iotests/007 | 2 +- tests/qemu-iotests/008 | 2 +- tests/qemu-iotests/009 | 2 +- tests/qemu-iotests/010 | 2 +- tests/qemu-iotests/011 | 2 +- tests/qemu-iotests/012 | 2 +- tests/qemu-iotests/013 | 2 +- tests/qemu-iotests/014 | 2 +- tests/qemu-iotests/015 | 2 +- tests/qemu-iotests/017 | 2 +- tests/qemu-iotests/018 | 2 +- tests/qemu-iotests/019 | 2 +- tests/qemu-iotests/020 | 2 +- tests/qemu-iotests/021 | 2 +- tests/qemu-iotests/022 | 2 +- tests/qemu-iotests/023 | 2 +- tests/qemu-iotests/024 | 2 +- tests/qemu-iotests/025 | 2 +- tests/qemu-iotests/026 | 2 +- tests/qemu-iotests/027 | 2 +- tests/qemu-iotests/028 | 2 +- tests/qemu-iotests/029 | 2 +- tests/qemu-iotests/031 | 2 +- tests/qemu-iotests/032 | 2 +- tests/qemu-iotests/033 | 2 +- tests/qemu-iotests/034 | 2 +- tests/qemu-iotests/035 | 2 +- tests/qemu-iotests/036 | 2 +- tests/qemu-iotests/037 | 2 +- tests/qemu-iotests/038 | 2 +- tests/qemu-iotests/039 | 2 +- tests/qemu-iotests/042 | 2 +- tests/qemu-iotests/043 | 2 +- tests/qemu-iotests/046 | 2 +- tests/qemu-iotests/047 | 2 +- tests/qemu-iotests/048 | 2 +- tests/qemu-iotests/049 | 2 +- tests/qemu-iotests/050 | 2 +- tests/qemu-iotests/051 | 2 +- tests/qemu-iotests/052 | 2 +- tests/qemu-iotests/053 | 2 +- tests/qemu-iotests/054 | 2 +- tests/qemu-iotests/058 | 2 +- tests/qemu-iotests/059 | 2 +- tests/qemu-iotests/060 | 2 +- tests/qemu-iotests/061 | 2 +- tests/qemu-iotests/062 | 2 +- tests/qemu-iotests/063 | 2 +- tests/qemu-iotests/064 | 2 +- tests/qemu-iotests/066 | 2 +- tests/qemu-iotests/067 | 2 +- tests/qemu-iotests/068 | 2 +- tests/qemu-iotests/069 | 2 +- tests/qemu-iotests/070 | 2 +- tests/qemu-iotests/071 | 2 +- tests/qemu-iotests/072 | 2 +- tests/qemu-iotests/073 | 2 +- tests/qemu-iotests/074 | 2 +- tests/qemu-iotests/075 | 2 +- tests/qemu-iotests/076 | 2 +- tests/qemu-iotests/077 | 2 +- tests/qemu-iotests/078 | 2 +- tests/qemu-iotests/079 | 2 +- tests/qemu-iotests/080 | 2 +- tests/qemu-iotests/081 | 2 +- tests/qemu-iotests/082 | 2 +- tests/qemu-iotests/083 | 2 +- tests/qemu-iotests/084 | 2 +- tests/qemu-iotests/085 | 2 +- tests/qemu-iotests/086 | 2 +- tests/qemu-iotests/087 | 2 +- tests/qemu-iotests/088 | 2 +- tests/qemu-iotests/089 | 2 +- tests/qemu-iotests/090 | 2 +- tests/qemu-iotests/091 | 2 +- tests/qemu-iotests/092 | 2 +- tests/qemu-iotests/094 | 2 +- tests/qemu-iotests/095 | 2 +- tests/qemu-iotests/097 | 2 +- tests/qemu-iotests/098 | 2 +- tests/qemu-iotests/099 | 2 +- tests/qemu-iotests/101 | 2 +- tests/qemu-iotests/102 | 2 +- tests/qemu-iotests/103 | 2 +- tests/qemu-iotests/104 | 2 +- tests/qemu-iotests/105 | 2 +- tests/qemu-iotests/106 | 2 +- tests/qemu-iotests/107 | 2 +- tests/qemu-iotests/108 | 2 +- tests/qemu-iotests/109 | 2 +- tests/qemu-iotests/110 | 2 +- tests/qemu-iotests/111 | 2 +- tests/qemu-iotests/112 | 2 +- tests/qemu-iotests/113 | 2 +- tests/qemu-iotests/114 | 2 +- tests/qemu-iotests/115 | 2 +- tests/qemu-iotests/116 | 2 +- tests/qemu-iotests/117 | 2 +- tests/qemu-iotests/119 | 2 +- tests/qemu-iotests/120 | 2 +- tests/qemu-iotests/121 | 2 +- tests/qemu-iotests/122 | 2 +- tests/qemu-iotests/123 | 2 +- tests/qemu-iotests/125 | 2 +- tests/qemu-iotests/126 | 2 +- tests/qemu-iotests/127 | 2 +- tests/qemu-iotests/128 | 2 +- tests/qemu-iotests/130 | 2 +- tests/qemu-iotests/131 | 2 +- tests/qemu-iotests/133 | 2 +- tests/qemu-iotests/134 | 2 +- tests/qemu-iotests/135 | 2 +- tests/qemu-iotests/137 | 2 +- tests/qemu-iotests/138 | 2 +- tests/qemu-iotests/140 | 2 +- tests/qemu-iotests/141 | 2 +- tests/qemu-iotests/142 | 2 +- tests/qemu-iotests/143 | 2 +- tests/qemu-iotests/144 | 2 +- tests/qemu-iotests/145 | 2 +- tests/qemu-iotests/146 | 2 +- tests/qemu-iotests/150 | 2 +- tests/qemu-iotests/153 | 2 +- tests/qemu-iotests/154 | 2 +- tests/qemu-iotests/156 | 2 +- tests/qemu-iotests/157 | 2 +- tests/qemu-iotests/158 | 2 +- tests/qemu-iotests/159 | 2 +- tests/qemu-iotests/160 | 2 +- tests/qemu-iotests/161 | 2 +- tests/qemu-iotests/162 | 2 +- tests/qemu-iotests/170 | 2 +- tests/qemu-iotests/171 | 2 +- tests/qemu-iotests/172 | 2 +- tests/qemu-iotests/173 | 2 +- tests/qemu-iotests/174 | 2 +- tests/qemu-iotests/175 | 2 +- tests/qemu-iotests/176 | 2 +- tests/qemu-iotests/177 | 2 +- tests/qemu-iotests/178 | 2 +- tests/qemu-iotests/179 | 2 +- tests/qemu-iotests/181 | 2 +- tests/qemu-iotests/182 | 2 +- tests/qemu-iotests/183 | 2 +- tests/qemu-iotests/184 | 2 +- tests/qemu-iotests/185 | 2 +- tests/qemu-iotests/186 | 2 +- tests/qemu-iotests/187 | 2 +- tests/qemu-iotests/188 | 2 +- tests/qemu-iotests/189 | 2 +- tests/qemu-iotests/190 | 2 +- tests/qemu-iotests/191 | 2 +- tests/qemu-iotests/192 | 2 +- tests/qemu-iotests/195 | 2 +- tests/qemu-iotests/197 | 2 +- tests/qemu-iotests/198 | 2 +- tests/qemu-iotests/200 | 2 +- tests/qemu-iotests/201 | 2 +- tests/qemu-iotests/204 | 2 +- tests/qemu-iotests/214 | 2 +- tests/qemu-iotests/215 | 2 +- tests/qemu-iotests/217 | 2 +- tests/qemu-iotests/220 | 2 +- tests/qemu-iotests/221 | 2 +- tests/qemu-iotests/223 | 2 +- tests/qemu-iotests/225 | 2 +- tests/qemu-iotests/226 | 2 +- tests/qemu-iotests/227 | 2 +- tests/qemu-iotests/229 | 2 +- tests/qemu-iotests/231 | 2 +- tests/qemu-iotests/232 | 2 +- tests/qemu-iotests/233 | 2 +- tests/qemu-iotests/check | 2 +- tests/qemu-iotests/common.config | 2 +- tests/qemu-iotests/common.filter | 2 +- tests/qemu-iotests/common.nbd | 2 +- tests/qemu-iotests/common.pattern | 2 +- tests/qemu-iotests/common.qemu | 2 +- tests/qemu-iotests/common.rc | 2 +- tests/qemu-iotests/common.tls | 2 +- 185 files changed, 185 insertions(+), 185 deletions(-)
tests/qemu-iotests/001 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test simple read/write using plain bdrv_read/bdrv_write #
tests/qemu-iotests/002 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test simple read/write using plain bdrv_pread/bdrv_pwrite #
tests/qemu-iotests/003 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test simple read/write using bdrv_aio_readv/bdrv_aio_writev #
tests/qemu-iotests/004 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Make sure we can't read and write outside of the image size. #
tests/qemu-iotests/005 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Make sure qemu-img can create 5TB images #
tests/qemu-iotests/007 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Check for one possible case of qcow2 refcount corruption. #
tests/qemu-iotests/008 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test simple asynchronous read/write operations. #
tests/qemu-iotests/009 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Nolan I qcow2 corruption - incorrectly reports free clusters #
tests/qemu-iotests/010 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Nolan II qcow2 corruption - wrong used cluster #
tests/qemu-iotests/011 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test for AIO allocation on the same cluster #
tests/qemu-iotests/012 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Make sure we can open read-only images #
tests/qemu-iotests/013 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # qcow2 pattern test, empty and compressed image - 4k cluster patterns #
tests/qemu-iotests/014 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # qcow2 pattern test, complex patterns including compression and snapshots # Using patterns for 4k cluster size.
tests/qemu-iotests/015 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Combined test to grow the refcount table and test snapshots. #
tests/qemu-iotests/017 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Simple backing file reads #
tests/qemu-iotests/018 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Merge backing file into test image when converting the image #
tests/qemu-iotests/019 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # When using a backing file for the output image in qemu-img convert, # the backing file clusters must not copied. The data must still be
tests/qemu-iotests/020 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Commit changes to backing file #
tests/qemu-iotests/021 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test handling of invalid patterns arguments to qemu-io #
tests/qemu-iotests/022 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test bdrv_load/save_vmstate using the usual patterns #
tests/qemu-iotests/023 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # qcow2 pattern test with various cluster sizes #
tests/qemu-iotests/024 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Rebasing COW images #
tests/qemu-iotests/025 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Resizing images #
tests/qemu-iotests/026 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # qcow2 error path testing #
tests/qemu-iotests/027 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test that sub-cluster allocating writes zero the rest of the cluster #
tests/qemu-iotests/028 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test that backing files can be smaller than the image #
tests/qemu-iotests/029 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # qcow2 internal snapshots/VM state tests #
tests/qemu-iotests/031 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test that all qcow2 header extensions survive a header rewrite #
tests/qemu-iotests/032 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test that AIO requests are drained before an image is closed. This used # to segfault because the request coroutine kept running even after the
tests/qemu-iotests/033 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test aligned and misaligned write zeroes operations. #
tests/qemu-iotests/034 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test bdrv_pwrite_zeroes with backing files (see also 154) #
tests/qemu-iotests/035 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Let a few AIO requests run in parallel and have them access different L2 # tables so that the cache has a chance to get used up.
tests/qemu-iotests/036 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test qcow2 feature bits #
tests/qemu-iotests/037 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test COW from backing files #
tests/qemu-iotests/038 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test COW from backing files with AIO #
tests/qemu-iotests/039 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test qcow2 lazy refcounts #
tests/qemu-iotests/042 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test qemu-img operation on zero size images #
tests/qemu-iotests/043 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test that qemu-img info --backing-chain detects infinite loops #
tests/qemu-iotests/046 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test concurrent cluster allocations #
tests/qemu-iotests/047 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Regression test for commit b7ab0fea (which was a corruption fix, # despite the commit message claiming otherwise)
tests/qemu-iotests/048 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash ## ## qemu-img compare test ##
tests/qemu-iotests/049 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Check qemu-img option parsing #
tests/qemu-iotests/050 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test qemu-img rebase with zero clusters #
tests/qemu-iotests/051 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test command line configuration of block devices and driver-specific options #
tests/qemu-iotests/052 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test bdrv_read/bdrv_write using BDRV_O_SNAPSHOT #
tests/qemu-iotests/053 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test qemu-img convert when image length is not a multiple of cluster size #
tests/qemu-iotests/054 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test huge qcow2 images #
tests/qemu-iotests/058 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test export internal snapshot by qemu-nbd, convert it by qemu-img. #
tests/qemu-iotests/059 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for vmdk #
tests/qemu-iotests/060 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for image corruption (overlapping data structures) in qcow2 #
tests/qemu-iotests/061 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for image option amendment in qcow2. #
tests/qemu-iotests/062 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for snapshotting images with unallocated zero clusters in # qcow2
tests/qemu-iotests/063 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # test of qemu-img convert -n - convert without creation #
tests/qemu-iotests/064 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test VHDX read/write from a sample image created with Hyper-V #
tests/qemu-iotests/066 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for preallocated zero clusters in qcow2 #
tests/qemu-iotests/067 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test automatic deletion of BDSes created by -drive/drive_add #
tests/qemu-iotests/068 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for loading a saved VM state from a qcow2 image #
tests/qemu-iotests/069 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for deleting a backing file #
tests/qemu-iotests/070 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test VHDX log replay from an image with a journal that needs to be # replayed
tests/qemu-iotests/071 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for the QMP blkdebug and blkverify interfaces #
tests/qemu-iotests/072 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for nested image formats #
tests/qemu-iotests/073 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test count_contiguous_clusters in qcow2 #
tests/qemu-iotests/074 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash ## ## qemu-img compare test (qcow2 only ones) ##
tests/qemu-iotests/075 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # cloop format input validation tests #
tests/qemu-iotests/076 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # parallels format input validation tests #
tests/qemu-iotests/077 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test concurrent pread/pwrite #
tests/qemu-iotests/078 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # bochs format input validation tests #
tests/qemu-iotests/079 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test qcow2 preallocation with different cluster_sizes #
tests/qemu-iotests/080 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # qcow2 format input validation tests #
tests/qemu-iotests/081 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test Quorum block driver #
tests/qemu-iotests/082 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test qemu-img command line parsing #
tests/qemu-iotests/083 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test NBD client unexpected disconnect #
tests/qemu-iotests/084 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for VDI header corruption; image too large, and too many blocks. # Also simple test for creating dynamic and static VDI images.
tests/qemu-iotests/085 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Live snapshot tests #
tests/qemu-iotests/086 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test qemu-img progress output #
tests/qemu-iotests/087 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test unsupported blockdev-add cases #
tests/qemu-iotests/088 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # vpc (VHD) format input validation tests #
tests/qemu-iotests/089 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for support of JSON filenames #
tests/qemu-iotests/090 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test for discarding compressed clusters on qcow2 images #
tests/qemu-iotests/091 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Live migration test #
tests/qemu-iotests/092 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # qcow1 format input validation tests #
tests/qemu-iotests/094 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for drive-mirror to NBD #
tests/qemu-iotests/095 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test for commit of larger active layer #
tests/qemu-iotests/097 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Commit changes into backing chains and empty the top image if the # backing image is not explicitly specified
tests/qemu-iotests/098 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test qcow2's bdrv_make_empty for images without internal snapshots #
tests/qemu-iotests/099 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test valid filenames for blkdebug and blkverify representatively for # other protocols (such as NBD) when queried
tests/qemu-iotests/101 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test short file I/O #
tests/qemu-iotests/102 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for qemu-io -c map and qemu-img map #
tests/qemu-iotests/103 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for qcow2 metadata cache size specification #
tests/qemu-iotests/104 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test image creation with aligned and unaligned sizes #
tests/qemu-iotests/105 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Create, read, write big image #
tests/qemu-iotests/106 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test preallocated resize of raw images #
tests/qemu-iotests/107 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Tests updates of the qcow2 L1 table #
tests/qemu-iotests/108 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for repairing qcow2 images which cannot be repaired using # the on-disk refcount structures
tests/qemu-iotests/109 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test writing image headers of other formats into raw images #
tests/qemu-iotests/110 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for relative backing file names in complex BDS trees #
tests/qemu-iotests/111 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for non-existing backing file when creating a qcow2 image # and not specifying the size
tests/qemu-iotests/112 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test cases for different refcount_bits values #
tests/qemu-iotests/113 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for accessing creation options on image formats and # protocols not supporting image creation
tests/qemu-iotests/114 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test invalid backing file format in qcow2 images #
tests/qemu-iotests/115 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for non-self-referential qcow2 refcount blocks #
tests/qemu-iotests/116 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test error code paths for invalid QED images #
tests/qemu-iotests/117 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for shared BDS between backend trees #
tests/qemu-iotests/119 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # NBD test case for overriding BDRV_O_PROTOCOL by explicitly specifying # a driver
tests/qemu-iotests/120 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Non-NBD test cases for overriding BDRV_O_PROTOCOL by explicitly # specifying a driver
tests/qemu-iotests/121 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test cases for qcow2 refcount table growth #
tests/qemu-iotests/122 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test some qemu-img convert cases #
tests/qemu-iotests/123 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for qemu-img convert to NBD #
tests/qemu-iotests/125 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test preallocated growth of qcow2 images #
tests/qemu-iotests/126 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Tests handling of colons in filenames (which may be confused with protocol # prefixes)
tests/qemu-iotests/127 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for mirroring with dataplane #
tests/qemu-iotests/128 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test that opening O_DIRECT succeeds when image file I/O produces EIO #
tests/qemu-iotests/130 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test that temporary backing file overrides (on the command line or in # blockdev-add) don't replace the original path stored in the image during
tests/qemu-iotests/131 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # parallels format validation tests (created by QEMU) #
tests/qemu-iotests/133 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test for reopen #
tests/qemu-iotests/134 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test encrypted read/write using plain bdrv_read/bdrv_write #
tests/qemu-iotests/135 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test VPC open of image with large Max Table Entries value. #
tests/qemu-iotests/137 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test qcow2 reopen #
tests/qemu-iotests/138 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # General test case for qcow2's image check #
tests/qemu-iotests/140 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for ejecting a BlockBackend with an NBD server attached to it #
tests/qemu-iotests/141 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for ejecting BDSs with block jobs still running on them #
tests/qemu-iotests/142 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test for configuring cache modes of arbitrary nodes (requires O_DIRECT) #
tests/qemu-iotests/143 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for connecting to a non-existing NBD export name #
tests/qemu-iotests/144 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # Check live snapshot, followed by active commit, and another snapshot. # # This test is to catch the error case of BZ #1300209:
tests/qemu-iotests/145 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test the combination of -incoming and snapshot=on #
tests/qemu-iotests/146 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test VHD image format creator detection and override #
tests/qemu-iotests/150 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test that qemu-img convert -S 0 fully allocates the target image #
tests/qemu-iotests/153 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test image locking #
tests/qemu-iotests/154 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # qcow2 specific bdrv_pwrite_zeroes tests with backing files (complements 034) #
tests/qemu-iotests/156 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Tests oVirt-like storage migration: # - Create snapshot
tests/qemu-iotests/157 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test command line configuration of block devices with qdev #
tests/qemu-iotests/158 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test encrypted read/write using backing files #
tests/qemu-iotests/159 +1 -1
@@ -1,4 +1,4 @@ -#! /bin/bash +#!/usr/bin/env bash # # qemu-img dd test with different block sizes #
tests/qemu-iotests/160 +1 -1
@@ -1,4 +1,4 @@ -#! /bin/bash +#!/usr/bin/env bash # # qemu-img dd test for the skip option #
tests/qemu-iotests/161 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test reopening a backing image after block-stream and block-commit #
tests/qemu-iotests/162 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for specifying runtime options of the wrong type to some # block drivers
tests/qemu-iotests/170 +1 -1
@@ -1,4 +1,4 @@ -#! /bin/bash +#!/usr/bin/env bash # # qemu-img dd test #
tests/qemu-iotests/171 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test 'offset' and 'size' options of the raw driver. Make sure we can't # (or can) read and write outside of the image size.
tests/qemu-iotests/172 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test floppy configuration #
tests/qemu-iotests/173 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test QAPI commands looking up protocol based images with relative # filename backing strings
tests/qemu-iotests/174 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test that qemu-io fail with non-zero exit code #
tests/qemu-iotests/175 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test creating raw image preallocation mode #
tests/qemu-iotests/176 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Commit changes into backing chains and empty the top image if the # backing image is not explicitly specified.
tests/qemu-iotests/177 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test corner cases with unusual block geometries #
tests/qemu-iotests/178 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # qemu-img measure sub-command tests #
tests/qemu-iotests/179 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for write zeroes with unmap #
tests/qemu-iotests/181 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test postcopy live migration with shared storage #
tests/qemu-iotests/182 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test image locking for POSIX locks #
tests/qemu-iotests/183 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test old-style block migration (migrate -b) #
tests/qemu-iotests/184 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test I/O throttle block filter driver interface #
tests/qemu-iotests/185 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test exiting qemu while jobs are still running #
tests/qemu-iotests/186 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test 'info block' with all kinds of configurations #
tests/qemu-iotests/187 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test switching between read-only and read-write #
tests/qemu-iotests/188 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test encrypted read/write using plain bdrv_read/bdrv_write #
tests/qemu-iotests/189 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test encrypted read/write using backing files #
tests/qemu-iotests/190 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # qemu-img measure sub-command tests on huge qcow2 files #
tests/qemu-iotests/191 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test commit block job where top has two parents #
tests/qemu-iotests/192 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test NBD export with -incoming (non-shared storage migration use case from # libvirt)
tests/qemu-iotests/195 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test change-backing-file command #
tests/qemu-iotests/197 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for copy-on-read into qcow2 #
tests/qemu-iotests/198 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test commit of encrypted qcow2 files #
tests/qemu-iotests/200 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Block job co-routine race condition test. #
tests/qemu-iotests/201 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test savevm and loadvm after live migration with postcopy flag #
tests/qemu-iotests/204 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test corner cases with unusual block geometries #
tests/qemu-iotests/214 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test qcow2 image compression #
tests/qemu-iotests/215 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test case for copy-on-read into qcow2, using the COR filter driver #
tests/qemu-iotests/217 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # I/O errors when working with internal qcow2 snapshots, and repairing # the result
tests/qemu-iotests/220 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # max limits on compression in huge qcow2 files #
tests/qemu-iotests/221 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test qemu-img vs. unaligned images #
tests/qemu-iotests/223 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test reading dirty bitmap over NBD #
tests/qemu-iotests/225 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test vmdk backing file correlation #
tests/qemu-iotests/226 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # This test covers expected filetypes for the file, host_cdrom and # host_device drivers.
tests/qemu-iotests/227 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test query-blockstats with different ways to create a BB #
tests/qemu-iotests/229 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test for force canceling a running blockjob that is paused in # an error state.
tests/qemu-iotests/231 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test legacy and modern option parsing for rbd/ceph. This will not # actually connect to a ceph server, but rather looks for the appropriate
tests/qemu-iotests/232 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test for auto-read-only #
tests/qemu-iotests/233 +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Test NBD TLS certificate / authorization integration #
tests/qemu-iotests/check +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Copyright (C) 2009 Red Hat, Inc. # Copyright (c) 2000-2002,2006 Silicon Graphics, Inc. All Rights Reserved.
tests/qemu-iotests/common.config +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Copyright (C) 2009 Red Hat, Inc. # Copyright (c) 2000-2003,2006 Silicon Graphics, Inc. All Rights Reserved.
tests/qemu-iotests/common.filter +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Copyright (C) 2009 Red Hat, Inc. # Copyright (c) 2000-2001 Silicon Graphics, Inc. All Rights Reserved.
tests/qemu-iotests/common.nbd +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # -*- shell-script-mode -*- # # Helpers for NBD server related config
tests/qemu-iotests/common.pattern +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Copyright (C) 2009 Red Hat, Inc. #
tests/qemu-iotests/common.qemu +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # This allows for launching of multiple QEMU instances, with independent # communication possible to each instance.
tests/qemu-iotests/common.rc +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Copyright (C) 2009 Red Hat, Inc. # Copyright (c) 2000-2006 Silicon Graphics, Inc. All Rights Reserved.
tests/qemu-iotests/common.tls +1 -1
@@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # # Helpers for TLS related config #
Signature · 1 line
2.20.1
PATCH v3 4/8 qemu-iotests: Ensure GNU sed is used
In reply to Philippe Mathieu-DaudéVarious sed regexp from common.filter use sed GNU extensions. Instead of spending time to write these regex to be POSIX compliant, verify the GNU sed is available and use it.
--- tests/qemu-iotests/common.filter | 36 ++++++++++++++++---------------- tests/qemu-iotests/common.rc | 13 ++++++++++++ 2 files changed, 31 insertions(+), 18 deletions(-)
tests/qemu-iotests/common.filter +18 -18
@@ -23,37 +23,37 @@ # _filter_date() { - sed \ + $SED \ -e 's/[A-Z][a-z][a-z] [A-z][a-z][a-z] *[0-9][0-9]* [0-9][0-9]:[0-9][0-9]:[0-9][0-9] [0-9][0-9][0-9][0-9]$/DATE/' } _filter_generated_node_ids() { - sed -re 's/\#block[0-9]{3,}/NODE_NAME/' + $SED -re 's/\#block[0-9]{3,}/NODE_NAME/' } _filter_qom_path() { - sed -e 's#\(Attached to: *\) /.*#\1 PATH#' + $SED -e 's#\(Attached to: *\) /.*#\1 PATH#' } # replace occurrences of the actual TEST_DIR value with TEST_DIR _filter_testdir() { - sed -e "s#$TEST_DIR/#TEST_DIR/#g" + $SED -e "s#$TEST_DIR/#TEST_DIR/#g" } # replace occurrences of the actual IMGFMT value with IMGFMT _filter_imgfmt() { - sed -e "s#$IMGFMT#IMGFMT#g" + $SED -e "s#$IMGFMT#IMGFMT#g" } # Replace error message when the format is not supported and delete # the output lines after the first one _filter_qemu_img_check() { - sed -e '/allocated.*fragmented.*compressed clusters/d' \ + $SED -e '/allocated.*fragmented.*compressed clusters/d' \ -e 's/qemu-img: This image format does not support checks/No errors were found on the image./' \ -e '/Image end offset: [0-9]\+/d' }
@@ -61,13 +61,13 @@ _filter_qemu_img_check() # Removes \r from messages _filter_win32() { - sed -e 's/\r//g' + $SED -e 's/\r//g' } # sanitize qemu-io output _filter_qemu_io() { - _filter_win32 | sed -e "s/[0-9]* ops\; [0-9/:. sec]* ([0-9/.inf]* [EPTGMKiBbytes]*\/sec and [0-9/.inf]* ops\/sec)/X ops\; XX:XX:XX.X (XXX YYY\/sec and XXX ops\/sec)/" \ + _filter_win32 | $SED -e "s/[0-9]* ops\; [0-9/:. sec]* ([0-9/.inf]* [EPTGMKiBbytes]*\/sec and [0-9/.inf]* ops\/sec)/X ops\; XX:XX:XX.X (XXX YYY\/sec and XXX ops\/sec)/" \ -e "s/: line [0-9][0-9]*: *[0-9][0-9]*\( Aborted\| Killed\)/:\1/" \ -e "s/qemu-io> //g" }
@@ -75,7 +75,7 @@ _filter_qemu_io() # replace occurrences of QEMU_PROG with "qemu" _filter_qemu() { - sed -e "s#\\(^\\|(qemu) \\)$(basename $QEMU_PROG):#\1QEMU_PROG:#" \ + $SED -e "s#\\(^\\|(qemu) \\)$(basename $QEMU_PROG):#\1QEMU_PROG:#" \ -e 's#^QEMU [0-9]\+\.[0-9]\+\.[0-9]\+ monitor#QEMU X.Y.Z monitor#' \ -e $'s#\r##' # QEMU monitor uses \r\n line endings }
@@ -84,7 +84,7 @@ _filter_qemu() _filter_qmp() { _filter_win32 | \ - sed -e 's#\("\(micro\)\?seconds": \)[0-9]\+#\1 TIMESTAMP#g' \ + $SED -e 's#\("\(micro\)\?seconds": \)[0-9]\+#\1 TIMESTAMP#g' \ -e 's#^{"QMP":.*}$#QMP_VERSION#' \ -e '/^ "QMP": {\s*$/, /^ }\s*$/ c\' \ -e ' QMP_VERSION'
@@ -93,32 +93,32 @@ _filter_qmp() # readline makes HMP command strings so long that git complains _filter_hmp() { - sed -e $'s/^\\((qemu) \\)\\?.*\e\\[D/\\1/g' \ + $SED -e $'s/^\\((qemu) \\)\\?.*\e\\[D/\\1/g' \ -e $'s/\e\\[K//g' } # replace block job offset _filter_block_job_offset() { - sed -e 's/, "offset": [0-9]\+,/, "offset": OFFSET,/' + $SED -e 's/, "offset": [0-9]\+,/, "offset": OFFSET,/' } # replace block job len _filter_block_job_len() { - sed -e 's/, "len": [0-9]\+,/, "len": LEN,/g' + $SED -e 's/, "len": [0-9]\+,/, "len": LEN,/g' } # replace actual image size (depends on the host filesystem) _filter_actual_image_size() { - sed -s 's/\("actual-size":\s*\)[0-9]\+/\1SIZE/g' + $SED -s 's/\("actual-size":\s*\)[0-9]\+/\1SIZE/g' } # replace driver-specific options in the "Formatting..." line _filter_img_create() { - sed -e "s#$REMOTE_TEST_DIR#TEST_DIR#g" \ + $SED -e "s#$REMOTE_TEST_DIR#TEST_DIR#g" \ -e "s#$IMGPROTO:$TEST_DIR#TEST_DIR#g" \ -e "s#$TEST_DIR#TEST_DIR#g" \ -e "s#$IMGFMT#IMGFMT#g" \
@@ -154,7 +154,7 @@ _filter_img_info() discard=0 regex_json_spec_start='^ *"format-specific": \{' - sed -e "s#$REMOTE_TEST_DIR#TEST_DIR#g" \ + $SED -e "s#$REMOTE_TEST_DIR#TEST_DIR#g" \ -e "s#$IMGPROTO:$TEST_DIR#TEST_DIR#g" \ -e "s#$TEST_DIR#TEST_DIR#g" \ -e "s#$IMGFMT#IMGFMT#g" \
@@ -201,7 +201,7 @@ _filter_img_info() # human and json output _filter_qemu_img_map() { - sed -e 's/\([0-9a-fx]* *[0-9a-fx]* *\)[0-9a-fx]* */\1/g' \ + $SED -e 's/\([0-9a-fx]* *[0-9a-fx]* *\)[0-9a-fx]* */\1/g' \ -e 's/"offset": [0-9]\+/"offset": OFFSET/g' \ -e 's/Mapped to *//' | _filter_testdir | _filter_imgfmt }
@@ -213,7 +213,7 @@ _filter_nbd() # receive callbacks sometimes, making them unreliable. # # Filter out the TCP port number since this changes between runs. - sed -e '/nbd\/.*\.c:/d' \ + $SED -e '/nbd\/.*\.c:/d' \ -e 's#127\.0\.0\.1:[0-9]*#127.0.0.1:PORT#g' \ -e "s#?socket=$TEST_DIR#?socket=TEST_DIR#g" \ -e 's#\(foo\|PORT/\?\|.sock\): Failed to .*$#\1#'
tests/qemu-iotests/common.rc +13 -0
@@ -17,6 +17,19 @@ # along with this program. If not, see <http://www.gnu.org/licenses/>. # +SED= +for sed in sed gsed; do + ($sed --version | grep 'GNU sed') > /dev/null 2>&1 + if [ "$?" -eq 0 ]; then + SED=$sed + break + fi +done +if [ -z "$SED" ]; then + echo "$0: GNU sed not found" + exit 1 +fi + dd() { if [ "$HOSTOS" == "Linux" ]
Signature · 1 line
2.20.1
PATCH v3 5/8 iotests: Let verify_platform() check for unsupported platforms
In reply to Philippe Mathieu-DaudéInstead of checking for a supported platforms, it might be useful to test for the opposite.
--- tests/qemu-iotests/iotests.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
tests/qemu-iotests/iotests.py +3 -1
@@ -712,9 +712,11 @@ def verify_protocol(supported=[], unsupported=[]): if not_sup or (imgproto in unsupported): notrun('not suitable for this protocol: %s' % imgproto) -def verify_platform(supported_oses=['linux']): +def verify_platform(supported_oses=['linux'], unsupported_oses=[]): if True not in [sys.platform.startswith(x) for x in supported_oses]: notrun('not suitable for this OS: %s' % sys.platform) + if True in [sys.platform.startswith(x) for x in unsupported_oses]: + notrun('not suitable for this OS: %s' % sys.platform) def verify_cache_mode(supported_cache_modes=[]): if supported_cache_modes and (cachemode not in supported_cache_modes):
Signature · 1 line
2.20.1
PATCH v3 6/8 RFC iotests: Disable 208 on OpenBSD
In reply to Philippe Mathieu-DaudéThis test explodes on OpenBSD:
$ gmake check-block
[...]
208 [14:46:03] [14:46:03] [failed, exit status 1] - output mismatch (see 208.out.bad)
--- /tmp/qemu-test.9cUFe0/tests/qemu-iotests/208.out Tue Jan 29 13:33:43 2019
+++ /tmp/qemu-test.9cUFe0/tests/qemu-iotests/208.out.bad Tue Jan 29 14:46:03 2019
@@ -1,9 +1,23 @@
+WARNING:qemu:qemu received signal 9: /tmp/qemu-test.9cUFe0/tests/qemu-iotests/../../x86_64-softmmu/qemu-system-x86_64 -chardev socket,id=mon,path=/tmp/qemu-iotests-quick-38268/tmpjdovgo/qemu-66480-monitor.sock -mon chardev=mon,mode=control -display none -vga none -qtest unix:path=/tmp/qemu-iotests-quick-38268/qemu-66480-qtest.sock -machine accel=qtest -nodefaults -machine accel=qtest -drive if=none,id=drive0,file=/tmp/qemu-iotests-quick-38268/66480-disk.img,format=qcow2,cache=writeback,node-name=drive0-node
+WARNING:qemu:qemu received signal 9: /tmp/qemu-test.9cUFe0/tests/qemu-iotests/../../x86_64-softmmu/qemu-system-x86_64 -chardev socket,id=mon,path=/tmp/qemu-iotests-quick-38268/tmpjdovgo/qemu-66480-monitor.sock -mon chardev=mon,mode=control -display none -vga none -qtest unix:path=/tmp/qemu-iotests-quick-38268/qemu-66480-qtest.sock -machine accel=qtest -nodefaults -machine accel=qtest -drive if=none,id=drive0,file=/tmp/qemu-iotests-quick-38268/66480-disk.img,format=qcow2,cache=writeback,node-name=drive0-node
Launching VM...
-Starting NBD server...
-{"return": {}}
-Adding NBD export...
-{"return": {}}
-Creating external snapshot...
-{"return": {}}
-Stopping NBD server...
-{"return": {}}
+Traceback (most recent call last):
+ File "208", line 36, in <module>
+ (vm.add_drive(disk_img_path, 'node-name=drive0-node', interface='none')
+ File "/tmp/qemu-test.9cUFe0/tests/qemu-iotests/../../scripts/qemu.py", line 295, in launch
+ self._launch()
+ File "/tmp/qemu-test.9cUFe0/tests/qemu-iotests/../../scripts/qemu.py", line 321, in _launch
+ self._post_launch()
+ File "/tmp/qemu-test.9cUFe0/tests/qemu-iotests/../../scripts/qtest.py", line 100, in _post_launch
+ super(QEMUQtestMachine, self)._post_launch()
+ File "/tmp/qemu-test.9cUFe0/tests/qemu-iotests/../../scripts/qemu.py", line 266, in _post_launch
+ self._qmp.accept()
+ File "/tmp/qemu-test.9cUFe0/tests/qemu-iotests/../../scripts/qmp/qmp.py", line 157, in accept
+ return self.__negotiate_capabilities()
+ File "/tmp/qemu-test.9cUFe0/tests/qemu-iotests/../../scripts/qmp/qmp.py", line 71, in __negotiate_capabilities
+ greeting = self.__json_read()
+ File "/tmp/qemu-test.9cUFe0/tests/qemu-iotests/../../scripts/qmp/qmp.py", line 82, in __json_read
+ data = self.__sockfile.readline()
+ File "/usr/local/lib/python2.7/socket.py", line 451, in readline
+ data = self._sock.recv(self._rbufsize)
+socket.error: [Errno 35] Resource temporarily unavailable--- tests/qemu-iotests/208 | 1 + 1 file changed, 1 insertion(+)
tests/qemu-iotests/208 +1 -0
@@ -23,6 +23,7 @@ import iotests iotests.verify_image_format(supported_fmts=['generic']) +iotests.verify_platform(unsupported_oses=['openbsd']) # FIXME with iotests.FilePath('disk.img') as disk_img_path, \ iotests.FilePath('disk-snapshot.img') as disk_snapshot_img_path, \
Signature · 1 line
2.20.1
PATCH v3 7/8 RFC iotests: Disable 209 on OpenBSD
In reply to Philippe Mathieu-DaudéThis test simply hangs with no information on OpenBSD.
--- tests/qemu-iotests/209 | 1 + 1 file changed, 1 insertion(+)
tests/qemu-iotests/209 +1 -0
@@ -23,6 +23,7 @@ from iotests import qemu_img_create, qemu_io, qemu_img_verbose, qemu_nbd, \ file_path iotests.verify_image_format(supported_fmts=['qcow2']) +iotests.verify_platform(unsupported_oses=['openbsd']) # FIXME disk, nbd_sock = file_path('disk', 'nbd-sock') nbd_uri = 'nbd+unix:///exp?socket=' + nbd_sock
Signature · 1 line
2.20.1
PATCH v3 8/8 RFC iotests: Disable 236 and 238 on OpenBSD
In reply to Philippe Mathieu-DaudéThese tests explode on OpenBSD:
$ gmake check-block
[...]
238 [17:16:09] [17:16:09] [failed, exit status 1] - output mismatch (see 238.out.bad)
--- /tmp/qemu-test.VKNS07/tests/qemu-iotests/238.out Tue Jan 29 17:09:03 2019
+++ /tmp/qemu-test.VKNS07/tests/qemu-iotests/238.out.bad Tue Jan 29 17:16:09 2019
@@ -1,6 +1,14 @@
-{"return": {}}
-{"return": {}}
-{"return": {}}
-{"return": {}}
-{"return": {}}
-{"return": {}}
+Traceback (most recent call last):
+ File "238", line 37, in <module>
+ vm.launch()
+ File "/tmp/qemu-test.VKNS07/tests/qemu-iotests/../../scripts/qemu.py", line 295, in launch
+ self._launch()
+ File "/tmp/qemu-test.VKNS07/tests/qemu-iotests/../../scripts/qemu.py", line 321, in _launch
+ self._post_launch()
+ File "/tmp/qemu-test.VKNS07/tests/qemu-iotests/../../scripts/qemu.py", line 266, in _post_launch
+ self._qmp.accept()
+ File "/tmp/qemu-test.VKNS07/tests/qemu-iotests/../../scripts/qmp/qmp.py", line 157, in accept
+ return self.__negotiate_capabilities()
+ File "/tmp/qemu-test.VKNS07/tests/qemu-iotests/../../scripts/qmp/qmp.py", line 73, in __negotiate_capabilities
+ raise QMPConnectError
+qmp.qmp.QMPConnectError---
This might be due to these tests requiring KVM?... Maybe we need a has_kvm argument to iotests.verify_platform()?
--- tests/qemu-iotests/236 | 1 + tests/qemu-iotests/238 | 2 ++ 2 files changed, 3 insertions(+)
tests/qemu-iotests/236 +1 -0
@@ -23,6 +23,7 @@ import iotests from iotests import log iotests.verify_image_format(supported_fmts=['generic']) +iotests.verify_platform(unsupported_oses=['openbsd']) # FIXME size = 64 * 1024 * 1024 granularity = 64 * 1024
tests/qemu-iotests/238 +2 -0
@@ -23,6 +23,8 @@ import os import iotests from iotests import log +iotests.verify_platform(unsupported_oses=['openbsd']) # FIXME + sys.path.append(os.path.join(os.path.dirname(__file__), '..', '..', 'scripts')) from qemu import QEMUMachine
Signature · 1 line
2.20.1
Re: [Qemu-devel] [PATCH v3 8/8] RFC iotests: Disable 236 and 238 on OpenBSD
Quoted 29 lines · Philippe Mathieu-Daudé
These tests explode on OpenBSD:
$ gmake check-block [...] 238 [17:16:09] [17:16:09] [failed, exit status 1] - output mismatch (see 238.out.bad) --- /tmp/qemu-test.VKNS07/tests/qemu-iotests/238.out Tue Jan 29 17:09:03 2019 +++ /tmp/qemu-test.VKNS07/tests/qemu-iotests/238.out.bad Tue Jan 29 17:16:09 2019 @@ -1,6 +1,14 @@ -{"return": {}} -{"return": {}} -{"return": {}} -{"return": {}} -{"return": {}} -{"return": {}} +Traceback (most recent call last): + File "238", line 37, in <module> + vm.launch() + File "/tmp/qemu-test.VKNS07/tests/qemu-iotests/../../scripts/qemu.py", line 295, in launch + self._launch() + File "/tmp/qemu-test.VKNS07/tests/qemu-iotests/../../scripts/qemu.py", line 321, in _launch + self._post_launch() + File "/tmp/qemu-test.VKNS07/tests/qemu-iotests/../../scripts/qemu.py", line 266, in _post_launch + self._qmp.accept() + File "/tmp/qemu-test.VKNS07/tests/qemu-iotests/../../scripts/qmp/qmp.py", line 157, in accept + return self.__negotiate_capabilities() + File "/tmp/qemu-test.VKNS07/tests/qemu-iotests/../../scripts/qmp/qmp.py", line 73, in __negotiate_capabilities + raise QMPConnectError +qmp.qmp.QMPConnectError
Quoted 4 lines
Signed-off-by Philippe Mathieu-Daudé <[email protected]>---
This might be due to these tests requiring KVM?... Maybe we need ahas_kvmargument toiotests.verify_platform()?
Uhhh, 236 shouldn't be doing anything fancy. It does boot a VM, but so does 237, 222, 219, 218, 216, ...
I actually don't know what this would be failing. Any chance to look at the core dump QEMU is leaving behind?
Quoted 31 lines
--- tests/qemu-iotests/236 | 1 + tests/qemu-iotests/238 | 2 ++ 2 files changed, 3 insertions(+)tests/qemu-iotests/236 +1
-0@@ -23,6 +23,7 @@ import iotests from iotests import log iotests.verify_image_format(supported_fmts=['generic']) +iotests.verify_platform(unsupported_oses=['openbsd']) # FIXME size = 64 * 1024 * 1024 granularity = 64 * 1024tests/qemu-iotests/238 +2
-0@@ -23,6 +23,8 @@ import os import iotests from iotests import log +iotests.verify_platform(unsupported_oses=['openbsd']) # FIXME + sys.path.append(os.path.join(os.path.dirname(__file__), '..', '..', 'scripts')) from qemu import QEMUMachine
Re: [Qemu-devel] [PATCH v3 8/8] RFC iotests: Disable 236 and 238 on OpenBSD
In reply to Philippe Mathieu-DaudéFWIW 238 also fails on my s390 box:
qemu-iotests]$ ./check -qcow2 238
QEMU -- "/home/cborntra/REPOS/qemu/build/tests/qemu-iotests/../../s390x-softmmu/qemu-system-s390x" -nodefaults -machine accel=qtest QEMU_IMG -- "/home/cborntra/REPOS/qemu/build/tests/qemu-iotests/../../qemu-img" QEMU_IO -- "/home/cborntra/REPOS/qemu/build/tests/qemu-iotests/../../qemu-io" --cache writeback -f qcow2 QEMU_NBD -- "/home/cborntra/REPOS/qemu/build/tests/qemu-iotests/../../qemu-nbd" IMGFMT -- qcow2 (compat=1.1) IMGPROTO -- file PLATFORM -- Linux/s390x s38lp08 5.0.0-rc5+ TEST_DIR -- /home/cborntra/REPOS/qemu/build/tests/qemu-iotests/scratch
SOCKET_SCM_HELPER -- /home/cborntra/REPOS/qemu/build/tests/qemu-iotests/socket_scm_helper
238 - output mismatch (see 238.out.bad)
home/cborntra/REPOS/qemu/build/tests/qemu-iotests/238.out.bad renamed from home/cborntra/REPOS/qemu/tests/qemu-iotests/238.out +5 -5
@@ -1,6 +1,6 @@ {"return": {}} -{"return": {}} -{"return": {}} -{"return": {}} -{"return": {}} -{"return": {}} +None +None +None +None +None
Failures: 238
Failed 1 of 1 tests
Have not looked into that yet.
Quoted 64 lines · Philippe Mathieu-Daudé
These tests explode on OpenBSD:
$ gmake check-block [...] 238 [17:16:09] [17:16:09] [failed, exit status 1] - output mismatch (see 238.out.bad) --- /tmp/qemu-test.VKNS07/tests/qemu-iotests/238.out Tue Jan 29 17:09:03 2019 +++ /tmp/qemu-test.VKNS07/tests/qemu-iotests/238.out.bad Tue Jan 29 17:16:09 2019 @@ -1,6 +1,14 @@ -{"return": {}} -{"return": {}} -{"return": {}} -{"return": {}} -{"return": {}} -{"return": {}} +Traceback (most recent call last): + File "238", line 37, in <module> + vm.launch() + File "/tmp/qemu-test.VKNS07/tests/qemu-iotests/../../scripts/qemu.py", line 295, in launch + self._launch() + File "/tmp/qemu-test.VKNS07/tests/qemu-iotests/../../scripts/qemu.py", line 321, in _launch + self._post_launch() + File "/tmp/qemu-test.VKNS07/tests/qemu-iotests/../../scripts/qemu.py", line 266, in _post_launch + self._qmp.accept() + File "/tmp/qemu-test.VKNS07/tests/qemu-iotests/../../scripts/qmp/qmp.py", line 157, in accept + return self.__negotiate_capabilities() + File "/tmp/qemu-test.VKNS07/tests/qemu-iotests/../../scripts/qmp/qmp.py", line 73, in __negotiate_capabilities + raise QMPConnectError +qmp.qmp.QMPConnectErrorSigned-off-by Philippe Mathieu-Daudé <[email protected]>---
This might be due to these tests requiring KVM?... Maybe we need ahas_kvmargument toiotests.verify_platform()?--- tests/qemu-iotests/236 | 1 + tests/qemu-iotests/238 | 2 ++ 2 files changed, 3 insertions(+)tests/qemu-iotests/236 +1
-0@@ -23,6 +23,7 @@ import iotests from iotests import log iotests.verify_image_format(supported_fmts=['generic']) +iotests.verify_platform(unsupported_oses=['openbsd']) # FIXME size = 64 * 1024 * 1024 granularity = 64 * 1024tests/qemu-iotests/238 +2
-0@@ -23,6 +23,8 @@ import os import iotests from iotests import log +iotests.verify_platform(unsupported_oses=['openbsd']) # FIXME + sys.path.append(os.path.join(os.path.dirname(__file__), '..', '..', 'scripts')) from qemu import QEMUMachine
Patchew URL: https://patchew.org/QEMU/[email protected]/
Patchew URL: https://patchew.org/QEMU/[email protected]/
Hi,
This series failed the docker-mingw@fedora build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally.
=== TEST SCRIPT BEGIN ===
#!/bin/bash
time make docker-test-mingw@fedora SHOW_ENV=1 J=14 === TEST SCRIPT END ===
The full log is available at
http://patchew.org/logs/[email protected]/testing.docker-mingw@fedora/?type=message.
---
Email generated automatically by Patchew [http://patchew.org/].
Please send your feedback to [email protected]