blob: 7845bd6ee414715463a81d4975d493a1a7327464 [file] [log] [blame]
Philipp Reisnerb411b362009-09-25 16:07:19 -07001#
2# DRBD device driver configuration
3#
4
Lars Ellenbergd2ec1802012-12-06 11:11:04 +01005comment "DRBD disabled because PROC_FS or INET not selected"
6 depends on PROC_FS='n' || INET='n'
Philipp Reisnerb411b362009-09-25 16:07:19 -07007
8config BLK_DEV_DRBD
9 tristate "DRBD Distributed Replicated Block Device support"
Lars Ellenbergd2ec1802012-12-06 11:11:04 +010010 depends on PROC_FS && INET
Philipp Reisnerb411b362009-09-25 16:07:19 -070011 select LRU_CACHE
Lars Ellenbergd2ec1802012-12-06 11:11:04 +010012 select LIBCRC32C
Philipp Reisnerb411b362009-09-25 16:07:19 -070013 default n
14 help
15
16 NOTE: In order to authenticate connections you have to select
17 CRYPTO_HMAC and a hash function as well.
18
19 DRBD is a shared-nothing, synchronously replicated block device. It
20 is designed to serve as a building block for high availability
21 clusters and in this context, is a "drop-in" replacement for shared
22 storage. Simplistically, you could see it as a network RAID 1.
23
24 Each minor device has a role, which can be 'primary' or 'secondary'.
25 On the node with the primary device the application is supposed to
26 run and to access the device (/dev/drbdX). Every write is sent to
27 the local 'lower level block device' and, across the network, to the
28 node with the device in 'secondary' state. The secondary device
29 simply writes the data to its lower level block device.
30
31 DRBD can also be used in dual-Primary mode (device writable on both
32 nodes), which means it can exhibit shared disk semantics in a
33 shared-nothing cluster. Needless to say, on top of dual-Primary
34 DRBD utilizing a cluster file system is necessary to maintain for
35 cache coherency.
36
37 For automatic failover you need a cluster manager (e.g. heartbeat).
38 See also: http://www.drbd.org/, http://www.linux-ha.org
39
40 If unsure, say N.
41
Philipp Reisnerb411b362009-09-25 16:07:19 -070042config DRBD_FAULT_INJECTION
43 bool "DRBD fault injection"
44 depends on BLK_DEV_DRBD
45 help
46
47 Say Y here if you want to simulate IO errors, in order to test DRBD's
48 behavior.
49
50 The actual simulation of IO errors is done by writing 3 values to
51 /sys/module/drbd/parameters/
52
53 enable_faults: bitmask of...
54 1 meta data write
55 2 read
56 4 resync data write
57 8 read
58 16 data write
59 32 data read
60 64 read ahead
61 128 kmalloc of bitmap
Lars Ellenbergd2ec1802012-12-06 11:11:04 +010062 256 allocation of peer_requests
63 512 insert data corruption on receiving side
Philipp Reisnerb411b362009-09-25 16:07:19 -070064
65 fault_devs: bitmask of minor numbers
66 fault_rate: frequency in percent
67
68 Example: Simulate data write errors on /dev/drbd0 with a probability of 5%.
69 echo 16 > /sys/module/drbd/parameters/enable_faults
70 echo 1 > /sys/module/drbd/parameters/fault_devs
71 echo 5 > /sys/module/drbd/parameters/fault_rate
72
73 If unsure, say N.