CCIE DC Multicast Part 3.
Hi Guys!
Here is part 3 of the Multicast Tutorials, Hopefully you have read the two previous posts here and here on multicast/Shared/Source tree's, and the post on SSM (Source Specific Multicast).
这里是组播实验的第三部分,希望你已经阅读了前两篇,关于组播共享树源树和SSM相关
The next thing we need to look at is Bi-Directional PIM.
下面的内容我们需要学习BIDir双向PIM
So remember how in SSM we had sparse-mode PIM, but due to the enhancements in IGMPv3 including the source address of a multicast stream AND the multicast group address that we want to join, there was no need for the RP, so more efficient, Source-based tree's could be made even though we where using PIM Sparse mode?
记得在SSM特定源组播我们如何需要Sparse-mode PIM,但是由于在IGMPv3的增强能力包含组播流的源地址,因此不需要RP,因此基于源的树可能更效率,尽管我们使用了PIM Sparse模式
Bi-Dir is kind of the opposite of that, everything is a shared-tree, but traffic can flow bidirectional (We will get to what that means in a minute.)
Bi-Dir相反,什么都是共享树的,但是流量是可以双向(一会解释什么意思)
Why would we want everything to be a shared tree? Didn't we just establish that SSM was great because it made everything use an efficient source-based tree?
为什么我们想让任何事情都是共享树?我们建立SSM不是挺好的吗? 它可使用更效率的基于源的树啊。
Imagine a massive network of multicast traffic, with many sources and many receivers (a many-to-many multicast application network). A network like this would quickly add hundreds, even thousands and tens of thousands of (S,G), multicast entries in the mroute table. One of the major applications for Multicast is financial services, stock markets etc, and in today's climate of HFT (High-Frequency-Trading), latency is a big no-no.
想象一个庞大的组播流量网络,有很多的源和接收者(多对多组播应用网络),一个网络可能在组播路由表里迅速添加成百上千的(S,G)组播条目,而组播最主要的应用是金融服务,股票市场,在当今高频交易的环境下,延迟是一个大大不可以。
All those multicast entries in the mroute table will slow the switch down, and start to make the switch inefficient, thus, we have Bidirectional PIM, the idea is that if everything uses a shared tree, we can reduce the number of mroute table entries down to just those with (,G), when using one multicast group address with multiple sources, this efficiency really starts making sense.
这么多的组播条目将使交换机变慢,变得低效率,因此,我们有双向PIM,想法就是如果什么都是用共享树,我们可以减少组播路由表条目,只用(,G),当使用一个组播地址带多个源时,这个效率就真的变得有意义了。
Now we get into the Bi-Directional part of the discussion.
现在我们开始Bi-Dir的讨论吧
So, when we use a shared tree, what is our major issue with it? It's inefficient distribution. The other problem with a shared tree is: How does the multicast traffic from the SOURCE, get to the RP when PIM Sparse mode doesn't forward multicast traffic unless it already has entries? Sparse Mode normal PIM get's around this by delivering the traffic via unicast first, then switching to a source-based tree as soon as possible.
那么,当我们使用一个共享树,我们主要的问题是什么?就是它的不够效率的分发,另一个共享树的问题,如何当PIM Sparse mode还没有组播条目的时候让组播流从源到达RP,Sparse mode正常PIM是通过第一次使用单播传送的方式解决的,然后尽可能的转到基于源树的转发。
What Bidirectional PIM does, is elect routers along the path from the source back to the RP as "designated forwarders", these designated forwarders are elected based on who has the best route back to the RP. A designated forwarder is elected for every LAN segment, because the multicast traffic might be sourced from that LAN segment.
Bi-Dir所做的就是,选择从源端到RP之间路径上的路由器作为“指定转发器”,这些指定的转发器被选择基于谁是最优到RP的路由器,这个指定转发器在每个LAN分段都会选取,因为组播流量都可能源自这些LAN分段
The topology we will use is shown below:
As you can see, traffic travels up the tree from the source, through PIM1 to the RP, and then, despite all the rules of multicast which essentially say "never forward multicast back through the interface it was received on" (A kind of loop prevention mechanism), what do we do? We forward back on the same interface we received from, Cause that's how we roll.
你可以看到,流量从源穿越这个树到达RP,然后不管组播的基本规则(防环用的):不再转发回组播流到组播流量的接收端口,Bir会怎么做,将转发到我们接收到组播的那个相同的接口,因为我们就是很牛逼.
Hence the term, Bi-Directional PIM.
这就是这个术语 Bi-Dir PIM,
So without any further chit-chat let's see it in action.
不废话了,我们继续往下看。
On each of the routers involved in your bidir Pim, enable the following, note that if your going to enable Bi-DIR Pim, you need to do it NETWORK WIDE, here is the caution straight from cisco:
在PIM域每个路由器上使用下面命令开启,注意如果你想使用Bi-Dir PIM,你需要在所有网络范围都要开启它,下面是cisco的直接警告:
"Packet loops will occur immediately in networks that are only partially upgraded to support bidir-PIM."
只有部分设备升级支持bidir-PIM时,包环路会立即发生在网络。
Yikes! So hopefully you can see, enable it EVERYWHERE>
所以,希望你看到,要开启它在任何网络PIM范围。
ip pim bidir-enable
ip pim rp-address 2.2.2.5
ip pim send-rp-announce GigabitEthernet1/0 scope 255 bidir
ip pim send-rp-discovery GigabitEthernet1/0 scope 255
The major commands we care about are the bidir-enable at the top, and the send-rp-announce bidir, don't worry too much about those commands at the moment, RP discovery will be covered in my next blog post.
我们主要关心的开启Birdir的命令在顶端,send-rp-announce bidir不需要多关注,RP 发现我们将在下一章介绍
OK so now you have it enabled, let's keep investigating.
ok,现在开启后,我们继续观察
First of all, let's have a look at what happens on the routers in regards to the Designated Forwarder:
首先,我们看看路由器上的DF发生了什么
Check out the section we have highlighted in the picture, subnet 10.2.0.0, let's say we have a IGMP source on this segment, WHO is the designated forwarder for this segment?
检查高亮的部分这段,子网10.20.0.0,我们说我们在这个分段有个源,那谁是这个段的DF?
The DF election is based on whomever has the best metric to the address of the RP, let's check out some debugs:
DF选举基于谁到RP有最好度量的,让我们检查一下debug信息:
"Pim1
Debug ip pim df
b 6 21:45:36.527: PIM(0): Send v2 Winner on GigabitEthernet1/0 (DF) for RP 2.2.2.5
*Feb 6 21:45:36.531: PIM(0): Sender 1.1.1.2, pref 110, metric 2
*Feb 6 21:45:36.531: PIM(0): Send v2 Winner on GigabitEthernet2/0 (DF) for RP 2.2.2.5
*Feb 6 21:45:36.531: PIM(0): Sender 10.2.0.1, pref 110, metric 2
*Feb 6 21:45:38.151: PIM(0): Receive DF Winner message from 10.0.0.2 on GigabitEthernet3/0 (Non-DF)
*Feb 6 21:45:38.155: PIM(0): RP 2.2.2.5, pref 0, metric 0
*Feb 6 21:45:38.155: PIM(0): Metric is better
*Feb 6 21:45:44.003: PIM(0): Receive DF Winner message from 10.0.0.2 on GigabitEthernet3/0 (Non-DF)
*Feb 6 21:45:44.007: PIM(0): RP 2.2.2.5, pref 0, metric 0
*Feb 6 21:45:44.007: PIM(0): Metric is better
"
Let's examine these line by line, the first statement is that we are sending out a v2 Winner (Pim1 is the designated forwarder for int gi1/0, he will forward multicasts for that segment up to the RP, the reason he is the winner is because his routes are pref 110, metric 2 to the RP address 2.2.2.5, let's check the unicast routing table:
让我们一行一行检查,第一个段是正在发送v2获胜信息,(Pim1的G1/0是DF,他将转发组播流量到RP,获胜的原因是他到RP 2.2.2.5有110的优先级和2的度量,让我们检查单薄路由表)
"PIM1#show ip route 2.2.2.5
Routing entry for 2.2.2.0/24
Known via "ospf 1", distance 110, metric 2, type intra area
"
Well whatya know? The routers unicast routing table says the distance is 110, and the metric is 2, funny that!
知道了吗?单播路由表告诉的距离是110,度量是2
So PIM checks to see who is closest to the RP, based on the metrics in the unicast routing table, and the winner of that becomes the DF for that segment.
所以,PIM检查谁是最近到RP的是基于单播路由表上的度量值,然后获胜者变成了这个网段的DF
You can see that on interface gi3/0 (the interface that faces the RP), that PIM1 has conceded it is not the DF, because the metric sent to it by the RP is better (in this case it's pref 0 metric 0, because 2.2.2.0/24 is directly connected to the RP.)
你可以看到G3/0接口(面向RP的),PIM1直接连接RP的接口不是DF,因为RP发过来的度量更优
the Designated forwarder make sense? Check out the below for a bit more info
DF什么用途?查看下面更多的信息
PIM1#show ip pim interface df
- implies this system is the DF
Interface RP DF Winner Metric Uptime
GigabitEthernet1/0 2.2.2.5 *1.1.1.2 2 00:08:57
GigabitEthernet2/0 2.2.2.5 *10.2.0.1 2 00:08:57
GigabitEthernet3/0 2.2.2.5 10.0.0.2 0 00:07:43
Hopefully the designated forwarder is starting to make sense, let's look at what happens
when we actually generate some multicast! Woopie!!!
希望DF有它的作用,让我们看一下当产生一些组播的时候发生了什么
Receiver3(config)#int gi1/0
Receiver3(config-if)#ip igmp join
Receiver3(config-if)#ip igmp join-group 239.1.1.1
Receiver2(config)#int gi1/0
Receiver2(config-if)#ip igmp join-group 239.1.1.1
Source1#ping 239.1.1.1
Type escape sequence to abort.
Sending 1, 100-byte ICMP Echos to 239.1.1.1, timeout is 2 seconds:
Reply to request 0 from 10.1.0.1, 64 ms
Reply to request 0 from 2.2.2.1, 68 ms
Our multicast worked! Let's have a look at which tree was generated:
组播正常工作,再看看产生了哪些树?
PIM1#
PIM1#show ip mroute
IP Multicast Routing Table
Flags: D - Dense, S - Sparse, B - Bidir Group, s - SSM Group, C - Connected,
L - Local, P - Pruned, R - RP-bit set, F - Register flag,
T - SPT-bit set, J - Join SPT, M - MSDP created entry, E - Extranet,
X - Proxy Join Timer Running, A - Candidate for MSDP Advertisement,
U - URD, I - Received Source Specific Host Report,
Z - Multicast Tunnel, z - MDT-data group sender,
Y - Joined MDT-data group, y - Sending to MDT-data group,
V - RD & Vector, v - Vector
Outgoing interface flags: H - Hardware switched, A - Assert winner
Timers: Uptime/Expires
Interface state: Interface, Next-Hop or VCD, State/Mode
(*,224.0.0.0/4), 00:13:25/-, RP 2.2.2.5, flags: B
Bidir-Upstream: GigabitEthernet3/0, RPF nbr: 10.0.0.2 Incoming interface list:
GigabitEthernet3/0, Accepting/Sparse
GigabitEthernet2/0, Accepting/Sparse
GigabitEthernet1/0, Accepting/Sparse
(, 239.1.1.1), 00:02:06/00:03:21, RP 2.2.2.5, flags: B
Bidir-Upstream: GigabitEthernet3/0, RPF nbr 10.0.0.2 Outgoing interface list:
GigabitEthernet2/0, Forward/Sparse, 00:02:06/00:03:21
GigabitEthernet3/0, Bidir-Upstream/Sparse, 00:02:06/stopped
You can see from the above output that the first thing the router does is create a shared tree for every single multicast group (224.0.0.0/4), this is the parent entry for all multicast groups. The next thing that happens is that the shared tree (,239.1.1.1) is created, the flag shows B for bidirectional group, and instead of "incoming-interface" we have the words "BiDir-upstream" which in this case is Gi3/0 (where the traffic is sourced from), if you notice.. Gi3/0 is also in the outgoing interface list, so will have the traffic forwarded out of it...
你可以看到上面的输出,第一个看到的是路由器产生了一个共享树为每一个组播组,这是个父系条目,下一个是生成了一个共享树(*,239.1.1.1),标志位是B代表双向组,替换“入接口”我们有个词叫"BiDir-upstream",在我们这情况是G3/0(流量源自),如果你注意,G3/0也在出接口列表,所以也可以让流量转发出去
The next thing you will notice is the 00:02:06/Stopped, that is because this entry will never time out, because this is where the designated forwarder is.
下面的事情你注意到00:02:06/Stopped,这个条目没有超时时间,因为这是DF所在的地方
Let's take a look at PIM2:
PIM2#show ip mroute
IP Multicast Routing Table
Flags: D - Dense, S - Sparse, B - Bidir Group, s - SSM Group, C - Connected,
L - Local, P - Pruned, R - RP-bit set, F - Register flag,
T - SPT-bit set, J - Join SPT, M - MSDP created entry, E - Extranet,
X - Proxy Join Timer Running, A - Candidate for MSDP Advertisement,
U - URD, I - Received Source Specific Host Report,
Z - Multicast Tunnel, z - MDT-data group sender,
Y - Joined MDT-data group, y - Sending to MDT-data group,
V - RD & Vector, v - Vector
Outgoing interface flags: H - Hardware switched, A - Assert winner
Timers: Uptime/Expires
Interface state: Interface, Next-Hop or VCD, State/Mode
(*,224.0.0.0/4), 00:03:30/-, RP 2.2.2.5, flags: B
Bidir-Upstream: GigabitEthernet2/0, RPF nbr: 10.2.0.1
Incoming interface list:
GigabitEthernet1/0, Accepting/Sparse
GigabitEthernet2/0, Accepting/Sparse
(*, 239.1.1.1), 00:03:30/00:02:22, RP 2.2.2.5, flags: BC
Bidir-Upstream: GigabitEthernet2/0, RPF nbr 10.2.0.1
Outgoing interface list:
GigabitEthernet1/0, Forward/Sparse, 00:03:30/00:02:22
GigabitEthernet2/0, Bidir-Upstream/Sparse, 00:03:30/stopped
Again we see how the multicast works, we notice that there is a bidir upstream interface again and that it is set to never timeout, the flags also show BC for BiDir and Connected (a receiver is locally connected.)
在一次看组播如何工作的,我们注意到也有个bidir upstream在PIM2上,它作为出接口没有超时时间,BC位是BiDir和Connect直连接收者
There you have it, Bi-Dir! I hope you enjoyed this blog post. As I have mentioned previously, if you find it useful the best books i have ever found on multicast are linked below, please use my links below if you enjoyed my blog post .
这里你了解完了Bi-Dir,希望你能喜欢这篇
BiDir的个人总结:
1, RP 主要实现 DF的选举和BiDir-upstream 的选举,最终每个路由器产生默认(,G)表项
2 , 每个路由器上都有一个BiDir-Upstream接口, 其中到达RP的出接口网段的DF是作为BiDir-upstream 的上游neighbor
3, 配置RP Bir以后会产生一条默认(,224.0.0.0/4)组播表项
4, 组播源没有单播注册报文转发到RP,组播源是通过默认(,224.0.0.0/4)转发组播流到RP,组播源到RP路径之间没有(,G/32)表项,DF在(,224.0.0.0/4)里作为incoming入接口用于接收组播流量,然后由upstream接口转发给RP
5, 组播接收者与RP之间,DF转发join message 到RP,产生(,G/32)表项,DF在(,G/32)作为outgoing接口转发接口将流量转发到接收端
6,总结一句话:(,224.0.0.0/4)给组播源用的,(*,G/32)是给接收端用的
CCIE DC Multicast Part 3.的更多相关文章
- 组播(Multicast)传输
组播(Multicast)传输: 在发送者和每一接收者之间实现点对多点网络连接. 如果一台发送者同时给多个的接收者传输相同的数据,也只需复制一份的相同数据包.它提高了数据传送效率.减少了骨干网络出现拥 ...
- 深入解析DC/OS 1.8 – 高可靠的微服务及大数据管理平台
深入解析DC/OS 1.8 – 高可靠的微服务及大数据管理平台 大家好,欢迎大家参加这次DC/OS的技术分享. 先做个自我介绍,刘超,Linker Networks首席架构师,Open DC/OS社区 ...
- 思科CCIE全新升级,SDN/SD-WAN成重头戏!
CCIE,全称Cisco Certified Internetwork Expert,是美国Cisco公司于1993年开始推出的专家级认证考试.被全球公认为IT业最权威的认证,是全球Internetw ...
- 怎么搭建DC+SCCM 域环境(一)
需要的软件: 1. SCCM 2012 SP1 2. SQL Server 2012 3. System ISO 4. ADK 环境搭建顺序: 1. 安装DC和SCCM 机器,并配置需要的IP.DNS ...
- LDAP 中 CN, OU, DC 的含义
1. LDAP的存储规则 区分名(DN,Distinguished Name) 和自然界中的树不同,文件系统/LDAP/电话号码簿目录的每一片枝叶都至少有一个独一无二的属性,这一属性可以帮助我们来区别 ...
- FMS 4中multicast脚本的小修正
FMS 4中multicast脚本的小修正 http://help.adobe.com/en_US/flashmediaserver/devguide/WS7812b00092aae0dc-2829d ...
- [专业名词·硬件] 2、DC\DC、LDO电源稳压基本常识(包含基本原理、高效率模块设计、常见问题、基于nRF51822电源管理模块分析等)·长文
综述先看这里 第一节的1.1简单介绍了DC/DC是什么: 第二节是关于DC/DC的常见的疑问答疑,非常实用: 第三节是针对nRF51822这款芯片电源管理部分的DC/DC.LDO.1.8的详细分析,对 ...
- 802.11 对于multicast 和 broadcast的处理
ethernet内部会有broadcast 和 multicast.这两种包都是一个STA向多个STA发包. 当没有wifi存在的时候,LAN口之间的broadcast 和 multicast是可靠转 ...
- AD域服务器|两台DC无法进行复制同步
注:本文由Colin撰写,版权所有!转载请注明原文地址,谢谢合作! 说明:前段时间公司两台域控出现了一些问题导致数据无法相互进行同步,DC之间也无法进行共享访问,网络用户无法通过计算机名映射的共享访问 ...
- DC/DC与LDO的差别
转自:http://bbs.eetop.cn/thread-459121-1-1.html 在平时的学习中,我们都有接触LDO和DC/DC这一类的电源产品,但作为学生的我们队这些东西可能了解不够深刻, ...
随机推荐
- vue学习笔记(一)---- vue指令(在vue中使用样式的方式)
认真学习,认真记录,每天都要有进步呀!!! 加油叭!!! 一.在vue中使用样式的方式: 1. 直接传递一个数组,注意: 这里的 class 需要使用 v-bind 做数据绑定 <style&g ...
- 《Terraform 101 从入门到实践》 Functions函数
<Terraform 101 从入门到实践>这本小册在南瓜慢说官方网站和GitHub两个地方同步更新,书中的示例代码也是放在GitHub上,方便大家参考查看. Terraform的函数 T ...
- 重学SpringBoot. step5 再学SpringMVC
SpringMVC 参考:<深入浅出 SpringBoot 2.X> 虽然说的是SpringBoot,但把SpringMVC将的很好,正是SpringMVC应用到SpringBoot中非常 ...
- 嵌入式Linux—Framebuffer应用编程
Framebuffer 应用编程 Frame的意思是帧,buffer的意思是缓冲区.Framebuffer就是一块内存(硬件设备),里面保存着一帧图像. ioctl()函数解析 ioctl()函数非常 ...
- LeetCode_单周赛_327
目录 6283. 正整数和负整数的最大计数 代码 6285. 执行 K 次操作后的最大分数 代码 6284. 使字符串总不同字符的数目相等 代码 6283. 正整数和负整数的最大计数 代码 直接遍历统 ...
- Nginx08 通过扩容提升整体吞吐量 nginx平滑升级-添加sticky模块和使用
1 扩容方式介绍 一个单一站点,想要扩,可以从硬件软件等多个方面来进行. 1 单机垂直扩容:硬件资源增加 2 水平扩展:集群化 3 细粒度拆分:分布式 3-1 数据分区 3-2 上游服务SOA化(原生 ...
- python导入和导出excel,以文件流形式返回前端
一.导入excel 1. 安装依赖包 pip install xlrd 2. 读取excel getColIndex(colList:list,colName:str): try: return co ...
- PostgresSQL 常用操作方法
1.后台生成XML作为参数然后数据库解析获取数据 var idList = ids.Split(new string[] { "," }, StringSplitOptions.R ...
- el-table 在第一行添加合计行和操作按钮
1.预计效果如下 2.前端及样式部分 1)el-table <el-table size="small" stripe style="width: 100%&quo ...
- python3中,len()、isalpha()、isspace()、isdigit()、isalnum()实例
# 实例:使用while循环 import string s1 = input('请输入一个字符串:\n') letters = 0 space = 0 digit = 0 others = 0 i ...