]> git.ipfire.org Git - thirdparty/mdadm.git/blob - mdadm.conf.5
mdadm-0.8
[thirdparty/mdadm.git] / mdadm.conf.5
1 .TH MDADM.CONF 5
2 .SH NAME
3 mdadm.conf \- configuration for management of Software Raid with mdadm
4 .SH SYNOPSIS
5 /etc/mdadm.conf
6 .SH DESCRIPTION
7 .PP
8 .B mdadm
9 is a tool for creating, managing, and monitoring RAID devices using the
10 .B md
11 driver in Linux.
12 .PP
13 Some common tasks, such as assembling all arrays, can be simplified
14 by describing the devices and array in this configuration file.
15
16 .SS SYNTAX
17 The file should be seen as a collection of words separated by white
18 space (space, tab, or newline).
19 Any word that beings with a hash sign (#) starts a comment and that
20 word together with the remainder of the line are ignored.
21
22 Any line that start with white space (space or tab) is treated as
23 though it were a continuation of the previous line.
24
25 Empty lines are ignored, but otherwise each (non continuation) line
26 must start with a keyword as listed below. The key words are case
27 insensitive and can be abbreviated to 3 characters.
28
29 The keywords are:
30 .TP
31 .B DEVICE
32 A
33 .B device
34 line lists the devices (whole devices or partitions) that might contain
35 a component of an MD array. When looking for the components of an
36 array,
37 .B mdadm
38 will scan these devices and no others.
39
40 The
41 .B device
42 line may contain a number of different devices (separated by spaces)
43 and each device name can contain wild cards as defined by
44 .BR glob (7).
45
46 Also, there may be several device lines present in the file.
47
48 For example:
49 .IP
50 DEVICE /dev/hda* /dev/hdc*
51 .br
52 DEV /dev/sd*
53 .br
54 DEVICE /dev/discs/disc*/disc
55
56 .TP
57 .B ARRAY
58 The ARRAY lines identify actual arrays. The second word on the line
59 should be the name of the device where the array is normally
60 assembled, such as
61 .BR /dev/md1 .
62 Subsequent words identify the array, or identify the array as a member
63 of a group. If multiple identities are given,
64 then the array must match ALL identities to be considered a match.
65 Each identity word has a tag, and equals sign, and some value.
66 The options are:
67
68 .RS 4
69 .TP
70 .B uuid=
71 The value should be a 128 bit uuid in hexadecimal, with punctuation
72 interspersed if desired. This must match the uuid stored in the
73 superblock.
74 .TP
75 .B super-minor=
76 The value is an integer which indicates the minor number that was
77 stored in the superblock when the array was created. When an array is
78 created as /dev/mdX, then the minor number X is stored.
79 .TP
80 .B devices=
81 The value is a comma separated list of device names. Precisely these
82 devices will be used to assemble the array. Note that the devices
83 listed there must also be listed on a DEVICE line.
84 .TP
85 .B level=
86 The value is a raid level. This is not normally used to
87 identify an array, but is supported so that the output of
88
89 .B "mdadm --examine --scan"
90
91 can be use directly in the configuration file.
92 .TP
93 .B disks=
94 The value is the number of disks in a complete active array. As with
95 .B level=
96 this is mainly for compatibility with the output of
97
98 .BR "mdadm --examine --scan" .
99
100 .TP
101 .B spare-group=
102 The value is a textual name for a group of arrays. All arrays with
103 the same
104 .B spare-group
105 name are considered to be part of the same group. The significance of
106 a group of arrays is that
107 .B mdadm
108 will, when monitoring the arrays, move a spare drive from one array in
109 a group to another array in that group if the first array had a failed
110 or missing drive but no spare.
111 .RE
112
113 .TP
114 .B MAILADDR
115 The
116 .B mailaddr
117 line gives an E-mail address that alerts should be
118 sent to when
119 .M mdadm
120 is running in
121 .B --monitor
122 mode (and was given the
123 .B --scan
124 option). There should only be one
125 .B MAILADDR
126 line and it should have only one address.
127
128
129 .TP
130 .B PROGRAM
131 The
132 .B program
133 line gives the name of a program to be run when
134 .B "mdadm --monitor"
135 detects potentially interesting events on any of the arrays that it
136 is monitoring. This program gets run with two or three arguments, they
137 being the Event, the md device, and possibly the related component
138 device.
139
140 There should only be one
141 .B program
142 line and it should be give only one program.
143
144
145 .SH SEE ALSO
146 .BR mdadm (8),
147 .BR md (4).
148