Back to home page

OSCL-LXR

 
 

    


0001 # SPDX-License-Identifier: GPL-2.0
0002 #
0003 # DRBD device driver configuration
0004 #
0005 
0006 comment "DRBD disabled because PROC_FS or INET not selected"
0007         depends on PROC_FS='n' || INET='n'
0008 
0009 config BLK_DEV_DRBD
0010         tristate "DRBD Distributed Replicated Block Device support"
0011         depends on PROC_FS && INET
0012         select LRU_CACHE
0013         select LIBCRC32C
0014         help
0015 
0016           NOTE: In order to authenticate connections you have to select
0017           CRYPTO_HMAC and a hash function as well.
0018 
0019           DRBD is a shared-nothing, synchronously replicated block device. It
0020           is designed to serve as a building block for high availability
0021           clusters and in this context, is a "drop-in" replacement for shared
0022           storage. Simplistically, you could see it as a network RAID 1.
0023 
0024           Each minor device has a role, which can be 'primary' or 'secondary'.
0025           On the node with the primary device the application is supposed to
0026           run and to access the device (/dev/drbdX). Every write is sent to
0027           the local 'lower level block device' and, across the network, to the
0028           node with the device in 'secondary' state.  The secondary device
0029           simply writes the data to its lower level block device.
0030 
0031           DRBD can also be used in dual-Primary mode (device writable on both
0032           nodes), which means it can exhibit shared disk semantics in a
0033           shared-nothing cluster.  Needless to say, on top of dual-Primary
0034           DRBD utilizing a cluster file system is necessary to maintain for
0035           cache coherency.
0036 
0037           For automatic failover you need a cluster manager (e.g. heartbeat).
0038           See also: https://www.drbd.org/, http://www.linux-ha.org
0039 
0040           If unsure, say N.
0041 
0042 config DRBD_FAULT_INJECTION
0043         bool "DRBD fault injection"
0044         depends on BLK_DEV_DRBD
0045         help
0046 
0047           Say Y here if you want to simulate IO errors, in order to test DRBD's
0048           behavior.
0049 
0050           The actual simulation of IO errors is done by writing 3 values to
0051           /sys/module/drbd/parameters/
0052 
0053           enable_faults: bitmask of...
0054           1     meta data write
0055           2               read
0056           4     resync data write
0057           8                 read
0058           16    data write
0059           32    data read
0060           64    read ahead
0061           128   kmalloc of bitmap
0062           256   allocation of peer_requests
0063           512   insert data corruption on receiving side
0064 
0065           fault_devs: bitmask of minor numbers
0066           fault_rate: frequency in percent
0067 
0068           Example: Simulate data write errors on /dev/drbd0 with a probability of 5%.
0069                 echo 16 > /sys/module/drbd/parameters/enable_faults
0070                 echo 1 > /sys/module/drbd/parameters/fault_devs
0071                 echo 5 > /sys/module/drbd/parameters/fault_rate
0072 
0073           If unsure, say N.