]> git.ipfire.org Git - thirdparty/mdadm.git/blame - md.4
mdadm-0.7.2
[thirdparty/mdadm.git] / md.4
CommitLineData
56eb10c0
NB
1.TH MD 4
2.SH NAME
3md \- Multiple Device driver aka Linux Software Raid
4.SH SYNOPSIS
5.BI /dev/md n
6.br
7.BI /dev/md/ n
8.SH DESCRIPTION
9The
10.B md
11driver provides virtual devices that are created from one or more
12independant underlying devices. This array of devices often contains
13redundancy, and hence the acronym RAID which stands for a Redundant
14Array of Independant Devices.
15.PP
16.B md
17support RAID levels 1 (mirroring) 4 (striped array with parity device) and 5
18(striped array with distributed parity information. If a single underlying
11a3e71d 19device fails while using one of these level, the array will continue
56eb10c0
NB
20to function.
21.PP
22.B md
23also supports a number of pseudo RAID (non-redundant) configuations
24including RAID0 (striped array), LINEAR (catenated array) and
25MULTIPATH (a set of different interfaces to the same device).
26
11a3e71d 27.SS MD SUPER BLOCK
56eb10c0
NB
28With the exception of Legacy Arrays described below, each device that
29is incorportated into an MD array has a
30.I super block
31written towards the end of the device. This superblock records
32information about the structure and state of the array so that the
11a3e71d 33array can be reliably re-assembled after a shutdown.
56eb10c0
NB
34
35The superblock is 4K long and is written into a 64K aligned block that
11a3e71d 36starts at least 64K and less than 128K from the end of the device
56eb10c0
NB
37(i.e. to get the address of the superblock round the size of the
38device down to a multiple of 64K and then subtract 64K).
11a3e71d 39The available size of each device is the amount of space before the
56eb10c0
NB
40super block, so between 64K and 128K is lost when a device in
41incorporated into an MD array.
42
43The superblock contains, among other things:
44.TP
45LEVEL
11a3e71d
NB
46The manner in which the devices are arranged into the array
47(linear, raid0, raid1, raid4, raid5, multipath).
56eb10c0
NB
48.TP
49UUID
50a 128 bit Universally Unique Identifier that identifies the array that
51this device is part of.
52
11a3e71d
NB
53.SS LEGACY ARRAYS
54Early versions of the
55.B md
56driver only supported Linear and Raid0 configurations and so
57did not use an MD superblock (as there is not state that needs to be
58recorded). While it is strongly recommended that all newly created
59arrays utilise a superblock to help ensure that they are assembled
60properly, the
61.B md
62driver still supports legacy linear and raid0 md arrays that
63do not have a superblock.
64
56eb10c0 65.SS LINEAR
11a3e71d
NB
66
67A linear array simply catenates the available space on each
68drive together to form one large virtual drive.
69
70One advantage of this arrangement over the more common RAID0
71arrangement is that the array may be reconfigured at a later time with
72an extra drive and so the array is made bigger without disturbing the
73data that is on the array. However this cannot be done on a live
74array.
75
76
77
56eb10c0 78.SS RAID0
11a3e71d
NB
79
80A RAID0 array (which has zero redundancy) is also known as a
81striped array.
56eb10c0
NB
82.SS RAID1
83.SS RAID4
84.SS RAID5
11a3e71d 85.SS MUTIPATH
56eb10c0
NB
86.SS REBUILD/RESYNC
87.SH FILES
88.TP
89.B /proc/mdstat
90Contains information about the status of currently running array.
91.TP
92.B /proc/sys/dev/raid/speed_limit_min
93A readable and writable file that reflects the current goal rebuild
94speed for times when non-rebuild activity is current on an array.
95The speed is in Kibibytes per second, and is a per-device rate, not a
96per-array rate (which means that an array with more disc will shuffle
97more data for a given speed). The default is 100.
98
99.TP
100.B /proc/sys/dev/raid/speed_limit_max
101A readable and writable file that reflects the current goal rebuild
102speed for times when no non-rebuild activity is current on an array.
103The default is 100,000.
104
105.SH SEE ALSO
106.BR mdadm (8),
107.BR mkraid (8).