qemu/tests/qemu-iotests
Stefan Hajnoczi 550830f935 block: delete cow block driver
This patch removes support for the cow file format.

Normally we do not break backwards compatibility but in this case there
is no impact and it is the most logical option.  Extraordinary claims
require extraordinary evidence so I will show why removing the cow block
driver is the right thing to do.

The cow file format is the disk image format for Usermode Linux, a way
of running a Linux system in userspace.  The performance of UML was
never great and it was hacky, but it enjoyed some popularity before
hardware virtualization support became mainstream.

QEMU's block/cow.c is supposed to read this image file format.
Unfortunately the file format was underspecified:

1. Earlier Linux versions used the MAXPATHLEN constant for the backing
   filename field.  The value of MAXPATHLEN can change, so Linux
   switched to a 4096 literal but QEMU has a 1024 literal.

2. Padding was not used on the header struct (both in the Linux kernel
   and in QEMU) so the struct layout varied across architectures.  In
   particular, i386 and x86_64 were different due to int64_t alignment
   differences.  Linux now uses __attribute__((packed)), QEMU does not.

Therefore:

1. QEMU cow images do not conform to the Linux cow image file format.

2. cow images cannot be shared between different host architectures.

This means QEMU cow images are useless and QEMU has not had bug reports
from users actually hitting these issues.

Let's get rid of this thing, it serves no purpose and no one will be
affected.

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Markus Armbruster <armbru@redhat.com>
Message-id: 1410877464-20481-1-git-send-email-stefanha@redhat.com
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
2014-09-22 11:39:45 +01:00
..
sample_images qemu-iotests: Add data pattern in version3 VMDK sample image in 059 2014-08-15 15:07:13 +02:00
.gitignore .gitignore: ignore tests/qemu-iotests/socket_scm_helper 2013-10-01 16:06:07 +04:00
001 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
001.out
002 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
002.out qemu-iotests: A few more bdrv_pread/pwrite tests 2013-04-15 08:26:18 +02:00
003 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
003.out
004 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
004.out
005 qemu-iotests: Don't run 005 on vmdk split formats 2014-02-14 18:05:39 +01:00
005.out
006
006.out
007 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
007.out
008 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
008.out
009 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
009.out
010 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
010.out
011 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
011.out
012 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
012.out
013 qemu-iotests: change _supported_proto to file for various tests 2014-02-09 09:12:38 +01:00
013.out qemu-iotests: Filter out 'qemu-io> ' prompt 2013-11-29 17:41:13 +01:00
014 qemu-iotests: change _supported_proto to file for various tests 2014-02-09 09:12:38 +01:00
014.out qemu-iotests: Filter out 'qemu-io> ' prompt 2013-11-29 17:41:13 +01:00
015 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
015.out
016 qemu-iotests: enable test 016 and 025 to work with NFS protocol 2014-02-09 09:12:38 +01:00
016.out
017 qemu-iotests: Add _unsupported_imgopts for vmdk subformats 2014-01-22 12:07:16 +01:00
017.out qemu-iotests: Filter out 'qemu-io> ' prompt 2013-11-29 17:41:13 +01:00
018 qemu-iotests: change _supported_proto to file for various tests 2014-02-09 09:12:38 +01:00
018.out qemu-iotests: Filter out 'qemu-io> ' prompt 2013-11-29 17:41:13 +01:00
019 block: qemu-iotests: make test 019 and 086 work with spaced pathnames 2014-04-29 16:19:37 +02:00
019.out qemu-iotests: Filter out 'qemu-io> ' prompt 2013-11-29 17:41:13 +01:00
020 qemu-iotests: blacklist test 020 for NFS protocol 2014-02-09 09:12:38 +01:00
020.out qemu-iotests: Filter out 'qemu-io> ' prompt 2013-11-29 17:41:13 +01:00
021 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
021.out
022
022.out qemu-iotests: Filter out 'qemu-io> ' prompt 2013-11-29 17:41:13 +01:00
023 qemu-iotests: change _supported_proto to file for various tests 2014-02-09 09:12:38 +01:00
023.out qemu-iotests: Filter out 'qemu-io> ' prompt 2013-11-29 17:41:13 +01:00
024 qemu-iotests: change _supported_proto to file for various tests 2014-02-09 09:12:38 +01:00
024.out qemu-iotests: Filter out 'qemu-io> ' prompt 2013-11-29 17:41:13 +01:00
025 qemu-iotests: Run 025 for Archipelago block driver 2014-09-10 10:41:29 +02:00
025.out qemu-iotests: Filter out 'qemu-io> ' prompt 2013-11-29 17:41:13 +01:00
026 qemu-iotests: change _supported_proto to file for various tests 2014-02-09 09:12:38 +01:00
026.out qcow2: Don't rely on free_cluster_index in alloc_refcount_block() (CVE-2014-0147) 2014-04-01 15:21:03 +02:00
026.out.nocache qemu-iotests: Correct 026 output 2013-10-07 13:23:19 +02:00
027 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
027.out
028 qemu-iotests: Fix 028 reference output for qed 2014-08-20 11:51:28 +02:00
028.out qemu-iotests: Fix 028 reference output for qed 2014-08-20 11:51:28 +02:00
029 qcow2: Fix L1 allocation size in qcow2_snapshot_load_tmp() (CVE-2014-0145) 2014-04-01 15:22:35 +02:00
029.out qcow2: Fix L1 allocation size in qcow2_snapshot_load_tmp() (CVE-2014-0145) 2014-04-01 15:22:35 +02:00
030 qemu-iotests: Fix blkdebug in VM drive in 030 2014-05-19 11:36:49 +02:00
030.out qemu-iotests: add tests for streaming error handling 2012-09-28 19:40:56 +02:00
031 iotests: Use $PYTHON for Python scripts 2014-06-27 20:00:00 +02:00
031.out qcow2: Add corrupt bit 2013-08-30 15:48:43 +02:00
032 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
032.out qemu-iotests: Filter out 'qemu-io> ' prompt 2013-11-29 17:41:13 +01:00
033 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
033.out
034 qemu-iotests: change _supported_proto to file for various tests 2014-02-09 09:12:38 +01:00
034.out
035 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
035.out qemu-iotests: Filter out 'qemu-io> ' prompt 2013-11-29 17:41:13 +01:00
036 qcow2: Fix error path for unknown incompatible features 2014-07-18 13:12:15 +01:00
036.out qcow2: Fix error path for unknown incompatible features 2014-07-18 13:12:15 +01:00
037 qemu-iotests: change _supported_proto to file for various tests 2014-02-09 09:12:38 +01:00
037.out qemu-iotests: Filter out 'qemu-io> ' prompt 2013-11-29 17:41:13 +01:00
038 qemu-iotests: change _supported_proto to file for various tests 2014-02-09 09:12:38 +01:00
038.out qemu-iotests: Filter out 'qemu-io> ' prompt 2013-11-29 17:41:13 +01:00
039 iotests: Use $PYTHON for Python scripts 2014-06-27 20:00:00 +02:00
039.out qemu-iotests: Fix core dump suppression in test 039 2014-05-19 11:36:49 +02:00
040 block: make 'top' argument to block-commit optional 2014-07-01 10:15:33 +02:00
040.out qemu-iotests: Test BLOCK_JOB_READY event for 0Kb image active commit 2014-06-26 13:51:00 +02:00
041 qemu-iotests: Disable Quorum testing in 041 when Quorum is not builtin 2014-07-07 09:15:29 +02:00
041.out mirror: Fix qiov size for short requests 2014-07-07 09:15:29 +02:00
042 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
042.out qemu-iotests: Test qemu-img operation on zero size image 2012-10-24 10:26:18 +02:00
043 qemu-iotests: change _supported_proto to file for various tests 2014-02-09 09:12:38 +01:00
043.out qemu-iotests: Add 043 backing file chain infinite loop test 2012-10-24 10:26:19 +02:00
044 qemu-iotests: qcow2: Test growing large refcount table 2012-11-14 18:19:21 +01:00
044.out qcow2: Don't rely on free_cluster_index in alloc_refcount_block() (CVE-2014-0147) 2014-04-01 15:21:03 +02:00
045 qemu-iotests: add tests for runtime fd passing via SCM rights 2013-09-12 10:12:47 +02:00
045.out qemu-iotests: add tests for runtime fd passing via SCM rights 2013-09-12 10:12:47 +02:00
046 qcow2: Set zero flag for discarded clusters 2014-02-21 21:02:21 +01:00
046.out qemu-iotests: Filter out 'qemu-io> ' prompt 2013-11-29 17:41:13 +01:00
047 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
047.out qemu-iotests: Filter out 'qemu-io> ' prompt 2013-11-29 17:41:13 +01:00
048 qemu-iotests: Split qcow2 only cases in 048 2013-12-04 14:31:39 +01:00
048.out qemu-iotests: Split qcow2 only cases in 048 2013-12-04 14:31:39 +01:00
049 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
049.out qapi: introduce PreallocMode and new PreallocModes full and falloc. 2014-09-12 15:43:06 +02:00
050 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
050.out qemu-iotests: add tests for rebasing zero clusters 2013-03-15 16:07:51 +01:00
051 block: Catch backing files assigned to non-COW drivers 2014-06-26 13:51:01 +02:00
051.out scsi-bus: Convert DeviceClass init to realize 2014-08-26 13:20:44 +02:00
052 qemu-iotests: change _supported_proto to file for various tests 2014-02-09 09:12:38 +01:00
052.out qemu-iotests: add 052 BDRV_O_SNAPSHOT test 2013-03-19 11:48:37 +01:00
053 qemu-iotests: Quote $TEST_IMG* and $TEST_DIR usage 2013-09-27 11:10:45 +02:00
053.out qemu-iotests: add 053 unaligned compressed image size test 2013-04-22 11:37:12 +02:00
054 iotests: Use $PYTHON for Python scripts 2014-06-27 20:00:00 +02:00
054.out qemu-iotests: Adjustments due to error propagation 2013-09-12 10:12:48 +02:00
055 qemu-iotests: Make test case 030, 040 and 055 deterministic 2013-11-29 13:40:37 +01:00
055.out Add tests for sync modes 'TOP' and 'NONE' 2013-07-26 22:01:31 +02:00
056 qemu-iotests: Improve and make use of QMPTestCase.wait_until_completed() 2014-04-25 18:05:05 +02:00
056.out Add tests for sync modes 'TOP' and 'NONE' 2013-07-26 22:01:31 +02:00
057 qemu-iotests: add 057 internal snapshot for block device test case 2013-09-12 10:12:47 +02:00
057.out qemu-iotests: add 057 internal snapshot for block device test case 2013-09-12 10:12:47 +02:00
058 qemu-iotests: add test for snapshot in qemu-img convert 2013-12-04 15:19:00 +01:00
058.out qemu-iotests: add test for snapshot in qemu-img convert 2013-12-04 15:19:00 +01:00
059 qemu-iotests: Add data pattern in version3 VMDK sample image in 059 2014-08-15 15:07:13 +02:00
059.out qemu-iotests: Add data pattern in version3 VMDK sample image in 059 2014-08-15 15:07:13 +02:00
060 iotests: Add more tests for qcow2 corruption 2014-09-22 11:39:29 +01:00
060.out iotests: Add more tests for qcow2 corruption 2014-09-22 11:39:29 +01:00
061 iotests: Use $PYTHON for Python scripts 2014-06-27 20:00:00 +02:00
061.out change block layer to support both QemuOpts and QEMUOptionParamter 2014-06-16 17:23:20 +08:00
062 qemu-iotests: Snapshotting zero clusters 2013-08-30 15:28:52 +02:00
062.out qemu-iotests: Snapshotting zero clusters 2013-08-30 15:28:52 +02:00
063 qemu-iotests: change _supported_proto to file for various tests 2014-02-09 09:12:38 +01:00
063.out add qemu-img convert -n option (skip target volume creation) 2013-09-06 15:25:07 +02:00
064 block: qemu-iotests for vhdx, add write test support 2013-11-07 13:58:59 +01:00
064.out block: qemu-iotests for vhdx, add write test support 2013-11-07 13:58:59 +01:00
065 iotests: Drop Python version from 065's Shebang 2014-06-27 20:00:01 +02:00
065.out qemu-iotests: Additional info from qemu-img info 2013-10-11 16:49:50 +02:00
066 qemu-iotests: Discard preallocated zero clusters 2013-10-11 16:49:59 +02:00
066.out qemu-iotests: Discard preallocated zero clusters 2013-10-11 16:49:59 +02:00
067 qemu-iotests: Filter out actual image size in 067 2013-11-07 13:53:30 +01:00
067.out block: optimize zero writes with bdrv_write_zeroes 2014-05-19 13:42:27 +02:00
068 qemu-iotests: Test for loading VM state from qcow2 2013-10-25 11:08:20 +02:00
068.out qemu-iotests: Test for loading VM state from qcow2 2013-10-25 11:08:20 +02:00
069 block: delete cow block driver 2014-09-22 11:39:45 +01:00
069.out block: Print its file name if backing file opening failed 2013-11-14 13:09:06 +01:00
070 block: add test for vhdx image created by Disk2VHD 2014-05-19 11:36:48 +02:00
070.out block: add test for vhdx image created by Disk2VHD 2014-05-19 11:36:48 +02:00
071 qemu-iotests: change _supported_proto to file for various tests 2014-02-09 09:12:38 +01:00
071.out iotests: Test new blkdebug/blkverify interface 2014-01-22 12:07:18 +01:00
072 block: delete cow block driver 2014-09-22 11:39:45 +01:00
072.out iotests: Test file format nesting 2014-01-22 12:07:18 +01:00
073 qemu-iotests: Test qcow2 count_contiguous_clusters() 2013-11-15 13:37:43 +01:00
073.out qemu-iotests: Test qcow2 count_contiguous_clusters() 2013-11-15 13:37:43 +01:00
074 qemu-iotests: Split qcow2 only cases in 048 2013-12-04 14:31:39 +01:00
074.out qemu-iotests: Split qcow2 only cases in 048 2013-12-04 14:31:39 +01:00
075 block/cloop: fix offsets[] size off-by-one 2014-04-01 13:59:47 +02:00
075.out block/cloop: fix offsets[] size off-by-one 2014-04-01 13:59:47 +02:00
076 parallels: Sanity check for s->tracks (CVE-2014-0142) 2014-04-01 15:22:35 +02:00
076.out parallels: Sanity check for s->tracks (CVE-2014-0142) 2014-04-01 15:22:35 +02:00
077 qemu-iotest: Make 077 raw-only 2014-02-09 09:12:38 +01:00
077.out qemu-iotests: Test pwritev RMW logic 2014-01-24 17:40:25 +01:00
078 bochs: Fix catalog size check 2014-04-11 13:59:49 +02:00
078.out bochs: Fix catalog size check 2014-04-11 13:59:49 +02:00
079 qemu-iotests: add test for qcow2 preallocation with different cluster sizes 2014-02-09 09:12:39 +01:00
079.out qemu-iotests: add test for qcow2 preallocation with different cluster sizes 2014-02-09 09:12:39 +01:00
080 qcow2: Check maximum L1 size in qcow2_snapshot_load_tmp() (CVE-2014-0143) 2014-04-01 15:22:35 +02:00
080.out qcow2: Check maximum L1 size in qcow2_snapshot_load_tmp() (CVE-2014-0143) 2014-04-01 15:22:35 +02:00
081 quorum: Add the rewrite-corrupted parameter to quorum 2014-06-27 14:18:17 +02:00
081.out quorum: Add the rewrite-corrupted parameter to quorum 2014-06-27 14:18:17 +02:00
082 qemu-iotests: Check qemu-img command line parsing 2014-02-21 22:10:31 +01:00
082.out qcow2: Add falloc and full preallocation option 2014-09-12 15:43:06 +02:00
083 iotests: Fix 083 for out-of-tree builds 2014-06-27 20:00:01 +02:00
083.out qemu-iotests: add 083 NBD client disconnect tests 2014-03-14 16:29:02 +01:00
084 block: iotest - update 084 to test static VDI image creation 2014-08-15 15:07:15 +02:00
084.out block: iotest - update 084 to test static VDI image creation 2014-08-15 15:07:15 +02:00
085 block: qemu-iotests - update 085 to use common.qemu 2014-05-09 20:57:32 +02:00
085.out block: qemu-iotests 085 - live snapshots tests 2014-03-07 11:36:12 +01:00
086 block: qemu-iotests: make test 019 and 086 work with spaced pathnames 2014-04-29 16:19:37 +02:00
086.out qemu-iotests: Test progress output for conversion 2014-03-05 15:58:32 +01:00
087 qemu-iotests: Check common namespace for id and node-name 2014-04-22 12:12:30 +02:00
087.out qemu-iotests: Check common namespace for id and node-name 2014-04-22 12:12:30 +02:00
088 vpc: Validate block size (CVE-2014-0142) 2014-04-01 13:59:47 +02:00
088.out vpc: Validate block size (CVE-2014-0142) 2014-04-01 13:59:47 +02:00
089 iotests: Use _img_info in test 089 2014-05-28 14:28:46 +02:00
089.out iotests: Use _img_info in test 089 2014-05-28 14:28:46 +02:00
090 iotests: Discarding compressed clusters on qcow2 2014-04-29 16:39:51 +02:00
090.out iotests: Discarding compressed clusters on qcow2 2014-04-29 16:39:51 +02:00
091 qemu-iotests: Handle cache mode option in 091 2014-05-28 14:22:25 +02:00
091.out block: qemu-iotests - test for live migration 2014-05-09 20:57:32 +02:00
092 qcow1: Stricter backing file length check 2014-05-19 11:36:49 +02:00
092.out qcow1: Stricter backing file length check 2014-05-19 11:36:49 +02:00
095 block: add qemu-iotest for resize base during live commit 2014-06-27 11:37:54 +02:00
095.out block: add qemu-iotest for resize base during live commit 2014-06-27 11:37:54 +02:00
099 block: delete cow block driver 2014-09-22 11:39:45 +01:00
099.out iotests: Add test for image filename construction 2014-08-20 14:33:42 +02:00
100 qemu-iotests: add multiwrite test cases 2014-08-29 14:10:15 +01:00
100.out qemu-iotests: add multiwrite test cases 2014-08-29 14:10:15 +01:00
101 qemu-iotests: add test case 101 for short file I/O 2014-08-22 11:01:12 +02:00
101.out qemu-iotests: add test case 101 for short file I/O 2014-08-22 11:01:12 +02:00
103 iotests: Add test for qcow2's cache options 2014-08-20 11:51:28 +02:00
103.out iotests: Add test for qcow2's cache options 2014-08-20 11:51:28 +02:00
104 block: round up file size to nearest sector 2014-09-12 15:43:06 +02:00
104.out block: round up file size to nearest sector 2014-09-12 15:43:06 +02:00
check iotests: Use $PYTHON for Python scripts 2014-06-27 20:00:00 +02:00
common block: delete cow block driver 2014-09-22 11:39:45 +01:00
common.config iotests: Allow out-of-tree run 2014-06-27 20:00:00 +02:00
common.filter block: round up file size to nearest sector 2014-09-12 15:43:06 +02:00
common.pattern block: qemu-iotests, add quotes to $TEST_IMG usage io pattern tests 2013-11-07 13:53:31 +01:00
common.qemu Fix new typos (found by codespell) 2014-06-24 20:01:24 +04:00
common.rc qemu-iotests: Fix 028 reference output for qed 2014-08-20 11:51:28 +02:00
COPYING
group block: round up file size to nearest sector 2014-09-12 15:43:06 +02:00
iotests.py iotests: Allow out-of-tree run 2014-06-27 20:00:00 +02:00
Makefile
nbd-fault-injector.py tests: add nbd-fault-injector.py utility 2014-03-14 16:28:28 +01:00
qcow2.py qcow2: Fix error path for unknown incompatible features 2014-07-18 13:12:15 +01:00
qed.py
README
socket_scm_helper.c iotests: Send the correct fd in socket_scm_helper 2014-09-12 10:27:54 +02:00

=== This is the QEMU I/O test suite ===

* Intro

This package contains a simple test suite for the I/O layer of qemu.
It does not require a guest, but only the qemu, qemu-img and qemu-io
binaries.  This does limit it to exercise the low-level I/O path only
but no actual block drivers like ide, scsi or virtio.

* Usage

Just run ./check to run all tests for the raw image format, or ./check
-qcow2 to test the qcow2 image format.  The output of ./check -h explains
additional options to test further image formats or I/O methods.

* Feedback and patches

Please send improvements to the test suite, general feedback or just
reports of failing tests cases to qemu-devel@savannah.nongnu.org.