]> git.ipfire.org Git - thirdparty/mdadm.git/blame - tests/00raid1
--wait or -W will wait for resync activity to finish on the given devices.
[thirdparty/mdadm.git] / tests / 00raid1
CommitLineData
5e7519fa
NB
1
2# create a simple mirror
3# test version0, version1, and no super
4# test resync and recovery.
5e7519fa 5
dab6685f
NB
6mdadm -CR $md0 -l 1 -n2 $dev0 $dev1
7check resync
8check raid1
9testdev $md0 1 $mdsize0 1
10mdadm -S $md0
5e7519fa 11
f6d75de8 12# now with version-1 superblock, spare
dab6685f
NB
13mdadm -CR $md0 -e1 --level=raid1 -n3 -x2 $dev0 missing missing $dev1 $dev2
14check recovery
15check raid1
16testdev $md0 1 $mdsize1 1
17mdadm -S $md0
5e7519fa
NB
18
19# now with no superblock
dab6685f
NB
20mdadm -B $md0 -l mirror -n2 $dev0 $dev1
21check resync
22check raid1
23testdev $md0 1 $size 1
24mdadm -S $md0
5e7519fa
NB
25
26# again, but with no resync
dab6685f
NB
27mdadm -B $md0 -l 1 --assume-clean -n2 $dev0 $dev1
28check raid1
29check nosync
30testdev $md0 1 $size 1
31mdadm -S $md0
5e7519fa
NB
32
33
34exit 0