dmraid.static (8) - Linux Manuals
dmraid.static: discover, configure and activate software (ATA)RAID
NAME
dmraid - discover, configure and activate software (ATA)RAIDSYNOPSIS
dmraid
dmraid
dmraid
dmraid
dmraid
dmraid
dmraid
dmraid
dmraid
[ -f|--format FORMAT-handler]
-S|--spare [RAID-set]
-M|--media "device-path"
dmraid
dmraid
dmraid
dmraid
S: Span (concatenation)
1. Using OROM to identify a new drive
2. Using dmraid to identify a new drive
3. Using hot spare drive
-f FORMAT-handler
This command adds hot spare support for one or more RAID sets.
1. When used with a format handler, which supports hot spare sets (e.g. isw), a hot spare is marked to be used when rebuilding any RAID set of that format.
2. When used when specifying a RAID set, the drive is added to that RAID set and will be used only to rebuild that set. Note: If the specified name does not match an existing RAID-set, a set with the new name will be created.
If
-E
is added to
-r
the RAID metadata on the devices gets conditionally erased.
Useful to erase old metadata after new one of different type has been
stored on a device in order to avoid discovering both. If you enter
-E
option
-D
will be enforced in order to have a fallback in case the wrong metadata
got erased.
Manual copying back onto the device is needed to recover from erasing
the wrong metadata using the dumped files devicename_formatname.dat
and devicename_formatname.offset.
Eg, to restore all *.dat files in the working directory to the respective devices:
If device-path(s) is/are given on the command line, the above actions
are restricted to those listed.
Add
-c
to display RAID device names only and
-cc
for CSV column output of RAID device properties.
See description of
-c
above for FIELD identifiers.
"dmraid -ay" activates all software RAID sets discovered.
"dmraid -an" deactivates all active software RAID sets which are not open
(e.g., mounted filesystem on them).
"dmraid -ay -f pdc" (pdc looked up from "dmraid -l") activates all
software RAID sets with Promise format discovered and ignores all other
supported formats.
"dmraid -r" discovers all software RAID devices supported on your system, e.g.:
"dmraid -s -s hpt45x_chidjhaiaa" displays properties of
set "hpt45x_chidjhaiaa", e.g.:
"dmraid -s -ccs hpt45" displays properties in column format of all sets
and subsets with hpt45* format, e.g.:
"dmraid -r --sep : -cpath:size" display paths and sizes in sectors for
RAID devices in column format using ':' as a delimiter, e.g.:
"dmraid -f isw -C Raid0 --type 0 --strip 8k --size 20g --disk "/dev/sdb /dev/sdc"" creates an ISW volume with
a name of "Raid0", 20Gig bytes in total, and 8kilo bytes strip size on two disks.
"dmraid -f isw -C Test0 --type 0 --disk "/dev/sdd /dev/sde"" creates an ISW volume with the default size and strip size.
"dmraid -f isw -C Test10 --type 01 --strip 128B --disk "/dev/sda /dev/sdb /dev/sdc /dev/sdd" creates a stacked
RAID device, RAID10 (isw format), with a name of "Test10", 128 blocks (512bytes) strip size , and the default volume size on
4 disks.
"dmraid -f isw -S -M /dev/sde" marks the device /dev/sde as a hot spare for rebuild
"dmraid -R isw_djaggchdde_RAID1 /dev/sde" starts rebuild of the RAID volume on device /dev/sde
DESCRIPTION
dmraid discovers block and software RAID devices (e.g., ATARAID)
by using multiple different metadata format handlers which
support various formats (e.g., Highpoint 37x series).
It offers activating RAID sets made up by 2 or more
discovered RAID devices, display properties of devices and sets (see option
-l
for supported metadata formats).
Block device access to activated RAID sets occurs via device-mapper nodes
/dev/mapper/RaidSetName.
RaidSetName starts with the format name (see
-l
option) which can be used to access all RAID sets of a specific format
easily with certain options (e.g.,
-a
below).
OPTIONS
For
-b:
d[evpath]|p[ath], sec[tors]|si[ze], ser[ialnumber].
For
-r:
de[vpath]|p[ath], f[ormat], r[aidname], t[ype], st[atus], se[ctors]|si[ze], da[taoffset]|o[ffset].
For
-s:
f[ormat], r[aidname], t[ype], sta[tus], str[ide], se[ctors]|si[ze], su[bsets], d[evices], sp[ares].
0: RAID0 (stripe)
1: RAID1 (mirror)
10: RAID10 (mirror on top of stripes)
01: RAID10 (stripe on top of mirrors) Note: Intel OROM displays this as RAID10
--type digit[digit...]
--size: [digits[k|K|m|M|g|G][b|B]]
If this option is missing, it's set to the default value pre-configured by the vendor. Note that different vendors may apply different constraints on the granularity of the size or the minimal value.
--strip: [digits[k|K|m|M|g|G][b|B]]
--disk: device-path[{,| }device-path...]
for f in *.dat
do
done
EXAMPLES
"dmraid -l" lists all supported metadata formats with their names along with
some descriptive information, e.g.:
hpt37x : (+) Highpoint HPT37X
hpt45x : (+) Highpoint HPT45X
isw : (+) Intel Software RAID
lsi : (0) LSI Logic MegaRAID
nvidia : (+) NVidia RAID
pdc : (+) Promise FastTrack
sil : (+) Silicon Image(tm) Medley(tm)
via : (+) VIA Software RAID
dos : (+) DOS partitions on SW RAIDs
(0): Discover, (+): Discover+Activate
/dev/dm-46: hpt45x, "hpt45x_chidjhaiaa-0", striped, ok, 320172928 sectors, data@ 0
/dev/dm-50: hpt45x, "hpt45x_chidjhaiaa-0", striped, ok, 320172928 sectors, data@ 0
/dev/dm-54: hpt45x, "hpt45x_chidjhaiaa-1", striped, ok, 320172928 sectors, data@ 0
/dev/dm-58: hpt45x, "hpt45x_chidjhaiaa-1", striped, ok, 320172928 sectors, data@ 0
*** Superset
name : hpt45x_chidjhaiaa
size : 640345856
stride : 128
type : raid10
status : ok
subsets: 2
dev : 4
spare : 0
---> Subset
name : hpt45x_chidjhaiaa-0
size : 640345856
stride : 128
type : stripe
status : ok
subsets: 0
dev : 2
spare : 0
---> Subset
name : hpt45x_chidjhaiaa-1
size : 640345856
stride : 128
type : stripe
status : ok
subsets: 0
dev : 2
spare : 0
hpt45x_chidjhaiaa,640345856,128,raid10,ok,4,0
hpt45x_chidjhaiaa-a,640345856,128,stripe,ok,2,0
hpt45x_chidjhaiaa-b,640345856,128,stripe,ok,2,0
/dev/dm-8:320173055
/dev/dm-12:320173055
/dev/dm-22:320173055
/dev/dm-26:320173055
/dev/dm-30:586114703
/dev/dm-34:586114703
/dev/dm-38:586114703
/dev/dm-42:586114703
/dev/dm-46:156301487
/dev/dm-50:156301487
/dev/dm-54:390624896
/dev/dm-58:390624896
/dev/dm-62:390624896
/dev/dm-66:390624896
DIAGNOSTICS
dmraid returns an exit code of 0 for success or 1 for error.
AUTHOR
Heinz Mauelshagen <Mauelshagen [at] RedHat.com>