summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorXiao Ni <xni@redhat.com>2017-10-10 19:32:52 +0800
committerJes Sorensen <jsorensen@fb.com>2017-10-10 16:23:14 -0400
commit62e2991ff90ec4b1ab4972218bc55489067cba8c (patch)
treeaf49d86f341cc931f209d50e825d14b3520b2378 /tests
parentc76242c56efb4d799bb15af1035a5f503cb4b8f3 (diff)
downloadmdadm-62e2991ff90ec4b1ab4972218bc55489067cba8c.tar.gz
mdadm/test: Add one test case for raid5 reshape
This case tries to allow raid5 reshape to use backwards direction. It changes chunksize after reshape and stops the raid. Then starts the raid again. Signed-off-by: Xiao Ni <xni@redhat.com> Suggested-by: Jes Sorensen <jes.sorensen@gmail.com> Suggested-by: Zhilong Liu <zlliu@suse.com> Suggested-by: Paul Menzel <pmenzel@molgen.mpg.de> Signed-off-by: Jes Sorensen <jsorensen@fb.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/02r5grow17
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/02r5grow b/tests/02r5grow
index 386e82e..bb9bd6d 100644
--- a/tests/02r5grow
+++ b/tests/02r5grow
@@ -34,3 +34,20 @@ check nosync
sh tests/testdev $md0 3 $[size/2] 128
mdadm -S $md0
+
+# create a raid5 array and change the chunk
+mdadm -CR $md0 --level raid5 --metadata=1.1 --chunk=32 --raid-disks 3 --size $[size/2] $dev1 $dev2 $dev3
+check wait
+check state UUU
+check chunk 32
+
+mdadm $md0 --grow --chunk=64
+check reshape
+check wait
+check chunk 64
+
+mdadm -S $md0
+mdadm -A $md0 $dev1 $dev2 $dev3
+check state UUU
+check chunk 64
+mdadm -S $md0