File: mdadd.8

package info (click to toggle)
raidtools 0.42-21
  • links: PTS
  • area: main
  • in suites: potato
  • size: 400 kB
  • ctags: 128
  • sloc: ansic: 2,056; makefile: 137; sh: 85
file content (124 lines) | stat: -rw-r--r-- 2,884 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
.\" -*- nroff -*-
.TH mdadd 8
.SH NAME
mdadd, mdrun, mdstop \- command set to manage md devices.
.SH SYNOPSIS
.BI mdadd
[options] [md_device] [block_device_1 block_device_2 ...]

.BI mdrun
[options] md_device

.BI mdstop
[options] md_device

.SH DESCRIPTION
Md devices are virtual devices used to group real block devices. This
way, two 100MB disks can be used as a single 200MB disk, whatever
their interface type.

If you're using the
.B /proc
filesystem,
.B /proc/mdstat
gives you informations about md devices status.

Avaible commands are :
.br
.B mdadd
: groups several real devices into a virtual one.
.br
.B mdrun
: set a virtual device as usable, with a given mode.
.br
.B mdstop
: free real devices belonging to a virtual one, and flush buffers.
.SH OPTIONS
.IP "\fI\-a\fP"
Apply the command to the set of devices described in \fB/etc/mdtab\fP.
.IP "\fI\-r\fP"
Starts the virtual device after the real devices are being added. Only
applicable to \fBmdadd\fP.
.IP "\fI\-px\fP"
where x is :
.br
.I l
: starts the device in linear mode,
.br
.B 0
: starts the device in raid-0 mode,
.br
.B 1
: starts the device in raid-1 mode.
.br
assuming that the mode is either compiled into the kernel or loaded
using the \fBinsmod\fP program. Only applicable to \fBmdrun\fP.
.IP "\fI\-cn\fP"
(raid-0 and raid-1 only)
.br
Set the chunk size as \fBPAGE_SIZE << n\fP. You can also set the chunk
size in kilobytes with \fB\-cxk\fP where x is a power of 2. Only
applicable to \fBmdrun\fP.
.IP "\fI\-fn\fP"
(raid-1 only)
.br
Set the maximum fault number as \fBn\fP. Only applicable to
\fBmdrun\fP.
.IP "\fI-i\fP"
(raid1 only)
.br
Show version number as well as driver version the command is compiled for.
.SH EXAMPLES
To configure the device :

.B /sbin/mdadd /dev/md0 /dev/sdb1 /dev/sdc2

Warning,
.B /sbin/mdadd /dev/md0 /dev/sdb1 /dev/sdc2
is different from
.B /sbin/mdadd /dev/md0 /dev/sdc2 /dev/sdb1
because there's no internal ordering.

To make it usable in linear mode :

.B /sbin/mdrun -pl /dev/md0

To make it usable in striped mode, with 8kb chunks :

.B /sbin/mdrun -p0 -c8k /dev/md0

To stop it :

.B /sbin/mdstop /dev/md0

If you have described you md-devices in
.BI /etc/mdtab
, you can replace the two first steps with

.B	/sbin/mdadd \ -ar
.SH FILES
.BI	/sbin/mdadd
: main command. Other commands are symlinks to this file.
.br
.BI	/etc/mdtab
: configuration file.
.br
.BI	/proc/mdstat
: driver and devices status
.SH AUTHOR
.B mdadd
was written as a kernel interface to md driver by Marc ZYNGIER
<zyngier@amertume.ufr-info-p7.ibp.fr>.
.SH BUGS
Options that are not applicable to a command are silently ignored
and/or may lead to unxepected behaviour. This man page (and the whole
documentation) is really brain-dead and should be rewritten. Any
volunteer ?
.SH SEE ALSO
.BR mdtab "(5)
.br
.BR modules
package.
.br
More informations in the README file included in the package.