aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2011-01-13 20:30:47 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2011-01-13 20:30:47 -0500
commitf6bcfd94c0a97c11ce9197ade93a08bc8af6e057 (patch)
tree83d867565b4f2a7627b3288f9e000eaf2b217be9 /Documentation
parent509e4aef44eb10e4aef1f81c3c3ff1214671503b (diff)
parent9d09e663d5502c46f2d9481c04c1087e1c2da698 (diff)
Merge git://git.kernel.org/pub/scm/linux/kernel/git/agk/linux-2.6-dm
* git://git.kernel.org/pub/scm/linux/kernel/git/agk/linux-2.6-dm: (32 commits) dm: raid456 basic support dm: per target unplug callback support dm: introduce target callbacks and congestion callback dm mpath: delay activate_path retry on SCSI_DH_RETRY dm: remove superfluous irq disablement in dm_request_fn dm log: use PTR_ERR value instead of ENOMEM dm snapshot: avoid storing private suspended state dm snapshot: persistent make metadata_wq multithreaded dm: use non reentrant workqueues if equivalent dm: convert workqueues to alloc_ordered dm stripe: switch from local workqueue to system_wq dm: dont use flush_scheduled_work dm snapshot: remove unused dm_snapshot queued_bios_work dm ioctl: suppress needless warning messages dm crypt: add loop aes iv generator dm crypt: add multi key capability dm crypt: add post iv call to iv generator dm crypt: use io thread for reads only if mempool exhausted dm crypt: scale to multiple cpus dm crypt: simplify compatible table output ...
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/device-mapper/dm-crypt.txt7
-rw-r--r--Documentation/device-mapper/dm-raid.txt70
2 files changed, 76 insertions, 1 deletions
diff --git a/Documentation/device-mapper/dm-crypt.txt b/Documentation/device-mapper/dm-crypt.txt
index 524de926290d..59293ac4a5d0 100644
--- a/Documentation/device-mapper/dm-crypt.txt
+++ b/Documentation/device-mapper/dm-crypt.txt
@@ -8,7 +8,7 @@ Parameters: <cipher> <key> <iv_offset> <device path> <offset>
8 8
9<cipher> 9<cipher>
10 Encryption cipher and an optional IV generation mode. 10 Encryption cipher and an optional IV generation mode.
11 (In format cipher-chainmode-ivopts:ivmode). 11 (In format cipher[:keycount]-chainmode-ivopts:ivmode).
12 Examples: 12 Examples:
13 des 13 des
14 aes-cbc-essiv:sha256 14 aes-cbc-essiv:sha256
@@ -20,6 +20,11 @@ Parameters: <cipher> <key> <iv_offset> <device path> <offset>
20 Key used for encryption. It is encoded as a hexadecimal number. 20 Key used for encryption. It is encoded as a hexadecimal number.
21 You can only use key sizes that are valid for the selected cipher. 21 You can only use key sizes that are valid for the selected cipher.
22 22
23<keycount>
24 Multi-key compatibility mode. You can define <keycount> keys and
25 then sectors are encrypted according to their offsets (sector 0 uses key0;
26 sector 1 uses key1 etc.). <keycount> must be a power of two.
27
23<iv_offset> 28<iv_offset>
24 The IV offset is a sector count that is added to the sector number 29 The IV offset is a sector count that is added to the sector number
25 before creating the IV. 30 before creating the IV.
diff --git a/Documentation/device-mapper/dm-raid.txt b/Documentation/device-mapper/dm-raid.txt
new file mode 100644
index 000000000000..33b6b7071ac8
--- /dev/null
+++ b/Documentation/device-mapper/dm-raid.txt
@@ -0,0 +1,70 @@
1Device-mapper RAID (dm-raid) is a bridge from DM to MD. It
2provides a way to use device-mapper interfaces to access the MD RAID
3drivers.
4
5As with all device-mapper targets, the nominal public interfaces are the
6constructor (CTR) tables and the status outputs (both STATUSTYPE_INFO
7and STATUSTYPE_TABLE). The CTR table looks like the following:
8
91: <s> <l> raid \
102: <raid_type> <#raid_params> <raid_params> \
113: <#raid_devs> <meta_dev1> <dev1> .. <meta_devN> <devN>
12
13Line 1 contains the standard first three arguments to any device-mapper
14target - the start, length, and target type fields. The target type in
15this case is "raid".
16
17Line 2 contains the arguments that define the particular raid
18type/personality/level, the required arguments for that raid type, and
19any optional arguments. Possible raid types include: raid4, raid5_la,
20raid5_ls, raid5_rs, raid6_zr, raid6_nr, and raid6_nc. (raid1 is
21planned for the future.) The list of required and optional parameters
22is the same for all the current raid types. The required parameters are
23positional, while the optional parameters are given as key/value pairs.
24The possible parameters are as follows:
25 <chunk_size> Chunk size in sectors.
26 [[no]sync] Force/Prevent RAID initialization
27 [rebuild <idx>] Rebuild the drive indicated by the index
28 [daemon_sleep <ms>] Time between bitmap daemon work to clear bits
29 [min_recovery_rate <kB/sec/disk>] Throttle RAID initialization
30 [max_recovery_rate <kB/sec/disk>] Throttle RAID initialization
31 [max_write_behind <sectors>] See '-write-behind=' (man mdadm)
32 [stripe_cache <sectors>] Stripe cache size for higher RAIDs
33
34Line 3 contains the list of devices that compose the array in
35metadata/data device pairs. If the metadata is stored separately, a '-'
36is given for the metadata device position. If a drive has failed or is
37missing at creation time, a '-' can be given for both the metadata and
38data drives for a given position.
39
40NB. Currently all metadata devices must be specified as '-'.
41
42Examples:
43# RAID4 - 4 data drives, 1 parity
44# No metadata devices specified to hold superblock/bitmap info
45# Chunk size of 1MiB
46# (Lines separated for easy reading)
470 1960893648 raid \
48 raid4 1 2048 \
49 5 - 8:17 - 8:33 - 8:49 - 8:65 - 8:81
50
51# RAID4 - 4 data drives, 1 parity (no metadata devices)
52# Chunk size of 1MiB, force RAID initialization,
53# min recovery rate at 20 kiB/sec/disk
540 1960893648 raid \
55 raid4 4 2048 min_recovery_rate 20 sync\
56 5 - 8:17 - 8:33 - 8:49 - 8:65 - 8:81
57
58Performing a 'dmsetup table' should display the CTR table used to
59construct the mapping (with possible reordering of optional
60parameters).
61
62Performing a 'dmsetup status' will yield information on the state and
63health of the array. The output is as follows:
641: <s> <l> raid \
652: <raid_type> <#devices> <1 health char for each dev> <resync_ratio>
66
67Line 1 is standard DM output. Line 2 is best shown by example:
68 0 1960893648 raid raid4 5 AAAAA 2/490221568
69Here we can see the RAID type is raid4, there are 5 devices - all of
70which are 'A'live, and the array is 2/490221568 complete with recovery.