Red Hat Training
A Red Hat training course is available for Red Hat Enterprise Linux
DM Multipath
Red Hat Enterprise Linux 5
DM Multipath Configuration and Administration
Ausgabe 3
Zusammenfassung
This book provides information on using the Device-Mapper Multipath feature of Red Hat Enterprise Linux 5
Einleitung
This book describes the Device Mapper Multipath (DM-Multipath) feature of Red Hat Enterprise Linux for the RHEL 5 release.
1. Zielgruppe
Dieses Buch ist für Systemadministratoren gedacht, die Systeme verwalten, auf denen das Betriebssystem Linux läuft. Kenntnisse in Red Hat Enterprise Linux sind erforderlich.
2. Verwandte Dokumentation
Werfen Sie einen Blick auf die folgenden Quellen für weitere Informationen zur Verwendung von Red Hat Enterprise Linux:
- Red Hat Enterprise Linux Installationshandbuch — Liefert Informationen bezüglicher der Installation von Red Hat Enterprise Linux 5.
- Red Hat Enterprise Linux Deployment-Handbuch — Liefert Informationen bezüglich des Einsatzes, der Konfiguration und der Administration von Red Hat Enterprise Linux 5.
Werfen Sie einen Blick auf die folgenden Quellen für weitere Informationen zur Red Hat Cluster Suite für Red Hat Enterprise Linux 5.
- Überblick über die Red Hat Cluster Suite — Liefert einen Überblick auf höchster Ebene über die Red Hat Cluster Suite.
- Konfiguration und Verwaltung eines Red Hat Cluster — Liefert Informationen zur Installation, Konfiguration und Verwaltung von Red Hat Cluster-Komponenten.
- LVM Administrator's Guide: Configuration and Administration — Provides a description of the Logical Volume Manager (LVM), including information on running LVM in a clustered environment.
- Global File System: Konfiguration und Administration — Liefert Informationen zur Installation, Konfiguration und Wartung von Red Hat GFS (Red Hat Global File System).
- Global File System 2: Configuration and Administration — Provides information about installing, configuring, and maintaining Red Hat GFS2 (Red Hat Global File System 2).
- Verwendung von GNBD mit Global File System — Liefert einen Überblick zur Vewendung von Global Network Block Device (GNBD) mit Red Hat GFS.
- Linux Virtual Server Administration — Liefert Informationen zur Konfiguration von Hochleistungssystemen und -diensten mit dem Linux Virtual Server (LVS).
- Red Hat Cluster Suite Release Notes — Liefert Informationen zum aktuellen Release der Red Hat Cluster Suite.
Dokumentation zur Red Hat Cluster Suite und andere Red Hat Dokumente stehen als HTML-, PDF-, und RPM-Versionen auf der Red Hat Enterprise Linux Dokumentations-CD und online unter http://www.redhat.com/docs/ zur Verfügung.
3. Feedback
Falls Sie Fehler entdecken (inhaltlich wie orthografisch), oder Vorschläge bzw. Anregungen zur Verbesserung dieses Dokuments machen möchten, freuen wir uns über Ihr Feedback. Bitte reichen Sie einen Fehlerbericht in Bugzilla (http://bugzilla.redhat.com/bugzilla/) für die Komponente
rh-cs
ein.
Be sure to mention the manual's identifier:
Bugzilla component: Documentation-cluster Book identifier: DM_Multipath(EN)-5 (2009-01-06T15:35)
By mentioning this manual's identifier, we know exactly which version of the guide you have.
Falls Sie Vorschläge zur Verbesserung der Dokumentation haben, versuchen Sie so spezifisch wie möglich zu sein. Falls Sie einen Fehler entdeckt haben, fügen Sie bitte die Nummer des Abschnitts, sowie einigen angrenzenden Text ein, damit wir die Stelle leicht wiederfinden können.
Kapitel 1. Device Mapper Multipathing
Device Mapper Multipathing (DM-Multipath) ermöglicht Ihnen die Konfiguration mehrerer I/O-Pfade zwischen Server-Knoten und Speicher-Arrays, zusammengefasst in einem einzelnen Gerät. Diese I/O-Pfade sind physikalische SAN-Verbindungen, die separate Kabel, Switches und Kontroller umfassen kann. Multipathing fasst die I/O-Pfade zusammen und erstellt ein neues Gerät, das aus den gesammelten Pfaden besteht.
1.1. Überblick über DM-Multipath
DM-Multipath kann dazu verwendet werden, um folgendes zur Verfügung zu stellen:
- RedundanzDM-Multipath kann Failover in einer aktiv/passiv-Konfiguration zur Verfügung stellen. In einer aktiv/passiv-Konfiguration wird nur jeweils die Hälfte der Pfade für I/O verwendet. Falls irgendein Element eines I/O-Pfads (das Kabel, der Switch, oder der Kontroller) ausfällt, wechselt DM-Multipath zu einem alternativen Pfad.
- Verbesserte LeistungDM-Multipath kann in aktiv/aktiv-Modus konfiguriert werden, in dem I/O nach Round-Robin-Art über die Pfade verteilt wird. In einigen Konfigurationen kann DM-Multipath die Auslastung auf den I/O-Pfaden ermitteln und diese dynamisch neu ausgleichen.
Abbildung 1.1, »Active/Passive Multipath Configuration with One RAID Device« shows an active/passive configuration with two I/O paths from the server to a RAID device. There are 2 HBAs on the server, 2 SAN switches, and 2 RAID controllers.
Abbildung 1.1. Active/Passive Multipath Configuration with One RAID Device
In dieser Konfiguration führt ein I/O-Pfad durch hba1, SAN1 und Kontroller1 und ein zweiter I/O-Pfad durch hba2, SAN2 und Kontroller2. Es existieren viele mögliche Ausfallpunkte in dieser Konfiguration:
- HBA-Ausfall
- FC Kabelausfall
- SAN Switch-Ausfall
- Array-Kontroller Port-Ausfall
Ist DM-Multipath konfiguriert, führt ein Ausfall jedes dieser Punkte dazu, dass DM-Multipath zu einem alternativen I/O-Pfad wechselt.
Abbildung 1.2, »Active/Passive Multipath Configuration with Two RAID Devices« shows a more complex active/passive configuration with 2 HBAs on the server, 2 SAN switches, and 2 RAID devices with 2 RAID controllers each.
Abbildung 1.2. Active/Passive Multipath Configuration with Two RAID Devices
In the example shown in Abbildung 1.2, »Active/Passive Multipath Configuration with Two RAID Devices«, there are two I/O paths to each RAID device (just as there are in the example shown in Abbildung 1.1, »Active/Passive Multipath Configuration with One RAID Device«). With DM-Multipath configured, a failure at any of the points of the I/O path to either of the RAID devices will cause DM-Multipath to switch to the alternate I/O path for that device.
Abbildung 1.3, »Active/Active Multipath Configuration with One RAID Device« shows an active/active configuration with 2 HBAs on the server, 1 SAN switch, and 2 RAID controllers. There are four I/O paths from the server to a storage device:
- hba1 an controller1
- hba1 an controller2
- hba2 an controller1
- hba2 an controller2
In dieser Konfiguration kann sich I/O auf diese vier Pfade verteilen.
Abbildung 1.3. Active/Active Multipath Configuration with One RAID Device
1.2. Speicher-Array-Unterstützung
By default, DM-Multipath includes support for the most common storage arrays that support DM-Multipath. The supported devices can be found in the
multipath.conf.defaults
file. If your storage array supports DM-Multipath and is not configured by default in this file, you may need to add them to the DM-Multipath configuration file, multipath.conf
. For information on the DM-Multipath configuration file, see Kapitel 4, Die DM-Multipath Konfigurationsdatei.
Einige Speicher-Arrays erfordern eine spezielle Handhabung von I/O-Fehlern und beim Wechseln von Pfaden. Sie benötigen separate "hardware handler" Kernel-Module.
1.3. DM-Multipath-Komponenten
Tabelle 1.1, »DM-Multipath-Komponenten«. describes the components of DM-Multipath.
Tabelle 1.1. DM-Multipath-Komponenten
Komponente | Beschreibung |
---|---|
dm-multipath kernel module | Leitet I/O um und unterstützt Ausfallsicherung (failover) für Pfade und Pfadgruppen. |
multipath command | Listet multipath-Geräte auf und konfiguriert diese. Ein Gerät, das normalerweise mit /etc/rc.sysinit gestartet wird, kann auch jedes Mal, wenn ein Blockgerät hinzugefügt wird, mit einem udev -Programm gestartet werden oder es kann vom initramfs -Dateisystem ausgeführt werden. |
multipathd daemon | Überwacht Pfade. Wenn Pfade ausfallen und wieder zurückkommen, kann er einen Wechsel zwischen Pfadgruppen einleiten. Sorgt für interaktive Änderungen an multipath-Geräten. Ein Neustart ist für jegliche Änderungen an der Datei /etc/multipath.conf erforderlich. |
kpartx command | Erstellt Device-Mapper-Geräte für die Partitionen auf einem Gerät. Es ist notwendig, dass dieser Befehl für DOS-basierte Partitionen mit DM-MP verwendet wird. kpartx wird in seinem eigenen Paket geliefert, das Paket device-mapper-multipath ist jedoch von diesem abhängig. |
1.4. Überblick über die Einrichtung von DM-Multipath
DM-Multipath umfasst einkompilierte Standardeinstellungen, die für allgemeine multipath-Konfigurationen passen. Das Einrichten von DM-multipath ist oft eine einfache Vorgehensweise.
Die grundlegende Prozedur für die Konfiguration Ihres Systems mit DM-Multipath lautet wie folgt:
- Installieren Sie das
device-mapper-multipath
-RPM. - Bearbeiten Sie die Konfigurationsdatei
multipath.conf
:- Kommentieren Sie die Standard-Blackliste aus
- Ändern Sie die bereits existierenden Standardwerte je nach Bedarf
- Speichern Sie die Konfigurationsdatei
- Starten Sie die Multipath-Daemons.
- Erstellen Sie das Multipath-Device mit dem Befehl
multipath
.
Detailed setup instructions for several example multipath configurations are provided in see Kapitel 3, DM-Multipath einrichten.
Kapitel 2. Multipath-Geräte
Ohne DM-Multipath wird jeder Pfad von einem Server-Knoten zu einem Speicher-Kontroller vom System als separates Gerät behandelt, auch wenn der I/O-Pfad denselben Server-Knoten mit demselben Speicher-Kontroller verbindet. DM-Multipath bietet eine Möglichkeit, I/O-Pfade logisch anzuordnen, indem ein einzelnes multipath-Gerät oberhalb der zugrundeliegenden Geräte erstellt wird.
2.1. Multipath-Geräte-Identifizierer
Jedes multipath-Gerät besitzt einen World Wide Identifier (WWID), der garantiert global einzigartig und konstant ist. Standardmäßig wird der Name eines multipath-Geräts auf dessen WWID gesetzt. Alternativ könne Sie die Option
user_friendly_names
in der multipath-Konfigurationsdatei setzen, welche einen Alias zu einem eindeutigen Knotennamen der Art mpath
n
setzt.
For example, a node with two HBAs attached to a storage controller with two ports via a single unzoned FC switch sees four devices:
/dev/sda
, /dev/sdb
, dev/sdc
, and /dev/sdd
. DM-Multipath creates a single device with a unique WWID that reroutes I/O to those four underlying devices according to the multipath configuration. When the user_friendly_names
configuration option is set to yes
, the name of the multipath device is set to mpath
n
.
When new devices are brought under the control of DM-Multipath, the new devices may be seen in three different places under the
/dev
directory: /dev/mapper/mpath
n
, /dev/mpath/mpath
n
, and /dev/dm-
n
.
- The devices in
/dev/mapper
are created early in the boot process. Use these devices to access the multipathed devices, for example when creating logical volumes. - The devices in
/dev/mpath
are provided as a convenience so that all multipathed devices can be seen in one directory. These devices are created by theudev
device manager and may not be available on startup when the system needs to access them. Do not use these devices for creating logical volumes or filesystems. - Any devices of the form
/dev/dm-
n
are for internal use only and should never be used.
For information on the multipath configuration defaults, including the
user_friendly_names
configuration option, see Abschnitt 4.3, »Standardeinstellungen der Konfigurationsdatei«.
You can also set the name of a multipath device to a name of your choosing by using the
alias
option in the multipaths
section of the multipath configuration file. For information on the multipaths
section of the multipath configuration file, see see Abschnitt 4.4, »Multipaths Attribute zur Gerätekonfiguration«.
2.2. Einheitliche Multipath-Gerätenamen in einem Cluster
Wenn die Konfigurationsoption
user_friendly_names
auf yes
gesetzt ist, ist der Name des multipath-Geräts eindeutig für einen Knoten. Es ist jedoch nicht gewährleistet, dass er auf allen Knoten, die das multipath-Gerät verwenden, derselbe ist. Dies sollte bei der Verwendung von LVM zur Erstellung von logischen Geräten vom multipath-Gerät zu keinen Schwierigkeiten führen. Falls es jedoch erforderlich ist, dass Ihr multipath-Gerät auf jedem Cluster-Knoten einheitlich ist, können Sie eine der folgenden Vorgehensweisen durchführen:
- Use the
alias
option in themultipaths
section of the multipath configuration file to set the name of the multipath device. Thealias
for the multipath device is consistent across all the nodes in a cluster. For information on themultipaths
section of the multipath configuration file, see see Abschnitt 4.4, »Multipaths Attribute zur Gerätekonfiguration«. - Falls Sie möchten, dass die vom System definierten benutzerfreundlichen Namen einheitlich auf allen Knoten im Cluster verteilt sind, richten Sie alle multipath-Geräte auf einer Maschine ein. Kopieren Sie dann die Datei
/var/lib/multipath/bindings
von dieser Maschine auf alle anderen Maschinen im Cluster.
2.3. Multipath-Geräte-Attribute
In addition to the
user_friendly_names
and alias
options, a multipath device has numerous attributes. You can modify these attributes for a specific multipath device by creating an entry for that device in the multipaths
section of the multipath configuration file. For information on the multipaths
section of the multipath configuration file, see see Abschnitt 4.4, »Multipaths Attribute zur Gerätekonfiguration«.
2.4. Multipath-Geräte in Logischen Datenträgern
After creating multipath devices, you can use the multipath device names just as you would use a physical device name when creating an LVM physical volume. For example, if
/dev/mapper/mpath0
is the name of a multipath device, the following command will mark /dev/mapper/mpath0
as a physical volume.
pvcreate /dev/mapper/mpath0
Sie können die entstehenden physikalischen LVM-Geräte beim Erstellen einer LVM-Datenträgergruppe genauso verwenden, wie Sie jedes andere physikalische LVM-Gerät verwenden würden.
Wenn Sie einen logischen LVM-Datenträger erstellen, der aktiv/passiv multipath-Arrays als zugrundeliegende physikalische Geräte verwendet, sollten Sie Filter in
lvm.conf
integrieren, um die Platten auszuschliessen, die den multipath-Geräten zugrundeliegen. Dies liegt daran, dass falls das Array beim Erhalt von I/O den aktiven Pfad automatisch in den passiven Pfad ändert, multipath jedes Mal mit einem Failover und Failback einspringt, wenn LVM den passiven Pfad abscannt, wenn diese Geräte nicht gefiltert werden. Für aktiv/passiv-Arrays, die einen Befehl erfordern, um den passiven Pfad auf aktiv zu setzen, gibt LVM eine Warnmeldung aus, wenn dies auftritt.
Um alle SCSI-Geräte in der multipath-Konfigurationsdatei (
lvm.conf
) zu filtern, binden Sie den folgenden Filter in den Abschnitt devices
der Datei ein.
filter = [ "r/disk/", "r/sd.*/", "a/.*/" ]
Kapitel 3. DM-Multipath einrichten
Dieses Kapitel liefert eine Schritt-für-Schritt Vorgehensweise als Beispiel zur Konfiguration von DM-Multipath. Es umfasst die folgenden Arbeitsschritte:
- Grundlegende DM-Multipath Einrichtung
- Lokale Platten ignorieren
- Mehr Geräte zu der Konfigurationsdatei hinzufügen
3.1. DM-Multipath einrichten
Stellen Sie vor der Einrichtung von DM-Multipath auf Ihrem System sicher, dass Ihr System aktualisiert wurde und das Paket
device-mapper-multipath
beinhaltet.
Verwenden Sie die folgende Vorgehensweise, um DM-Multipath für eine grundlegende Failover-Konfiguration einzurichten.
- Bearbeiten Sie die Datei
/etc/multipath.conf
, indem Sie die folgenden Zeilen am oberen Ende der Datei auskommentieren. Dieser Abschnitt der Konfigurationsdatei setzt in seinem ursprünglichen Status alle Geräte auf die Blacklist. Sie müssen ihn auskommentieren, um Multipathing zu aktivieren.blacklist { devnode "*" }
Nach dem Auskommentieren dieser Zeilen sollte dieser Abschnitt wie folgt erscheinen.# blacklist { # devnode "*" # }
- Die Standardeinstellungen für DM-Multipath sind im System einkompiliert und müssen nicht explizit in der Datei
/etc/multipath.conf
gesetzt werden.The default value ofpath_grouping_policy
is set tofailover
, so in this example you do not need to change the default value. For information on changing the values in the configuration file to something other than the defaults, see Kapitel 4, Die DM-Multipath Konfigurationsdatei.The initial defaults section of the configuration file configures your system that the names of the multipath devices are of the formmpath
n; without this setting, the names of the multipath devices would be aliased to the WWID of the device. - Speichern Sie die Konfigurationsdatei und beenden Sie den Editor.
- Führen Sie die folgenden Befehle aus:
modprobe dm-multipath service multipathd start multipath -v2
Der Befehlmultipath -v2
gibt multipathed-Pfade aus, die zeigen, welche Geräte multipath nutzen. Falls der Befehl nichts ausgibt, stellen Sie sicher, dass alle SAN-Verbindungen ordnungsgemäß eingerichtet sind und das System multipath nutzt.For further information on themultipath
command output, see Abschnitt 5.4, »Multipath Command Output«. - Führen Sie den folgenden Befehl aus, um sicherzustellen, dass der multipath-Daemon zum Zeitpunkt des Bootens startet:
chkconfig multipathd on
Since the value of
user_friendly_name
is set to yes
in the configuration file the multipath devices will be created as /dev/mapper/mpath
n. For information on setting the name of the device to an alias of your choosing, see Kapitel 4, Die DM-Multipath Konfigurationsdatei.
3.2. Lokale Platten beim Generieren von multipath-Geräten ignorieren
Einige Maschinen besitzen lokale SCSI-Karten für ihre internen Platten. DM-Multipath wird für diese Geräte nicht empfohlen. Die folgende Vorgehensweise zeigt, wie die multipath-Konfigurationsdatei zu modifizieren ist, um lokale Platten bei der Konfiguration von multipath zu ignorieren.
- Ermitteln Sie, welche Platten die internen Platten sind und markieren Sie diese als diejenigen, die zur Blacklist hinzugefügt werden sollen.In diesem Beispiel ist
/dev/sda
die interne Platte. Beachten Sie, dass wie ursprünglich in der standardmäßigen multipath-Konfigurationsdatei konfiguriert, das Ausführen vonmultipath -v2
die lokale Platte/dev/sda
in der multipath map anzeigt.For further information on themultipath
command output, see Abschnitt 5.4, »Multipath Command Output«.[root@rh4cluster1 ~]#
multipath -v2
create: SIBM-ESXSST336732LC____F3ET0EP0Q000072428BX1 [size=33 GB][features="0"][hwhandler="0"] \_ round-robin 0 \_ 0:0:0:0 sda 8:0 [--------- device-mapper ioctl cmd 9 failed: Invalid argument device-mapper ioctl cmd 14 failed: No such device or address create: 3600a0b80001327d80000006d43621677 [size=12 GB][features="0"][hwhandler="0"] \_ round-robin 0 \_ 2:0:0:0 sdb 8:16 \_ 3:0:0:0 sdf 8:80 create: 3600a0b80001327510000009a436215ec [size=12 GB][features="0"][hwhandler="0"] \_ round-robin 0 \_ 2:0:0:1 sdc 8:32 \_ 3:0:0:1 sdg 8:96 create: 3600a0b80001327d800000070436216b3 [size=12 GB][features="0"][hwhandler="0"] \_ round-robin 0 \_ 2:0:0:2 sdd 8:48 \_ 3:0:0:2 sdh 8:112 create: 3600a0b80001327510000009b4362163e [size=12 GB][features="0"][hwhandler="0"] \_ round-robin 0 \_ 2:0:0:3 sde 8:64 \_ 3:0:0:3 sdi 8:128 - Um zu verhindern, dass der Device-Mapper
/dev/sda
in seine multipath maps einbindet, bearbeiten Sie den Blacklist-Abschnitt der Datei/etc/multipath.conf
, um dieses Gerät einzubinden. Auch wenn Sie dassda
-Gerät mit Hilfe des Typsdevnode
auf die Blacklist setzen könnten, wäre dies keine sichere Vorgehensweise, da nicht garantiert werden kann, dass/dev/sda
nach einem Neustart dasselbe Gerät ist. Um einzelne Geräte auf die Blacklist zu setzen, können Sie den WWID des Geräts verwenden.Note that in the output to themultipath -v2
command, the WWID of the/dev/sda
device is SIBM-ESXSST336732LC____F3ET0EP0Q000072428BX1. To blacklist this device, include the following in the/etc/multipath.conf
file.blacklist { wwid SIBM-ESXSST336732LC____F3ET0EP0Q000072428BX1 }
- After you have updated the
/etc/multipath.conf
file, you must manually tell themultipathd
daemon to reload the file. The following command reloads the updated/etc/multipath.conf
file.service multipathd reload
- Führen Sie die folgenden Befehle aus:
multipath -F multipath -v2
Die lokale Platte(n) sollten nicht mehr länger in den multipath maps aufgelistet werden, wie im folgenden Beispiel gezeigt.[root@rh4cluster1 ~]#
multipath -F
[root@rh4cluster1 ~]#multipath -v2
create: 3600a0b80001327d80000006d43621677 [size=12 GB][features="0"][hwhandler="0"] \_ round-robin 0 \_ 2:0:0:0 sdb 8:16 \_ 3:0:0:0 sdf 8:80 create: 3600a0b80001327510000009a436215ec [size=12 GB][features="0"][hwhandler="0"] \_ round-robin 0 \_ 2:0:0:1 sdc 8:32 \_ 3:0:0:1 sdg 8:96 create: 3600a0b80001327d800000070436216b3 [size=12 GB][features="0"][hwhandler="0"] \_ round-robin 0 \_ 2:0:0:2 sdd 8:48 \_ 3:0:0:2 sdh 8:112 create: 3600a0b80001327510000009b4362163e [size=12 GB][features="0"][hwhandler="0"] \_ round-robin 0 \_ 2:0:0:3 sde 8:64 \_ 3:0:0:3 sdi 8:128
3.3. Hinzufügen von Geräten zur Multipathing-Datenbank
Standardmäßig beinhaltet DM-Multipath Support für die gebräuchlichsten Speicher-Arrays, die DM-Multipath unterstützen. Die standardmäßigen Konfigurationswerte, inklusive unterstützter Geräte, sind in der Datei
multipath.conf.defaults
zu finden.
Falls Sie ein Speichergerät hinzufügen müssen, das nicht standardmäßig als ein bekanntes multipath-Gerät unterstützt wird, bearbeiten Sie die Datei
/etc/multipath.conf
und fügen die entsprechenden Geräte-Informationen ein.
Um beispielsweise Informationen über die HP Open-V Serie einzufügen, sieht der Eintrag folgendermaßen aus:
devices { device { vendor "HP" product "OPEN-V." getuid_callout "/sbin/scsi_id -g -u -p0x80 -s /block/%n" } }
For more information on the
devices
section of the configuration file, see Abschnitt 4.5, »Konfigurationsdatei-Geräte«.
Kapitel 4. Die DM-Multipath Konfigurationsdatei
Standardmäßig bietet DM-Multipath Konfigurationswerte für die gebräuchlichsten Anwendungen von multipathing. Zusätzlich beinhaltet DM-Multipath Support für die gebräuchlichsten Speicher-Arrays, die DM-Multipath unterstützen. Die standardmäßigen Konfigurationswerte und die unterstützten Geräte sind in der Datei
/usr/share/doc/device-mapper-multipath-0.4.7/multipath.conf.defaults
zu finden.
Sie können die standardmäßigen Konfigurationswerte für DM-Multipath außer Kraft setzen, indem Sie die Konfigurationsdatei
/etc/multipath.conf
bearbeiten. Falls nötig, können Sie auch ein Speicher-Array zu der Konfigurationsdatei hinzufügen, das nicht standardmäßig unterstützt wird. Dieses Kapitel liefert Informationen zur Analyse und Modifikation der Datei multipath.conf
. Es umfasst Abschnitte zu den folgenden Themen:
- Überblick über die Konfigurationsdatei
- Konfigurationsdatei-Blacklist
- Konfigurationsdatei-Standardwerte
- Konfigurationsdatei multipaths
- Konfigurationsdatei-Geräte
Sie brauchen in der multipath-Konfigurationsdatei nur die Abschnitte angeben, die Sie für Ihre Konfiguration benötigen, oder bei denen Sie die in der Datei
multipath.conf.defaults
angegebenen Standardwerte ändern möchten. Falls einige Abschnitte dieser Datei für Ihre Umgebung nicht relevant sind, oder Sie für diese die Standardwerte nicht außer Kraft setzen müssen, können Sie sie auskommentiert lassen, wie in der ursprünglichen Datei.
In der Konfigurationsdatei darf die Beschreibungssyntax für reguläre Ausdrücke verwendet werden.
Eine Version der Konfigurationsdatei mit Anmerkungen ist unter
/usr/share/doc/device-mapper-multipathd-0.4.7/multipath.conf.annotated
zu finden.
4.1. Überblick über die Konfigurationsdatei
Die multipath-Konfigurationsdatei wird in die folgenden Abschnitte unterteilt:
- blacklist
- Auflistung von speziellen Geräten, die nicht für multipath berücksichtigt werden. Standardmäßig werden alle Geräte auf eine Blacklist gesetzt. Üblicherweise ist der standardmäßige Blacklist-Abschnitt auskommentiert.
- blacklist_exceptions
- Auflistung von multipath-Kandidaten, die ansonsten aufgrund der Parameter des Blacklist-Abschnitts auf die Blacklist gesetzt würden.
- Standardeinstellungen
- Allgemeine Standardeinstellungen für DM-Multipath.
- multipaths
- Einstellungen für die Charakteristiken von individuellen multipath-Geräten. Diese Werte überschreiben das, was in den Abschnitten
defaults
unddevices
der Konfigurationsdatei definiert ist. - devices
- Einstellungen für individuelle Speicher-Kontroller. Diese Werte überschreiben das, was im Abschnitt
defaults
der Konfigurationsdatei definiert ist. Falls Sie ein Speicher-Array verwenden, das nicht standardmäßig unterstützt wird, müssen Sie ggf. einen Unterabschnittdevices
für Ihr Array erstellen.
Wenn das System die Attribute eines multipath-Geräts ermittelt, überprüft es zunächst die multipath-Einstellungen, dann die Einstellungen pro Gerät und anschließend die standardmäßigen Systemeinstellungen von multipath.
4.2. Konfigurationsdatei-Blacklist
Der Abschnitt
blacklist
der multipath-Konfigurationsdatei definiert die Geräte, die bei der Konfiguration der multipath-Geräte durch das System nicht verwendet werden. Geräte auf einer Blacklist werden nicht in einem multipath-Gerät gruppiert.
Standardmäßig werden alle Geräte auf eine Blacklist gesetzt, da die folgenden Zeilen in der ursprünglichen Konfigurationsdatei erscheinen.
blacklist { devnode "*" }
To enable multipathing on all of the devices that are supported by default, comment out those lines, as described in Abschnitt 3.1, »DM-Multipath einrichten«.
Nachdem Sie die allgemeine Blacklist auskommentiert haben, können Sie allgemeine Gerätetypen und individuelle Geräte bestimmen, die auf die Blacklist gesetzt werden sollen. Sie können Geräte nach den folgenden Kriterien auf die Blacklist setzen:
- By WWID, as described in Abschnitt 4.2.1, »Blacklisting durch die WWID«
- By device name, as described in Abschnitt 4.2.2, »Blacklisting durch den Gerätenamen«
- By device type, as described in Abschnitt 4.2.3, »Blacklisting durch den Gerätetyp«
By default, a variety of device types are blacklisted, even after you comment out the initial blacklist section of the configuration file. For information, see Abschnitt 4.2.2, »Blacklisting durch den Gerätenamen«.
4.2.1. Blacklisting durch die WWID
Sie können individuelle Geräte durch ihre World-Wide IDentification mit einem
wwid
-Eintrag im Abschnitt blacklist
der Konfigurationsdatei auf die Blacklist setzen.
Das folgende Beispiel zeigt die Zeilen in der Konfigurationsdatei, die ein Gerät mit einer WWID von 26353900f02796769 auf die Blacklist setzen würde.
blacklist { wwid 26353900f02796769 }
4.2.2. Blacklisting durch den Gerätenamen
Sie können Gerätetypen durch Gerätenamen auf die Blacklist setzen, so dass sie nicht durch die Angabe eines
devnode
-Eintrags im Abschnitt blacklist
der Konfigurationsdatei in einem multipath-Gerät gruppiert werden.
Das folgende Beispiel zeigt die Zeilen in der Konfigurationsdatei, die alle SCSI-Geräte auf die Blacklist setzen würde, da alle sd*-Geräte auf die Blacklist gesetzt werden.
blacklist { devnode "^sd[a-z]" }
Sie können einen
devnode
-Eintrag im Abschnitt blacklist
der Konfigurationsdatei verwenden, um individuelle Geräte auf die Blacklist zu setzen, anstatt alle Geräte eines speziellen Typs. Dies wird jedoch nicht empfohlen. Solange es nicht statisch durch udev
-Regeln zugewiesen wird, gibt es keine Garantie, dass ein spezielles Gerät bei einem Neustart denselben Namen erhält. So kann sich ein Gerätenamen beispielsweise bei einem Neustart von /dev/sda
in /dev/sdb
ändern.
By default, the following
devnode
entries are compiled in the default blacklist; the devices that these entires blacklist do not generally support DM-Multipath. To enable multipathing on any of these devices, you would need to specify them in the blacklist_exceptions
section of the configuration file, as described in Abschnitt 4.2.4, »Blacklist-Ausnahmen«.
blacklist { devnode "^(ram|raw|loop|fd|md|dm-|sr|scd|st)[0-9]*" devnode "^hd[a-z]" }
4.2.3. Blacklisting durch den Gerätetyp
Sie können spezielle Gerätetypen im Abschnitt
blacklist
der Konfigurationsdatei durch einen Abschnitt device
definieren. Im folgenden Beispiel werden alle IBM DS4200 und alle HP-Geräte auf die Blacklist gesetzt.
blacklist { device { vendor "IBM" product "3S42" #DS4200 Product 10 } device { vendor "HP" product "*" } }
4.2.4. Blacklist-Ausnahmen
You can use the
blacklist_exceptions
section of the configuration file to enable multipathing on devices that have been blacklisted by default. For example, by default, devices with vendor = "IBM" and product = "S/390.*" are blacklisted since usually DASD devices are used for local storage. If you do need to enable multipathing on these devices, uncomment the following lines in the configuration file:
blacklist_exceptions { device { vendor "IBM" product "S/390.*" } }
Wenn Sie Geräte im Abschnitt
blacklist_exceptions
der Konfigurationsdatei angeben, müssen Sie die Ausnahmen ebenso bestimmen, wie sie in der Blacklist angegeben wurden. So wird eine WWID-Ausnahme beispielsweise nicht auf Geräte angewendet, die durch einen devnode
-Eintrag bestimmt wurden, auch wenn das Gerät auf der Blacklist mit dem WWID verknüpft ist. In gleicher Weise treffen devnode
-Ausnahmen nur auf devnode
-Einträge zu und device
-Ausnahmen nur auf Geräte-Einträge.
4.3. Standardeinstellungen der Konfigurationsdatei
Die Konfigurationsdatei
/etc/multipath.conf
beinhaltet einen Abschnitt defaults
, der den Parameter user_friendly_names
auf yes
setzt, wie nachfolgend aufgeführt.
defaults { user_friendly_names yes }
Dies überschreibt den standardmäßigen Wert des Parameters
user_friendly_names
.
Die Konfigurationsdatei beinhaltet eine Vorlage von Konfigurations- Standardwerten. Dieser Abschnitt ist auskommentiert, wie nachfolgend aufgeführt.
#defaults { # udev_dir /dev # polling_interval 10 # selector "round-robin 0" # path_grouping_policy multibus # getuid_callout "/sbin/scsi_id -g -u -s /block/%n" # prio_callout /bin/true # path_checker readsector0 # rr_min_io 100 # max_fds 8192 # rr_weight priorities # failback immediate # no_path_retry fail # user_friendly_names yes #}
Um den Standardwert für irgendeinen der Konfigurations-Parameter zu überschreiben, können Sie die relevanten Zeilen aus dieser Vorlage in den Abschnitt
defaults
kopieren und die Markierung als Kommentar entfernen. Um beispielsweise den Parameter path_grouping_policy
zu überschreiben, so dass er zu multibus
anstelle des Standardwerts von failover
wird, kopieren Sie die entsprechende Zeile aus der Vorlage in den ursprünglichen Abschnitt defaults
der Konfigurationsdatei und entfernen die Markierung als Kommentar wie folgt.
defaults { user_friendly_names yes path_grouping_policy multibus }
Tabelle 4.1, »Standardeinstellungen für die Multipath-Konfiguration« describes the attributes that are set in the
defaults
section of the multipath.conf
configuration file. These values are used by DM-Multipath unless they are overwritten by the attributes specified in the devices
and multipaths
sections of the multipath.conf
file.
Tabelle 4.1. Standardeinstellungen für die Multipath-Konfiguration
Attribut | Beschreibung | |||||||
---|---|---|---|---|---|---|---|---|
udev_dir | Definiert das Verzeichnis, in dem udev -Geräteknoten erstellt werden. Der Standardwert ist /udev . | |||||||
polling_interval | Gibt das Intervall zwischen zwei Pfad-Checks in Sekunden an. Der Standardwert lautet 5. | |||||||
selector | Gibt den Standard-Algorithmus an, der zur Bestimmung verwendet werden soll, welcher Pfad für die nächste I/O-Operation benutzt werden soll. Der Standardwert lautet round-robin 0 . | |||||||
path_grouping_policy |
| |||||||
getuid_callout |
| |||||||
prio_callout | Specifies the the default program and arguments to call out to obtain a path priority value. For example, the ALUA bits in SPC-3 provide an exploitable prio value for example. "none" is a valid value. The default value is no callout, indicating all paths are equal | |||||||
path_checker | Gibt die Standardmethode an, die zur Bestimmung des Status des Pfads verwendet wird. Mögliche Werte umfassen: readsector0 , tur , emc_clariion , hp_sw und directio . Der Standardwert lautet readsector0 . | |||||||
rr_min_io | Definiert die Anzahl der I/O-Anfragen, die an einen Pfad weitergeleitet werden sollen, bevor zum nächsten Pfad in der aktuellen Pfadgruppe gewechselt wird. Der Standardwert lautet 1000. | |||||||
max_fds | (RHEL 5.2 and later) Sets the maximum number of open file descriptors for the multipathd process. In RHEL 5.3, this option allows a value of max , which sets the number of open file descriptors to the system maximum. | |||||||
rr_weight |
| |||||||
failback |
| |||||||
no_path_retry |
| |||||||
flush_on_last_del | (RHEL 5.3 and later) If set to yes , the multipathd daemon will disable queueing when the last path to a device has been deleted. The default value is no . | |||||||
queue_without_daemon | (RHEL 5.3 and later) If set to no , the multipathd daemon will disable queueing for all devices when it is shut down. The default value is yes . | |||||||
user_friendly_names | If set to yes , specifies that the system should using the bindings file to assign a persistent and unique alias to the multipath, in the form of mpath n . The default location of the bindings file is /var/lib/multipath/bindings , but this can be changed with the bindings_file option. If set to no , specifies that the system should use use the WWID as the alias for the multipath. In either case, what is specified here will be overriden by any device-specific aliases you specify in the multipaths section of the configuration file. The default value is no . | |||||||
bindings_file | (RHEL 5.2 and later) The location of the bindings file that is used with the user_friend_names option. The default value is /var/lib/multipath/bindings . | |||||||
mode | (RHEL 5.3 and later) The mode to use for the multipath device nodes, in octal. The default value is determined by the process. | |||||||
uid | (RHEL 5.3 and later) The user ID to use for the multipath device nodes. You must use the numeric user ID. The default value is determined by the process. | |||||||
gid | (RHEL 5.3 and later) The group ID to use for the multipath device nodes. You must use the numeric group ID. The default value is determined by the process. |
4.4. Multipaths Attribute zur Gerätekonfiguration
Tabelle 4.2, »Multipath-Attribute« shows the attributes that you can set in the
multipaths
section of the multipath.conf
configuration file for each specific multipath device. These attributes apply only to the one specified multipath. These defaults are used by DM-Multipath and override attributes set in the defaults
and devices
sections of the multipath.conf
file.
Tabelle 4.2. Multipath-Attribute
Attribut | Beschreibung | ||||||
---|---|---|---|---|---|---|---|
wwid | Gibt die WWID des multipath-Geräts an, auf das die multipath -Attribute zutreffen. | ||||||
alias | Gibt den symbolischen Namen für das multipath-Gerät an, auf das die multipath -Attribute zutreffen. | ||||||
path_grouping_policy |
| ||||||
path_selector | Gibt den Standard-Algorithmus an, der zur Bestimmung verwendet werden soll, welcher Pfad für die nächste I/O-Operation verwendet werden soll. | ||||||
failback |
| ||||||
rr_weight |
| ||||||
no_path_retry |
| ||||||
flush_on_last_del | (RHEL 5.3 and later) If set to yes , the multipathd daemon will disable queueing when the last path to a device has been deleted. The default value is no . | ||||||
rr_min_io | Gibt die Zahl der I/O-Anfragen an, die zu einem Pfad weitergeleitet werden sollen, bevor zum nächsten Pfad in der aktuellen Pfadgruppe gewechselt wird. | ||||||
mode | (RHEL 5.3 and later) The mode to use for the multipath device nodes, in octal. The default value is determined by the process. | ||||||
uid | (RHEL 5.3 and later) The user ID to use for the multipath device nodes. You must use the numeric user ID. The default value is determined by the process. | ||||||
gid | (RHEL 5.3 and later) The group ID to use for the multipath device nodes. You must use the numeric group ID. The default value is determined by the process. |
The following example shows multipath attributes specified in the configuration file for two specific multipath devices. The first device has a WWID of
3600508b4000156d70001200000b0000
and a symbolic name of yellow
.
Das zweite multipath-Gerät in dem Beispiel besitzt eine WWID mit dem Wert
1DEC_____321816758474
und einen symbolischen Namen red
. In diesem Beispiel werden die rr_weight
-Attribute auf priorities
gesetzt.
multipaths { multipath { wwid 3600508b4000156d70001200000b0000 alias yellow path_grouping_policy multibus path_checker readsector0 path_selector "round-robin 0" failback manual rr_weight priorities no_path_retry 5 } multipath { wwid 1DEC_____321816758474 alias red rr_weight priorities } }
4.5. Konfigurationsdatei-Geräte
Tabelle 4.3, »Geräte-Attribute« shows the attributes that you can set for each individual storage device in the
devices
section of the multipath.conf
configuration file. These attributes are used by DM-Multipath unless they are overwritten by the attributes specified in the multipaths
section of the multipath.conf
file for paths that contain the device. These attributes override the attributes set in the defaults
section of the multipath.conf
file.
Viele Geräte, die multipathing unterstützen, sind standardmäßig in einer multipath-Konfiguration enthalten. Die Werte für die Geräte, die standardmäßig unterstützt werden, sind in der Datei
multipath.conf.defaults
aufgelistet. Sie müssen die Werte für diese Geräte möglicherweise nicht modifizieren. Falls doch, können Sie die Standardwerte überschreiben, indem Sie einen Eintrag für das Gerät in der Konfigurationsdatei einfügen, der diese Werte überschreibt. Sie können die Standardwerte der Gerätekonfiguration aus der Datei multipath.conf.defaults
für das jeweilige Gerät kopieren und die Werte außer Kraft setzen, die Sie ändern möchten.
To add a device to this section of the configuration file that is not configured automatically by default, you need to set the
vendor
and product
parameters. You can find these values by looking at /sys/block/device_name/device/vendor
and /sys/block/device_name/device/model
where device_name is the device to be multipathed, as in the following example:
[root@cypher-06 ~]#cat /sys/block/sda/device/vendor
WINSYS [root@cypher-06 ~]#cat /sys/block/sda/device/model
SF2372
The additional parameters to specify depend on your specific device. If the device is active/active, you will usually not need to set additional parameters. You may want to set
path_grouping_policy
to multibus
. Other parameters you may need to set are no_path_retry
and rr_min_io
, as described in Tabelle 4.3, »Geräte-Attribute«.
Falls das Gerät aktiv/passiv ist, es jedoch Pfade automatisch mit I/O zum passiven Pfad wechselt, müssen Sie die Checker-Funktion auf eine Variante setzen, die I/O nicht zum Pfad schickt, um es auf Funktionstüchtigkeit zu testen (ansonsten befindet sich das Gerät kontinuierlich im Failover). Dies hat fast unweigerlich zur Folge, dass Sie den
path_checker
auf tur
setzen müssen. Dies funktioniert für alle SCSI-Geräte. die den Befehl "Test Unit Ready" unterstützen, was bei den meisten der Fall ist.
If the device needs a special command to switch paths, then configuring this device for multipath requires a hardware handler kernel module. The current hardware handlers are
emc
and "rdac
. If these are not sufficient for your device, you may not be able to configure the device for multipath.
Tabelle 4.3. Geräte-Attribute
Attribut | Beschreibung | ||||||
---|---|---|---|---|---|---|---|
vendor | Gibt den Herstellernamen des Speichergeräts an, auf das die device -Attribute zutreffen, z.B. COMPAQ . | ||||||
product | Gibt den Produktnamen des Speichergeräts an, auf das die device -Attribute zutreffen, z.B. HSV110 (C)COMPAQ . | ||||||
path_grouping_policy |
| ||||||
getuid_callout | Specifies the default program and arguments to call out to obtain a unique path identifier. An absolute path is required. | ||||||
prio_callout | Specifies the the default program and arguments to call out to obtain a path weight. Weights are summed for each path group to determine the next path group to use in case of failue. "none" is a valid value. | ||||||
path_checker | Definiert die Standardmethode, die zur Ermittlung des Status der Pfade verwendet werden soll. Mögliche Werte umfassen readsector0 und tur , emc_clariion , hp_sw und directio . | ||||||
path_selector | Gibt den Standard-Algorithmus an, der zur Bestimmung verwendet werden soll, welcher Pfad für die nächste I/O-Operation verwendet werden soll. | ||||||
features | The extra features of multipath devices. The only existing feature is queue_if_no_path , which is the same as setting no_path_retry to queue . For information on issues that may arise when using this feature, see Abschnitt 5.3, »Issues with queue_if_no_path feature«. | ||||||
hardware_handler | Definiert ein Modul, das verwendet wird, um beim Wechsel von Pfadgruppen oder der Handhabung von I/O-Fehlern hardwarespezifische Aktionen durchzuführen. Mögliche Werte beinhalten 0 , 1 emc und 1 rdac . Der Standardwert lautet 0 . | ||||||
rr_weight |
| ||||||
no_path_retry |
| ||||||
failback |
| ||||||
rr_min_io | Definiert die Anzahl der I/O-Anfragen, die an einen Pfad weitergeleitet werden sollen, bevor zum nächsten Pfad in der aktuellen Pfadgruppe gewechselt wird. Der Standardwert lautet 1000. | ||||||
flush_on_last_del | (RHEL 5.3 and later) If set to yes , the multipathd daemon will disable queueing when the last path to a device has been deleted. The default value is no . | ||||||
product_blacklist | Definiert einen regulären Ausdruck, um Geräte anhand des Produkts auf die Blacklist zu setzen. |
Das folgende Beispiel zeigt einen
device
-Eintrag in der Konfigurationsdatei von multipath.
# } # device { # vendor "COMPAQ " # product "MSA1000 " # path_grouping_policy multibus # path_checker tur # rr_weight priorities # } #}
Kapitel 5. DM-Multipath Administration und Problembehandlung
Dieses Kapitel liefert Informationen zur Administration von DM-Multipath auf einem laufenden System. Es umfasst Abschnitte zu den folgenden Themen:
- The Multipath Daemon
- Issues with Large Number of LUNs
- Issues with queue_if_no_path feature
- Multipath Command Output
- Multipath Queries with multipath Command
- Multipath Command Options
- Multipath Abfragen (Queries) mit dem Befehl 'dmsetup'
- Troubleshooting with the multipathd Interactive Console
5.1. The Multipath Daemon
If you find you have trouble implementing a multipath configuration, you should ensure that the multipath daemon is running, as described in Kapitel 3, DM-Multipath einrichten. The
multipathd
daemon must be running in order to use multipathed devices.
5.2. Issues with Large Number of LUNs
When a large number of LUNs are added to a node, using multipathed devices can significantly increase the time it takes for the
udev
device manager to create device nodes for them. If you experience this problem, you can correct it by deleting the following line in /etc/udev/rules.d/40-multipath.rules
:
KERNEL!="dm-[0-9]*", ACTION=="add", PROGRAM=="/bin/bash -c '/sbin/lsmod | /bin/grep ^dm_multipath'", RUN+="/sbin/multipath -v0 %M:%m"
This line causes the
udev
device manager to run multipath
every time a block device is added to the node. Even with this line removed, the multipathd
daemon will still automatically create multipathed devices, and multipath
will still be called during the boot process for nodes with multipathed root file systems. The only change is that multipathed devices will not be automatically created when the multipathd
daemon is not running, which should not be a problem for the vast majority of multipath users.
5.3. Issues with queue_if_no_path feature
If
features "1 queue_if_no_path"
is specified in the /etc/multipath.conf
file, then any process that issues I/O will hang until one or more paths are restored. To avoid this, set the no_path_retry
N
parameter in the /etc/multipath.conf
file (where N
is the number of times the system should retry a path). When you do, remove the features "1 queue_if_no_path"
option from the /etc/multipath.conf
as well.
If you need to use the
features "1 queue_if_no_path"
option and you experience the issue noted here, use the dmsetup
command to edit the policy at runtime for a particular LUN (that is, for which all the paths are unavailable). For example, if you want to change the policy on the multipath device mpath2
from "queue_if_no_path"
to "fail_if_no_path"
, execute the following command.
dmsetup message mpath2 0 "fail_if_no_path"
Note that you must specify the
mpath
n
alias rather than the path.
5.4. Multipath Command Output
Wenn Sie ein multipath-Gerät erstellen, modifizieren oder auflisten, erhalten Sie einen Ausdruck der aktuellen Einstellung der Geräte. Das Format lautet wie folgt.
Für jedes multipath-Gerät:
action_if_any: alias (wwid_if_different_from_alias) [size][features][hardware_handler]
Für jede Pfad-Gruppe:
\_ scheduling_policy [path_group_priority_if_known] [path_group_status_if_known]
Für jeden Pfad:
\_ host:channel:id:lun devnode major:minor [path_status] [dm_status_if_known]
Die Ausgabe eines multipath-Befehls kann z.B. wie folgt erscheinen:
mpath1 (3600d0230003228bc000339414edb8101) [size=10 GB][features="0"][hwhandler="0"] \_ round-robin 0 [prio=1][active] \_ 2:0:0:6 sdb 8:16 [active][ready] \_ round-robin 0 [prio=1][enabled] \_ 3:0:0:6 sdc 8:64 [active][ready]
Falls der Pfad für I/O erreichbar und bereit ist, lautet sein Status
ready
oder active
. Falls der Pfad nicht erreichbar ist, lautet sein Status faulty
oder failed
. Der Pfad-Status wird periodisch durch den multipathd
-Daemon aktualisiert, basierend auf dem Abfrage-Intervall, das in der Datei /etc/multipath.conf
definiert wird.
The dm status is similar to the path status, but from the kernel's point of view. The dm status has two states:
failed
, which is analogous to faulty
, and active
which covers all other path states. Occasionally, the path state and the dm state of a device will temporarily not agree.
Anmerkung
Bei der Erstellung oder Modifizierung eines multipath-Geräts sind der "path group status" und der "dm status" nicht bekannt. Auch sind die Features nicht immer korrekt. Wenn ein multipath-Gerät aufgelistet wird, ist die "path group priority" nicht bekannt.
5.5. Multipath Queries with multipath Command
Mit Hilfe der Optionen
-l
und -ll
des Befehls multipath
können Sie die aktuelle multipath-Konfiguration anzeigen. Die Option -l
zeigt die multipath-Topologie an, die aus Informationen in sysfs
und dem Device-Mapper zusammengetragen wurden. Die Option -ll
zeigt die Informationen an, die -l
anzeigt und zusätzlich noch alle verfügbaren Komponenten des Systems.
Für die Anzeige der multipath-Konfiguration existieren drei Stufen für die umfangreiche Ausgabe, die Sie mit Hilfe der Option
-v
des Befehls multipath
angeben können. Die Angabe von -v0
produziert keine Ausgabe. Bei der Angabe von -v1
werden lediglich die erstellten oder aktualisierten multipath-Namen ausgegeben, die Sie dann in anderen Tools, wie beispielsweise kpartx
verwerten können. Durch die Angabe von -v2
werden alle erkannten "paths", "multipaths" und "device maps" ausgegeben.
Das folgende Beispiel zeigt die Ausgabe eines
multipath -l
Befehls.
# multipath -1
mpath1 (3600d0230003228bc000339414edb8101)
[size=10 GB][features="0"][hwhandler="0"]
\_ round-robin 0 [prio=1][active]
\_ 2:0:0:6 sdb 8:16 [active][ready]
\_ round-robin 0 [prio=1][enabled]
\_ 3:0:0:6 sdc 8:64 [active][ready]
5.6. Multipath Command Options
Tabelle 5.1, »Nützliche
multipath
-Befehlsoptionen« describes some options of the multipath
command that you may find useful.
Tabelle 5.1. Nützliche multipath
-Befehlsoptionen
Option | Beschreibung |
---|---|
-l | Zeigt die aktuelle multipath-Konfiguration an, die von sysfs und dem Device-Mapper zusammengetragen wurde. |
-ll | Display the current multipath configuration gathered from sysfs , the device mapper, and all other available components on the system. |
-f device | Entfernt das angegebene multipath-Gerät. |
-F | Entfernt alle multipath-Geräte. |
5.7. Device-Mapper-Einträge mit dem dmsetup-Befehl ermitteln.
Mit Hilfe des Befehls
dmsetup
können Sie herausfinden, welche Device-Mapper-Einträge zu welchen multipathed-Geräten passen.
Der folgende Befehl zeigt alle Device-Mapper-Geräte und ihre Major- und Minor- Nummern an. Die Minor-Nummern bestimmen den Namen des dm-Geräts. So entspricht eine Minor-Nummer 3 beispielsweise dem multipathed-Gerät
/dev/dm-3
.
# dmsetup ls
mpath2 (253, 4)
mpath4p1 (253, 12)
mpath5p1 (253, 11)
mpath1 (253, 3)
mpath6p1 (253, 14)
mpath7p1 (253, 13)
mpath0 (253, 2)
mpath7 (253, 9)
mpath6 (253, 8)
VolGroup00-LogVol01 (253, 1)
mpath5 (253, 7)
VolGroup00-LogVol00 (253, 0)
mpath4 (253, 6)
mpath1p1 (253, 10)
mpath3 (253, 5)
5.8. Troubleshooting with the multipathd Interactive Console
Der Befehl
multipathd -k
ist eine interaktive Schnittstelle zum multipathd
-Daemon. Bei der Eingabe dieses Befehls wird eine interaktive Konsole für multipath gestartet. Nach der Eingabe dieses Befehls können Sie help
eingeben, um eine Liste verfügbarer Befehlen abzurufen, oder einen interaktiven Befehl eingeben, oder STRG-D
eingeben, um abzubrechen.
Die interaktive Konsole für
multipathd
kann zur Problembehandlung von Problemen verwendet werden, die Sie ggf. mit Ihren Systemen haben. Die folgende Befehlssequenz zeigt beispielsweise die multipath-Konfiguration an, inklusive der Standardwerte, bevor die Konsole beendet wird.
#multipathd -k
> >show config
> >CTRL-D
Die folgende Befehlssequenz stellt sicher, dass multipath jegliche Änderungen an
multipath.conf
berücksichtigt,
#multipathd -k
> >reconfigure
> >CTRL-D
Verwenden Sie die folgende Befehlssequenz, um sicherzustellen, dass der Pfad-Checker ordnungsgemäß funktioniert.
#multipathd -k
> >show paths
> >CTRL-D
Anhang A. Revision History
Versionsgeschichte | |||
---|---|---|---|
Version 3-6.400 | 2013-10-31 | Rüdiger Landmann | |
| |||
Version 3-6 | 2012-07-18 | Anthony Towns | |
| |||
Version 1.0-0 | Thu Jan 29 2009 | ||
|
Stichwortverzeichnis
Symbole
- /etc/multipath.conf package, DM-Multipath einrichten
A
- active/active configuration
- definition, Überblick über DM-Multipath
- illustration, Überblick über DM-Multipath
- active/passive configuration
- definition, Überblick über DM-Multipath
- illustration, Überblick über DM-Multipath
- alias parameter , Multipaths Attribute zur Gerätekonfiguration
- configuration file, Multipath-Geräte-Identifizierer
B
- bindings_file parameter, Standardeinstellungen der Konfigurationsdatei
- blacklist
- configuration file, Konfigurationsdatei-Blacklist
- default devices, Blacklisting durch den Gerätenamen
- device name, Blacklisting durch den Gerätenamen
- device type, Blacklisting durch den Gerätetyp
- in configuration file, DM-Multipath einrichten
- WWID, Blacklisting durch die WWID
- blacklist_exceptions section
- multipath.conf file, Blacklist-Ausnahmen
C
- chkconfig command, DM-Multipath einrichten
- configuration file
- alias parameter, Multipaths Attribute zur Gerätekonfiguration
- bindings_file parameter, Standardeinstellungen der Konfigurationsdatei
- blacklist, DM-Multipath einrichten, Konfigurationsdatei-Blacklist
- failback parameter, Standardeinstellungen der Konfigurationsdatei, Multipaths Attribute zur Gerätekonfiguration, Konfigurationsdatei-Geräte
- features parameter, Konfigurationsdatei-Geräte
- flush_on_last_del parameter, Standardeinstellungen der Konfigurationsdatei, Multipaths Attribute zur Gerätekonfiguration, Konfigurationsdatei-Geräte
- getuid_callout parameter, Standardeinstellungen der Konfigurationsdatei, Konfigurationsdatei-Geräte
- gid parameter, Standardeinstellungen der Konfigurationsdatei, Multipaths Attribute zur Gerätekonfiguration
- hardware_handler parameter, Konfigurationsdatei-Geräte
- max_fds parameter, Standardeinstellungen der Konfigurationsdatei
- mode parameter, Standardeinstellungen der Konfigurationsdatei, Multipaths Attribute zur Gerätekonfiguration
- no_path_retry parameter, Standardeinstellungen der Konfigurationsdatei, Multipaths Attribute zur Gerätekonfiguration, Konfigurationsdatei-Geräte
- overview, Überblick über die Konfigurationsdatei
- path_checker parameter, Standardeinstellungen der Konfigurationsdatei, Konfigurationsdatei-Geräte
- path_grouping_policy parameter, Standardeinstellungen der Konfigurationsdatei, Multipaths Attribute zur Gerätekonfiguration, Konfigurationsdatei-Geräte
- path_selector parameter, Multipaths Attribute zur Gerätekonfiguration, Konfigurationsdatei-Geräte
- polling-interval parameter, Standardeinstellungen der Konfigurationsdatei
- prio_callout parameter, Standardeinstellungen der Konfigurationsdatei, Konfigurationsdatei-Geräte
- product parameter, Konfigurationsdatei-Geräte
- product_blacklist parameter, Konfigurationsdatei-Geräte
- queue_without_daemon parameter, Standardeinstellungen der Konfigurationsdatei
- rr_min_io parameter, Standardeinstellungen der Konfigurationsdatei, Multipaths Attribute zur Gerätekonfiguration
- rr_weight parameter, Standardeinstellungen der Konfigurationsdatei, Multipaths Attribute zur Gerätekonfiguration, Konfigurationsdatei-Geräte
- selector parameter, Standardeinstellungen der Konfigurationsdatei
- udev_dir parameter, Standardeinstellungen der Konfigurationsdatei
- uid parameter, Standardeinstellungen der Konfigurationsdatei, Multipaths Attribute zur Gerätekonfiguration
- user_friendly_names parameter, Standardeinstellungen der Konfigurationsdatei
- vendor parameter, Konfigurationsdatei-Geräte
- wwid parameter, Multipaths Attribute zur Gerätekonfiguration
- configuring
- DM-Multipath, DM-Multipath einrichten
D
- defaults section
- multipath.conf file, Standardeinstellungen der Konfigurationsdatei
- dev/mapper directory, Multipath-Geräte-Identifizierer
- dev/mpath directory, Multipath-Geräte-Identifizierer
- device name, Multipath-Geräte-Identifizierer
- device-mapper-multipath package, DM-Multipath einrichten
- devices
- devices section
- multipath.conf file, Konfigurationsdatei-Geräte
- DM-Multipath
- and LVM, Multipath-Geräte in Logischen Datenträgern
- components, DM-Multipath-Komponenten
- configuration file, Die DM-Multipath Konfigurationsdatei
- configuring, DM-Multipath einrichten
- definition, Device Mapper Multipathing
- device name, Multipath-Geräte-Identifizierer
- devices, Multipath-Geräte
- failover, Überblick über DM-Multipath
- overview, Überblick über DM-Multipath
- redundancy, Überblick über DM-Multipath
- setup, DM-Multipath einrichten
- setup, overview, Überblick über die Einrichtung von DM-Multipath
- dm-multipath kernel module , DM-Multipath-Komponenten
- dm-n devices, Multipath-Geräte-Identifizierer
- dmsetup command, determining device mapper entries, Device-Mapper-Einträge mit dem dmsetup-Befehl ermitteln.
F
- failback parameter, Standardeinstellungen der Konfigurationsdatei, Multipaths Attribute zur Gerätekonfiguration, Konfigurationsdatei-Geräte
- failover, Überblick über DM-Multipath
- features parameter, Konfigurationsdatei-Geräte
- feedback, Feedback
- flush_on_last_del parameter, Standardeinstellungen der Konfigurationsdatei, Multipaths Attribute zur Gerätekonfiguration, Konfigurationsdatei-Geräte
G
- getuid_callout parameter, Standardeinstellungen der Konfigurationsdatei, Konfigurationsdatei-Geräte
- gid parameter, Standardeinstellungen der Konfigurationsdatei, Multipaths Attribute zur Gerätekonfiguration
H
- hardware_handler parameter, Konfigurationsdatei-Geräte
K
- kpartx command , DM-Multipath-Komponenten
L
- local disks, ignoring, Lokale Platten beim Generieren von multipath-Geräten ignorieren
- LVM physical volumes
- multipath devices, Multipath-Geräte in Logischen Datenträgern
- lvm.conf file , Multipath-Geräte in Logischen Datenträgern
M
- max_fds parameter, Standardeinstellungen der Konfigurationsdatei
- mode parameter, Standardeinstellungen der Konfigurationsdatei, Multipaths Attribute zur Gerätekonfiguration
- modprobe command, DM-Multipath einrichten
- multipath command , DM-Multipath-Komponenten, DM-Multipath einrichten
- options, Multipath Command Options
- output, Multipath Command Output
- queries, Multipath Queries with multipath Command
- multipath daemon (multipathd), The Multipath Daemon
- multipath devices, Multipath-Geräte
- logical volumes, Multipath-Geräte in Logischen Datenträgern
- LVM physical volumes, Multipath-Geräte in Logischen Datenträgern
- multipath.conf file, Speicher-Array-Unterstützung, Die DM-Multipath Konfigurationsdatei
- blacklist_exceptions section, Blacklist-Ausnahmen
- defaults section, Standardeinstellungen der Konfigurationsdatei
- devices section, Konfigurationsdatei-Geräte
- multipaths section, Multipaths Attribute zur Gerätekonfiguration
- multipath.conf.annotated file, Die DM-Multipath Konfigurationsdatei
- multipath.conf.defaults file, Speicher-Array-Unterstützung, Die DM-Multipath Konfigurationsdatei
- multipathd
- command, Troubleshooting with the multipathd Interactive Console
- interactive console, Troubleshooting with the multipathd Interactive Console
- multipathd daemon , DM-Multipath-Komponenten
- multipathd start command, DM-Multipath einrichten
- multipaths section
- multipath.conf file, Multipaths Attribute zur Gerätekonfiguration
N
- no_path_retry parameter, Standardeinstellungen der Konfigurationsdatei, Multipaths Attribute zur Gerätekonfiguration, Konfigurationsdatei-Geräte
P
- path_checker parameter, Standardeinstellungen der Konfigurationsdatei, Konfigurationsdatei-Geräte
- path_grouping_policy parameter, Standardeinstellungen der Konfigurationsdatei, Multipaths Attribute zur Gerätekonfiguration, Konfigurationsdatei-Geräte
- path_selector parameter, Multipaths Attribute zur Gerätekonfiguration, Konfigurationsdatei-Geräte
- polling_interval parameter, Standardeinstellungen der Konfigurationsdatei
- prio_callout parameter, Standardeinstellungen der Konfigurationsdatei, Konfigurationsdatei-Geräte
- product parameter, Konfigurationsdatei-Geräte
- product_blacklist parameter, Konfigurationsdatei-Geräte
Q
- queue_without_daemon parameter, Standardeinstellungen der Konfigurationsdatei
R
S
- selector parameter, Standardeinstellungen der Konfigurationsdatei
- setup
- DM-Multipath, DM-Multipath einrichten
- storage array support, Speicher-Array-Unterstützung
- storage arrays
U
- udev_dir parameter, Standardeinstellungen der Konfigurationsdatei
- uid parameter, Standardeinstellungen der Konfigurationsdatei, Multipaths Attribute zur Gerätekonfiguration
- user_friendly_names parameter , Multipath-Geräte-Identifizierer, Standardeinstellungen der Konfigurationsdatei
V
- vendor parameter, Konfigurationsdatei-Geräte
W
- World Wide Identifier (WWID), Multipath-Geräte-Identifizierer
- wwid parameter, Multipaths Attribute zur Gerätekonfiguration
Rechtlicher Hinweis
Copyright © 2009 Red Hat, Inc.
This document is licensed by Red Hat under the Creative Commons Attribution-ShareAlike 3.0 Unported License. If you distribute this document, or a modified version of it, you must provide attribution to Red Hat, Inc. and provide a link to the original. If the document is modified, all Red Hat trademarks must be removed.
Red Hat, as the licensor of this document, waives the right to enforce, and agrees not to assert, Section 4d of CC-BY-SA to the fullest extent permitted by applicable law.
Red Hat, Red Hat Enterprise Linux, the Shadowman logo, JBoss, OpenShift, Fedora, the Infinity logo, and RHCE are trademarks of Red Hat, Inc., registered in the United States and other countries.
Linux® is the registered trademark of Linus Torvalds in the United States and other countries.
Java® is a registered trademark of Oracle and/or its affiliates.
XFS® is a trademark of Silicon Graphics International Corp. or its subsidiaries in the United States and/or other countries.
MySQL® is a registered trademark of MySQL AB in the United States, the European Union and other countries.
Node.js® is an official trademark of Joyent. Red Hat Software Collections is not formally related to or endorsed by the official Joyent Node.js open source or commercial project.
The OpenStack® Word Mark and OpenStack logo are either registered trademarks/service marks or trademarks/service marks of the OpenStack Foundation, in the United States and other countries and are used with the OpenStack Foundation's permission. We are not affiliated with, endorsed or sponsored by the OpenStack Foundation, or the OpenStack community.
All other trademarks are the property of their respective owners.