Linux DM Multipath
   HOME

TheInfoList



OR:

Device Mapper Multipath Input Output often shortened to DM-Multipathing and abbreviated as DM-MPIO provides input-output ( I/O) fail-over and load-balancing by using
multipath I/O In computer storage, multipath I/O is a fault-tolerance and performance-enhancement technique that defines more than one physical path between the CPU in a computer system and its mass-storage devices through the buses, controllers, switches, an ...
within
Linux Linux ( or ) is a family of open-source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991, by Linus Torvalds. Linux is typically packaged as a Linux distribution, which ...
for
block device In Unix-like operating systems, a device file or special file is an interface to a device driver that appears in a file system as if it were an ordinary file. There are also special files in DOS, OS/2, and Windows. These special files allow an ...
s. By utilizing device-mapper, the multipathd daemon provides the host-side logic to use multiple paths of a redundant
network Network, networking and networked may refer to: Science and technology * Network theory, the study of graphs as a representation of relations between discrete objects * Network science, an academic field that studies complex networks Mathematics ...
to provide continuous availability and higher-
bandwidth Bandwidth commonly refers to: * Bandwidth (signal processing) or ''analog bandwidth'', ''frequency bandwidth'', or ''radio bandwidth'', a measure of the width of a frequency range * Bandwidth (computing), the rate of data transfer, bit rate or thr ...
connectivity between the host server and the block-level device. DM-MPIO handles the rerouting of block I/O to an alternate path in the event of a path failure. DM-MPIO can also balance the I/O load across all of the available paths that are typically utilized in
Fibre Channel Fibre Channel (FC) is a high-speed data transfer protocol providing in-order, lossless delivery of raw block data. Fibre Channel is primarily used to connect computer data storage to servers in storage area networks (SAN) in commercial data cen ...
(FC) and
iSCSI Internet Small Computer Systems Interface or iSCSI ( ) is an Internet Protocol-based storage networking standard for linking data storage facilities. iSCSI provides block-level access to storage devices by carrying SCSI commands over a TCP/IP ...
SAN environments. DM-MPIO is based on the
device mapper The device mapper is a framework provided by the Linux kernel for mapping physical block devices onto higher-level ''virtual block devices''. It forms the foundation of the logical volume manager (LVM), software RAIDs and dm-crypt disk encryption, ...
, which provides the basic framework that maps one block device onto another.


Considerations

When utilizing Linux DM-MPIO in a
datacenter A data center (American English) or data centre (British English)See spelling differences. is a building, a dedicated space within a building, or a group of buildings used to house computer systems and associated components, such as telecommunic ...
that has other
operating system An operating system (OS) is system software that manages computer hardware, software resources, and provides common services for computer programs. Time-sharing operating systems schedule tasks for efficient use of the system and may also in ...
s and multipath solutions, key components of path management must be considered. *Load balancing — The workload is distributed across the available hardware components. Goal: Reduce I/O completion time, maximize throughput, and optimize resources *Path failover and recovery — Utilizes redundant I/O channels to redirect application reads and writes when one or more paths are no longer available.


History

DM-MPIO started as a patch set created by Joe Thornber, and was later maintained by Alasdair G Kergon at Red Hat. It was included in mainline Linux with kernel version 2.6.12, which was released on June 17, 2005.


Components

DM-MPIO in Linux consists of kernel components and user-space components. * Kernel – ''device-mapper'' – block subsystem that provides layering mechanism for block devices. ** dm-multipath – kernel module implementing the ''multipath'' device-mapper target. * User-space – ''multipath-tools'' – provides the tools to manage multipathed devices by instructing the device-mapper multipath module what to do. The tools consist of: ** Multipath: scans the system for multipathed devices, assembles them, updates the device-mapper's map. ** Multipathd: daemon that waits for maps events, and then executes multipath and monitors the paths. Marks a path as failed when the path becomes faulty. Depending on the failback policy, it can reactivate the path. ** Devmap-name: provides a meaningful device-name to udev for devmaps. ** Kpartx: maps linear devmaps to device partitions to make multipath maps partitionable. ** Multipath.conf: configuration file for the multipath daemon. Used to overwrite the built-in configuration table of multipathd.


Configuration file

The configuration file ''/etc/multipath.conf'' makes many of the DM-MPIO features user-configurable. The ''multipath'' command and the kernel daemon ''multipathd'' use information found in this file. The file is only consulted during the configuration of the multipath devices. Changes must be made prior to running the ''multipath'' command. Changes to the file afterwards will require ''multipath'' to be executed again. The multipath.conf has five sections: # System level defaults (''defaults''): User can override system level defaults. # Blacklisted devices (''blacklist''): User specifies the list of devices that is not to be under the control of DM-MPIO. # Blacklist exceptions (''blacklist_exceptions''): Specific devices to be treated as multipath devices even if listed in the blacklist. # Storage controller specific settings (''devices''): User specified configuration settings will be applied to devices with specified "Vendor" and "Product" information. # Device specific settings (''multipaths''): Fine tune the configuration settings for individual LUNs.


Terminology

*HBA:
Host bus adapter In computer hardware, a host controller, host adapter, or host bus adapter (HBA), connects a computer system bus, which acts as the host system, to other computer network, network and computer storage, storage devices. The terms are primarily ...
s provide the physical interface between the input/output (I/O) host bus of
Fibre Channel Fibre Channel (FC) is a high-speed data transfer protocol providing in-order, lossless delivery of raw block data. Fibre Channel is primarily used to connect computer data storage to servers in storage area networks (SAN) in commercial data cen ...
devices and the underlying Fibre Channel network. *Path: Connection from the server through the HBA to a specific LUN. *DM Path States: The device mapper's view of the path condition. Only two conditions are possible: ** Active: The last I/O operation sent through this path successfully completed. Analogous to ready path state. ** Failed: The last I/O operation sent through this path did not successfully complete. Analogous to faulty path state. *Failover: When a path is determined to be in a failed state, a path that is in ready state will be made active. *Failback: When a failed path is determined to be active again, multipathd may choose to failback to the path as determined by the failback policy. *Failback Policy: Four options as set in the multipath.conf configuration file. **Immediate: Immediately failback to the highest priority path. **Manual: The failed path is not monitored, requires user intervention to failback. **Followover(for clusters): Only perform automatic failback when the first path of a pathgroup becomes active. This keeps a node from automatically failing back when another node requested the failover. **Number of seconds: Wait for a specified number of seconds to allow the I/O to stabilize, then failback to the highest priority path. *Active/Active: In a system that has two storage controllers, each controller can process I/O. *Active/Passive: In a system that has two storage controllers, only one controller at a time is able to process I/O, the other (passive) is in a standby mode. *LUN:
SCSI Small Computer System Interface (SCSI, ) is a set of standards for physically connecting and transferring data between computers and peripheral devices. The SCSI standards define commands, protocols, electrical, optical and logical interface ...
Logical Unit Number In computer storage, a logical unit number, or LUN, is a number used to identify a logical unit, which is a device addressed by the SCSI protocol or by Storage Area Network protocols that encapsulate SCSI, such as Fibre Channel or iSCSI. A LUN m ...
*
WWID A World Wide Name (WWN) or World Wide Identifier (WWID) is a unique identifier used in storage technologies including Fibre Channel, Parallel ATA, Serial ATA, SCSI and Serial Attached SCSI (SAS). A WWN may be employed in a variety of roles, such ...
: Worldwide Identifier is an identifier for the multipath device that is guaranteed to be globally unique and unchanging.


Further reading

*Michael, T., Kabir, R., Giles, J. & Hull, J. (2006.) Configuring Linux to Enable Multipath I/O. Retrieved from http://www.dell.com/downloads/global/power/ps3q06-20060189-Michael.pdf *Goggin, E., Kergon, A., Varoqui, C., & Olien, D. (2005) Proceedings of the Linux Symposium – Linux Multipathing. Retrieved from https://web.archive.org/web/20101227213252/http://www.linuxinsight.com/files/ols2005/goggin-reprint.pdf *Red Hat Documentation. (n.d.) Red Hat Enterprise Linux 6, DM Multipath. Retrieved from https://access.redhat.com/site/documentation/en-US/Red_Hat_Enterprise_Linux/6/html-single/DM_Multipath/ *Varoqui, C. (2010.) The Linux multipath implementation. Retrieved from http://christophe.varoqui.free.fr/refbook.html


References

{{reflist


External links


multipath-tools
homepage of the upstream project used to drive the Device Mapper multipathing driver. Linux kernel features Linux Red Hat software Device mapper