Linux自带多路径详解

发表于:2014-7-28 10:17

字体: | 上一篇 | 下一篇 | 我要投稿

 作者:Alexy Young    来源:51Testing软件测试网采编

  4、命令
[root@web2 ~]# multipath -h
multipath-tools v0.4.7 (03/12, 2006)
Usage: multipath        [-v level] [-d] [-h|-l|-ll|-f|-F|-r]
[-p failover|multibus|group_by_serial|group_by_prio]
[device]
-v level        verbosity level
0                    no output
1                    print created devmap names only
2                    default verbosity
3                    print debug information
-h              print this usage text
-b file         bindings file location
-d              dry run, do not create or update devmaps
-l              show multipath topology (sysfs and DM info)
-ll             show multipath topology (maximum info)
-f              flush a multipath device map
-F              flush all multipath device maps
-r              force devmap reload
-p policy       force all maps to specified policy :
failover             1 path per priority group
multibus             all paths in 1 priority group
group_by_serial      1 priority group per serial
group_by_prio        1 priority group per priority lvl
group_by_node_name   1 priority group per target node
device          limit scope to the device's multipath
(udev-style $DEVNAME reference, eg /dev/sdb
or major:minor or a device map name)
[root@web2 ~]#
  5、启动关闭
  # /etc/init.d/multipathd start      #开启mulitipath服务
  service multipath start
  service multipath restart
  service multipath shutdown
  6、如何获取wwid
  1、
  [root@vxfs01 ~]# cat /var/lib/multipath/bindings
  # Multipath bindings, Version : 1.0
  # NOTE: this file is automatically maintained by the multipath program.
  # You should not need to edit this file in normal circumstances.
  #
  # Format:
  # alias wwid
  #
  mpath0 36006016051d50e0035744871c912de11
  mpath1 36006016051d50e0034744871c912de11
  mpath2 36006016051d50e0032744871c912de11
  mpath3 36006016051d50e0039744871c912de11
  mpath4 36006016051d50e003a744871c912de11
  2、
  [root@vxfs01 ~]# multipath -v3 |grep 3600
  sdb: uid = 36006016051d50e003a744871c912de11 (callout)
  sdc: uid = 36006016051d50e003a744871c912de11 (callout)
  sdd: uid = 36006016051d50e003a744871c912de11 (callout)
  sde: uid = 36006016051d50e003a744871c912de11 (callout)
  36006016051d50e003a744871c912de11 1:0:0:0 sdb 8:16  0   [undef][ready] DGC,RAI
  36006016051d50e003a744871c912de11 1:0:1:0 sdc 8:32  1   [undef][ready] DGC,RAI
  36006016051d50e003a744871c912de11 2:0:0:0 sdd 8:48  1   [undef][ready] DGC,RAI
  36006016051d50e003a744871c912de11 2:0:1:0 sde 8:64  0   [undef][ready] DGC,RAI
  Found matching wwid [36006016051d50e003a744871c912de11] in bindings file.
22/2<12
《2023软件测试行业现状调查报告》独家发布~

关注51Testing

联系我们

快捷面板 站点地图 联系我们 广告服务 关于我们 站长统计 发展历程

法律顾问:上海兰迪律师事务所 项棋律师
版权所有 上海博为峰软件技术股份有限公司 Copyright©51testing.com 2003-2024
投诉及意见反馈:webmaster@51testing.com; 业务联系:service@51testing.com 021-64471599-8017

沪ICP备05003035号

沪公网安备 31010102002173号