Home IT Linux Windows Database Network Programming Server Mobile  
           
  Home \ Linux \ RHEL5 multipath configuration     - Linux system security knowledge (Linux)

- Fun music library in Linux using command line (Linux)

- Thinking in Java study notes - Generics (Programming)

- Bash Automated Customization Linux belongs to its own CentOS system (Linux)

- Installation and management of Linux applications (Linux)

- Java memory analysis tool uses detailed MAT (Programming)

- crontab task scheduling Health Check (Linux)

- Install JDK 1.7 + Eclipse in CentOS 6.4 in (Linux)

- Linux Basics Tutorial: Combining awk delete data before the specified date hdfs (Linux)

- Java polymorphic methods inside constructors complete analysis (Programming)

- Getting jQuery - progress bar (Programming)

- DB2 manually create a library (Database)

- VMware Workstation virtual machine startup error: Could not open / dev / vmmon in CentOS 6 (Linux)

- Ubuntu deployment Flask + UWSGI + Nginx Comments (Server)

- Oracle 12c users create (Database)

- Oracle Database High-Risk Vulnerability Warning (Database)

- Android Unzip the ZIP / GZIP data (based on the InflaterInputStream implementation) (Programming)

- Caffe install under Ubuntu 14.04 64bit (Linux)

- Via Twitter how open source library to be used anywhere Emoji emoticons (Linux)

- Depth understanding of DB2 table space (Tablespace) (Database)

 
         
  RHEL5 multipath configuration
     
  Add Date : 2018-11-21      
         
       
         
  1 Check whether the package is installed
[Root @ pcvmaster ~] # rpm -qa | grep device-mapper
device-mapper-libs-1.02.74-10.el6.x86_64
device-mapper-event-libs-1.02.74-10.el6.x86_64
device-mapper-multipath-0.4.9-56.el6.x86_64
device-mapper-1.02.74-10.el6.x86_64
device-mapper-event-1.02.74-10.el6.x86_64
device-mapper-multipath-libs-0.4.9-56.el6.x86_64
2 Install multipath
[Root @ pcvmaster ~] # yum -yinstall multipath
3 boot
[Root @ pcvmaster ~] # chkconfigmultipathd on
4 Edit the multipath configuration file
vi /etc/multipath.conf
# This is a basicconfiguration file with some examples, for device mapper
# Multipath.
# For a complete list of thedefault configuration values, see
# / Usr / share / doc / device-mapper-multipath-0.4.9 / multipath.conf.defaults
# For a list of configurationoptions with descriptions, see
# / Usr / share / doc / device-mapper-multipath-0.4.9 / multipath.conf.annotated
#
# REMEMBER: After updatingmultipath.conf, you must run
#
# Service multipathd reload
#
# For the changes to takeeffect in multipathd
 
## By default, devices withvendor = "IBM" and product = "S / 390. *" are
## Blacklisted. To enablemulitpathing on these devies, uncomment the
## Following lines.
#blacklist_exceptions {
# Device {
# Vendor "IBM"
# Product "S / 390. *"
#}
#}
 
## Use user friendly names, instead of using WWIDs as names.
defaults {
      user_friendly_names yes
}
##
## Here is an example of howto configure some standard options.
##
#
#defaults {
# Udev_dir / dev
# Polling_interval 10
# Selector "round-robin0"
# Path_grouping_policy multibus
# Getuid_callout "/ lib / udev / scsi_id - whitelisted --device = / dev /% n"
# Prio alua
# Path_checker readsector0
# Rr_min_io 100
# Max_fds 8192
# Rr_weight priorities
# Failback immediate
# No_path_retry fail
# User_friendly_names yes
#}
##
## The wwid line in thefollowing blacklist section is shown as an example
## Of how to blacklistdevices by wwid. The 2 devnode lines arethe
## Compiled in defaultblacklist. If you want to blacklist entire types
## Of devices, such as allscsi devices, you should use a devnode line.
## However, if you want toblacklist specific devices, you should use
## A wwid line. Since there is no guarantee that a specificdevice will
## Not change names on reboot (from / dev / sda to / dev / sdb for example)
## Devnode lines are notrecommended for blacklisting specific devices.
##
#blacklist {
# Wwid 26353900f02796769
# Devnode "^ (ram | raw | loop | fd | md | dm- | sr | scd | st) [0-9] *"
# Devnode "^ hd [a-z]"
#}
#multipaths {
# Multipath {
# Wwid 3600508b4000156d700012000000b0000
# Alias ​​yellow
# Path_grouping_policy multibus
# Path_checker readsector0
# Path_selector "round-robin0"
# Failback manual
# Rr_weight priorities
# No_path_retry 5
#}
# Multipath {
# Wwid 1DEC_____321816758474
# Alias ​​red
#}
#}
#devices {
# Device {
# Vendor "COMPAQ"
# Product "HSV110 (C) COMPAQ"
# Path_grouping_policy multibus
# Getuid_callout "/ lib / udev / scsi_id --whitelisted --device = / dev /% n"
# Path_checker readsector0
# Path_selector "round-robin0"
# Hardware_handler "0"
# Failback 15
# Rr_weight priorities
# No_path_retry queue
#}
# Device {
# Vendor "COMPAQ"
# Product "MSA1000"
# Path_grouping_policy multibus
#}
#}
 
blacklist {
devnode "^ (ram | raw | loop | fd | md | dm- | sr | sr | scd | st) [0-9] *"
devnode "^ hd [a-z]"
}
devices {
device {
vendor "Netapp"
path_grouping_policymultibus
features "1queue_if_no_path"
path_checkerreadsector ()
failback immediate
}
}
5 Start Service
[Root @ pcvmaster ~] # / etc / init.d / multipathd start
6 Delete the existing path is not used
[Root @ pcvmaster ~] # multipath-F
7 formatted path detection path, the path merge
[Root @ pcvmaster ~] # multipath-v2
8 See multipath conditions
[Root @ pcvmaster ~] # multipath-ll
9 Reboot the system
[Root @ pcvmaster ~] # reboot
10 Creating PV multiple disks,
[Root @ pcvmaster ~] # pvcreate / dev / mapper / mpath {d, f, e, p, t, k, j, c, s, q}
11 add multiple disks to Volbackup
[Root @ pcvmaster ~] # vgcreateVolbackup / dev / mapper / mpath {d, f, e, p, t, k, j, c, s, q}
12 Creating LV
[Root @ pcvmaster ~] # lvcreate-l 1310780 -n LogVol01 Volbackup
13 Formatting LV
[Root @ pcvmaster ~] mkfs.ext4 / dev / Volbackup / LogVol01
14 Mount
[Root @ pcvmaster ~] # mount / dev / Volbackup / LogVol01 / backup
15FAQ
15.1 After the module is not loaded successfully
If the module is not loaded successfully use the following command to initialize DM, or reboot the system
--- Use thefollowing commands to initialize and start DM for the first time:
# Modprobedm-multipath
# Modprobe dm-round-robin
# Servicemultipathd start
# Multipath -v2
15.2 multipath principle introduction
1, device-mapper-multipath: namely multipath-tools. Multipathd and mainly provides tools such as multipath and multipath.conf and other configuration files. These tools of ioctr device mapper interface to create and configure multipath devices (call the user-space library of device-mapper. Multipath devices will be created in the / dev / mapper in).
 
2, device-mapper: includes two parts: the core part and a user part. The main part of the kernel from the device mapper kernel (dm.ko) and some of the target driver (md-multipath.ko). Core complete the mapping device, and target specific processing device down from mappered i / o according to the mapping relationship and its own characteristics. Meanwhile, in the central part, provides an interface, users can ioctr and kernel part of the communication, to guide the kernel driver behavior, such as how to create mappered device, the properties of these divece like. User-space portion linux device mapper mainly include device-mapper package. Including dmsetup tools and some help to create and configure mappered device libraries. These libraries mainly abstraction, encapsulation interface ioctr communication with, easy to create and configure mappered device. multipath-tool program you need to call these libraries.
 
3, dm-multipath.ko and dm.ko: dm.ko is devicemapper drive. It is the basis of multipath. dm dm-multipath is actually a target drive.
 
4, scsi_id: udev included in the package, you can configure the program to get the numbers in multipath.conf scsi device. By number, you can determine a plurality of paths corresponding to the same device. This is the key to multi-path implementation. scsi_id by sg driver, or sent to the device EVPD page80 page83 of inquery command to query identifies scsi devices. However, some devices do not support EVPD of inquery command, so they can not be used to generate multipath devices. But can be rewritten scsi_id, it was unable to provide a virtual scsi device identification of a device identifier, and output to standard output. multipath program when creating multipath devices, calls scsi_id, get scsi id of the device from its standard output. When rewriting scsi_id need to modify the program returns 0. Because multipath program checks to determine whether the direct scsi id has been successfully obtained.
     
         
       
         
  More:      
 
- Bash Getopts - let your script supports command line parameters (Linux)
- Linux permissions Detailed (Linux)
- Apache Web Security Linux systems (Linux)
- Workaround CentOS error message during compilation PHP5 common (Linux)
- Batch kill processes using awk command (Linux)
- Shell for loop (Programming)
- DataGuard the MRP can not start to analyze and solve problems (Database)
- Installation through the network Debian 7 (Wheezy) (Linux)
- Flow control message transmission between RAC (Database)
- Android WebView use layman (Programming)
- Fedora10 use Git version Configuration Management (Linux)
- Oracle Client Easy Connection error ORA-12154, TNS-03505 (Database)
- Linux / UNIX: Use the dd command to create a 1GB size binary (Linux)
- How to use GRUB2 files directly from the hard disk to run ISO (Linux)
- Linux (SUSE) mount NTFS mobile hard practice (Linux)
- Merge sort Java implementation (Programming)
- Node.js form --formidable (Programming)
- Ubuntu How to mount iso file (Linux)
- How to use SVN to manage our source code (Server)
- MySQL Tutorial: Philosophical Reflections on the unauthenticated user (Database)
     
           
     
  CopyRight 2002-2016 newfreesoft.com, All Rights Reserved.