]> git.ipfire.org Git - thirdparty/mdadm.git/blob - tests/07revert-grow
DDF: convert big-endian __u64 to be64 type
[thirdparty/mdadm.git] / tests / 07revert-grow
1 set -e -x
2
3 # revert a reshape that is increasing the number of devices,
4 # raid5, raid6, and raid10
5
6 # RAID5
7 mdadm -CR --assume-clean $md0 -l5 -n4 -x1 $devlist4
8 check raid5
9 testdev $md0 3 $mdsize1 512
10 mdadm -G $md0 -n 5
11 sleep 3
12 mdadm -S $md0
13 mdadm -A $md0 --update=revert-reshape $devlist4 --backup-file=/tmp/md-backup
14 check wait
15 check raid5
16 testdev $md0 3 $mdsize1 512
17 mdadm -S $md0
18
19 # RAID6
20 mdadm -CR --assume-clean $md0 -l6 -n4 -x1 $devlist4
21 check raid6
22 testdev $md0 2 $mdsize1 512
23 mdadm -G $md0 -n 5
24 sleep 3
25 mdadm -S $md0
26 mdadm -A $md0 --update=revert-reshape $devlist4 --backup-file=/tmp/md-backup
27 check wait
28 check raid6
29 testdev $md0 2 $mdsize1 512
30 mdadm -S $md0
31
32 # RAID10
33 mdadm -CR --assume-clean $md0 -l10 -n4 -x1 $devlist4
34 check raid10
35 testdev $md0 2 $mdsize1 512
36 mdadm -G $md0 -n 5
37 sleep 3
38 mdadm -S $md0
39 strace -o /tmp/str ./mdadm -A $md0 --update=revert-reshape $devlist4
40 check wait
41 check raid10
42 testdev $md0 2 $mdsize1 512
43 mdadm -S $md0