电工技术基础_电工基础知识_电工之家-电工学习网

欢迎来到电工学习网!

Cisco检查某条流在etherchannel中走哪条物理link

2017-07-24 14:49分类:电子技术 阅读:

 

Cisco检查某条流在etherchannel中走哪条物理link
怎样检查某一条流在etherchannel中走哪一条物理link,触及设备路径:Cisco Catalyst 6500, 4500, 2960, 3750, 3750G,3750X, and 3560 Series Switches.
  布景:
  Etherchannel load-balance工作是依据所装备的关于纷歧样流量的哈希算法所得到的0-7这8个哈希值的。哈希的作用咱们叫做 Result Bundle Hash (RBH)
  留神哈希值是依据咱们所装备的load-balancing 的算法来断定的。下面是一个比方:
  Source 192.168.1.1 (mac a.a.a ) sending a tcp stream to 172.16.1.1 ( mac b.b.b )
  with a source tcp port of 50 and destination port 2000
  Source 192.168.1.1 (mac a.a.a ) sending a tcp stream to 209.165.201.1 ( mac c.c.c )
  with a source tcp port of 60 and destination 2000.
  If configured load balancing algorithm is SRC_MAC
  Then no of flows = 1
  If configured load balancing algorithm is DST_MAC
  Then no of flows = 2
  If configured load balancing algorithm is DST_PORT
  Then no of flows= 1
  Catalyst 6500 系列:
  1, 查在用的load-balance算法
  2, 进入switch processor (SP),敲show etherchannel load-balance:
  6500#remote login sw
  Trying Switch ...
  Entering CONSOLE for Switch
  Type "^C^C^C" to end this session
  6500−sp#show etherchannel load−balance
  EtherChannel Load−Balancing Configuration:
  src−dst−ip
  mpls label−ip
  3, 查详细某一条flow的RBH 值:
  6500−sp#test etherchannel load−balance interface port−channel
  在上面的比方中,这条flow是在192.168.1.1 和172.16.1.1,疑问中的Portchannel是port-channel 1。假定咱们装备的算法是依据src-dst ip 的,那咱们就填入源目IP: 192.168.1.1 和 172.16.1.1:
  6500−sp#test etherchannel load−balance int port−channel 1 ip 192.168.1.1 172.16.1.1
  Computed RBH: 0x5
  Would select Gi3/2 of Po1
  4, 在一些IOS中是不会去显现流量从哪个详细物理接口的,能够运用如下的办法:
  在RP的console中敲show interface port−channel etherchannel。 然后再依照下面的办法核算出来是哪个物理端口:
  6500#show interface port−channel 1 etherchannel
  Port−channel1 (Primary aggregator)
  Age of the Port−channel = 0d:01h:05m:54s
  Logical slot/port = 14/1 Number of ports = 2
  HotStandBy port = null
  Port state = Port−channel Ag−Inuse
  Protocol = LACP
  Fast−switchover = disabled
  Ports in the Port−channel:
  Index Load Port EC state No of bits
  −−−−−−+−−−−−−+−−−−−−+−−−−−−−−−−−−−−−−−−+−−−−−−−−−−−
  0 55 Gi3/1 Active 4
  1 AA Gi3/2 Active 4
  在输出中load一栏能够看到两个Portchannel中的接口别离为55 和AA。
  咱们别离将55和AA改换为2进制后,用下面的办法来断定RBH值对应的物理接口是哪个:

  像上面这么,AA对应的2进制是1010 1010;55对应的是0101 0101 。然后再从7-0进行匹配,对应1的即是该接口所对应的RBH值。
  在上面比方中,G3/2对应的RBH值为:1 3 5 7;G3/1对应的是0 2 4 6
  这么咱们再得到RBH值往后就能够用这种办法匹配出对应接口。
  Catalyst 4500 系列沟通机:
  1, 检查load-balancing算法: show etherchannel load-balance
  2, 用如下指令检查:
  4500#show platform software etherchannel port−channel 1 map ip 192.168.1.1 172.16.1.1
  Map port for IP 192.168.1.1, 172.16.1.1 is Gi3/1(Po1)
  NOTE: Software forwarded traffic uses Gi3/1(Po1)
  Catalyst 3750 系列沟通机:
  运用如下指令:
  test etherchannel load−balance interface port−channel
  举个比方:
  3750(config)#port−channel load−balance src−dst−ip
  3750#show etherchannel load−balance
  EtherChannel Load−Balancing Configuration:
  src−dst−ip
  3750#test etherchannel load−balance interface port−channel 1 ip 192.168.1.1 172.16.1.1
  Would select Gi3/1 of Po1
  假定算法是依据MAC地址的,依据源目MAC也能够用该指令找到物理端口。

上一篇:vlan与三层沟通及Trunk的概念和疑问点

下一篇:光纤的分类_光纤构造_光纤品种

相关推荐

电工推荐

    电工技术基础_电工基础知识_电工之家-电工学习网
返回顶部