Presentation is loading. Please wait.

Presentation is loading. Please wait.

网络互连及设备 第六章.

Similar presentations


Presentation on theme: "网络互连及设备 第六章."— Presentation transcript:

1 网络互连及设备 第六章

2 主要内容 互连设备 网络路由

3 1、互连设备 中继器(repeater) 网桥(bridge) 交换机 路由器(router) 网关(gateway)

4 网络互连概述 网络互连需求 网络连接设备 扩大资源共享范围 实现分布式网络计算(多方合作设计) 部署大范围的应用(文档管理,email通信)
网络内部连接-网络设备 网际连接-互联设备 LAN-LAN LAN-WAN

5 网络互连概述 网络互连的原则 对原有网络的硬件和软件或者网络结构和协议不应作太大的修改。
执行网络互连的部件应当具有协调子网不同特性的能力。例如:编址方案、分组大小、访问机制和协议转换等。 不应为提高网络之间传输的性能而影响各个子网内部的传输功能和性能。

6 网络互连概述 网络互连因素考虑

7 连接设备

8 网络设备V.S OSI层次模型

9 中继器-Repeater(Hub)(1) 目的:延伸网段。 过程:信号(含噪声)的接收和整形。 形式:电缆延伸、光电转换等。
特点:通过转发器互连的设备处于同一广播域。

10 中继器-Repeater(2) 信号复制

11 中继器(3) 信号整形(增强)

12 Hub(4) 光纤 双绞线 细缆 粗缆 集线器 转发器 堆叠式集线器

13 网桥-Bridge(1) 目的:实现子网内冲突域的划分 不同子网之间的互连
功能:网络层以下协议转换,帧格式转 换,速率匹配,地址过滤,差错处 理,存储转发 特点:工作于数据链路层,可以连接不 同的网络

14 网桥-Bridge(2) 网桥 网段1 网段2 OSI高层 N DL1 Ph1 DL2 Ph2

15 网桥-Bridge(3) MAC帧头 数据 校验码 MAC帧头转换 新MAC帧头 新校验码 Ethernet FDDI

16 网桥-Bridge(4) 分类 简单网桥:地址表全部由人工输入。
透明网桥(transparent bridge)或生成树网桥(spanning tree bridge) 全自动工作模式,对终端完全透明 源路由网桥(source routing) 对终端不透明,由终端进行路由的发现

17 透明网桥(5) 地址学习-逆向学习法(backward learning) 地址广播 地址学习 地址查找 地址表更新

18 透明网桥-地址表(6)

19 透明网桥-地址学习(7) 对吗? MAC地址 端口 地址映射表: 00123456 网段1 50873EA6 网段4 1017385A
网段2 网段3 网段4 A 501C3dD56 50173E56 508C3dD5B 50873EA6 , 50873EA6 对吗? MAC地址 端口 地址映射表: 网段1 50873EA6 网段4 A 网段2 ……

20 透明网桥-环路处理(8) 网桥环路的产生 管理出错 多个网桥增加冗余链路,增加可靠性 B1表 B2表 1 2 B1 A B 1 2 B2
MAC PORT A 1 2 B MAC PORT A 1 2 B 1 2 B1 A B 1 2 B2

21 透明网桥-环路处理(9) 环路的特点 引起站点之间有多条通路 造成地址映射表冲突 可能引起分组循环 环路的处理 LAN网络抽象——〉图的处理
生成树(spanning tree)算法,所产生的生成树是覆盖所有节点的无环子图。

22 透明网桥-环路处理(10) 生成树(spanning tree)算法的特点 生成树(spanning tree)算法的目的 分布式
动态(出于不断构建之中,新加入或故障) 生成树(spanning tree)算法的目的 消除环路 任意两个互联的子网(网段)之间路径唯一

23 透明网桥-环路处理(11) 生成树算法原理(本次课作业) 网桥具有网桥标识和端口(网段)编号;端口可设置“转发”、“阻塞” 状态。
选择一网桥作为树根,①根网桥(指定或最小地址的桥)周期性(1-4s)发出Hello广播报文; ②所有网桥记录并转发该报文; ③多个桥向同一网段转发该报文时,小地址桥的端口置为“转发”状态,其它桥的相应端口可置为“阻塞(不转发)”; ④保证每个网段都(仅)有一个桥(端口)负责转发; ⑤当同一桥的多个端口冲突时,阻塞编号较高的端口。⑥最终形成一个面向根节点(根网桥)的转发非循环树。

24 透明网桥-环路处理(12) 2 3 1 4 5 6 A B C D E F G

25 透明网桥-环路处理(12) 1 4 5 6 A B C D E F G 2 3 2 3 1 4 5 6 A B C D E F G

26 源路由网桥(13) 假定每个帧的发送者都知道接收者是否在同一LAN上,当发送一帧到另外的LAN时,源机器将目的地址的高位设置成1作为标记。
在帧头加进此帧应走的实际路径。 网桥根据标注的路径进行转发。 源路由的查找 查找帧(discovery frame)

27 交换机(1) 交换机是特殊的网桥 交换机连接同构的网段(子网) 独享带宽 划分冲突域

28 交换机(2) 100M交换器 10M交换器 100M 10M Hub 网段 子网

29 交换机-VLAN(3) 目的:将不同物理网段上的节点划分为逻辑工作组 特点:方便节点的移动、增加和删除 划分方法 按照交换机端口进行划分
按照主机MAC地址进行划分 按照主机IP地址进行划分

30 交换机-VLAN(4) 有何不同? (port) (MAC) (IP)

31 zw2-1>show vlan VLAN Name Status Ports 1 default active 100 ggq active Gi1/0/1, Gi1/0/2, Gi1/0/3 Gi1/0/4, Gi1/0/5, Gi1/0/6 Gi1/0/7, Gi1/0/8, Gi1/0/26 200 wgx active Gi1/0/11, Gi1/0/12, Gi1/0/13 Gi1/0/14, Gi1/0/15, Gi1/0/16 300 ljz active Gi1/0/17, Gi1/0/18, Gi1/0/19 Gi1/0/20, Gi1/0/21, Gi1/0/22 Gi1/0/23, Gi1/0/24, Gi1/0/27 Gi1/0/28 540 VLAN active Gi1/0/9, Gi1/0/10 1002 fddi-default act/unsup 1003 token-ring-default act/unsup 1004 fddinet-default act/unsup 1005 trnet-default act/unsup VLAN Type SAID MTU Parent RingNo BridgeNo Stp BrdgMode Trans1 Trans2

32 交换机-VLAN(6) VLAN之间的通信由路由器或者具有三层交换功能的交换机完成。
三层交换机功能:是指具有路由功能的交换机,互联同构子网或网段,不需进行协议转换,是一种简化的路由器。 三层交换机的特点:保持两层交换机的灵活性,同时通过硬件完成路由和交换功能,支持高速处理。

33 路由器(Router)(1) 功能 网络内子网之间的互连 同构(异构)网络之间的互连形成广域网
运行路由算法/协议(RIP, OSPF, BGP) 在输入链路到输出链路之间交换数据包 工作于网络层 访问控制 网络管理

34 路由器(Router)(2) 路由器 子网1 子网2 OSI高层 N1 DL1 Ph1 DL2 Ph2 N2

35 路由器(Router)(3) 体系结构 网络拥塞

36 路由器(Router)(4) 路由处理 Route table Route lookup Routing protocol Routing
Network information Routing Algorithms Route table Route lookup

37 路由器(Router)(5) 交换模块

38 路由器(Router)(6) 输入端口 物理层: bit-级接受 数据链路层: 如:以太网 通过目的地址从路由表中查找输出接口
如果数据报到达速率>转发速率,则需要排队

39 路由器(Router)(7) 输出端口 如果从交换结构到达速率大于卡的发送速率,则需要排队

40 路由器(Router)(8) 路由协议 静态路由 动态路由 RIP-距离向量协议 OSPF-链路状态协议 BGP-边界网关路由协议

41 网关-Gateway 功能 高层协议的转换 SMTP TCP IP LLC MAC S T N DL Ph A-MHS P 网关

42 2. 网 络 路 由 技 术 网络互连应用

43 2. 网 络 路 由 技 术 通信子网构成形式

44 网 络 路 由 技 术 路由 问题解决 路由器 交换机

45 网 络 路 由 技 术 路由行为-how Route routing ?
寻径: 即判定到达目的地的最佳路径,由路由协议和选择算法来实现,本过程产生路由表。 转发(forward): 即沿寻径好的最佳路径传送信息分组。路由器首先在路由表中查找,判明是否知道如何将分组发送到下一个站点(路由器或主机)。 Route routing ? Windows下的命令 Route netstat

46 网 络 路 由 技 术 路由转发表的形式 Destination MASK Next-hop flag Interface
UH lo0 UG le0 UHG

47 网 络 路 由 技 术 主机终端路由实例 Active Routes:
Destination Netmask Gateway Interface Metric Default Gateway:

48 网 络 路 由 技 术 路由表(routing table) 静态路由 静态路由是在路由器中设置的固定的路由表。
由于静态路由不能对网络的改变作出反映,一般用于网络规模不大、拓扑结构固定的网络中。 静态路由的优点是简单、高效、可靠。

49 网 络 路 由 技 术 路由表(routing table) 动态路由 动态路由是路由器之间动态地传递路由信息,不断更新路由表的过程。
它能实时地适应网络结构的变化,通过路由算法,更新各自的路由表以动态地反映网络拓扑变化。 动态路由适用于网络规模大、网络拓扑复杂的网络。当然,各种动态路由协议会不同程度地占用网络带宽和CPU资源。

50 网 络 路 由 技 术 静态路由与动态路由优先级 在所有的路由中,静态路由优先级最高,当动态路由与静态路由发生冲突时,以静态路由为准。
网络中动态路由通常作为静态路由的补充,当分组被路由时,路由器首先查找静态路由,如果查到则根据相应的静态路由转发分组;否则再查找动态路由。

51 网 络 路 由 技 术 动态路由产生 (D_routing ) Routing protocol routing algorithm
Other routers Routing protocol 动态路由产生 (D_routing ) Routing protocol Network info. routing algorithm Use network info. Create routes. Routing Protocol Network information Routing Algorithms Route table Route lookup

52 Different routing mechanisms
数据报工作模式 虚电路工作模式 1 2 3 USER11 USER12 USER13 USER21 USER22 USER23 Router Physical link

53 Route Table Direct Route Redirect Route Specific Host Route
Specific Network Route Default Route

54 Route Table Destination NetMask Nexthop Flag IF Ct 127.0.0.0 255.0.0.0
UH lo0 UG le0 UHG

55 CIDR 无类域间路由 prifix Gateway Flag IF \15 UH lo0

56 Routing Algorithms Routing algorithms Shortest Path Routing

57 Routing Algorithms Distance Vector Routing (Bellman-Ford)

58

59

60 Routing Protocol IGP RIP OSPF EGP BGP

61 Routing Protocol

62 Routing Protocol RIP(Route information protocol)
Rfc2453(ripv2)(for small & middle network<16hops) Algorithm:distance vector algorithm Procedure: Every 30 seconds, the RIP process is awakened to send an unsolicited Response message containing the complete routing table to every neighboring router. Compare the resulting update distances with the current routing table entries.

63 If the new resulting distance is smaller than the existing value, adopt the new route.
If the updater is the router from which the existing route came, i.e., then use the new metric even if it is larger than the old one.

64 Routing Protocol RIP-----Count-to-infinity Example:
交换次数 R1路由表 R4路由表 R 2路由表 R3路由表 初始 Net0 - 1 16 第1次 R1 2 11 第2次 R4 3 Here, 16means infinity

65 在180s之内,R4没有收到邻居R1关于Net0的消息,则
交换次数 R1路由表 R4路由表 R 2路由表 R3路由表 初始 Net0 - 1 16 R4 3 第1次 R2 4 第2次 第3次 5 12 R1 11 在180s之内,R4没有收到邻居R1关于Net0的消息,则 认为链路中断,距离置为16

66 "split horizon with poisoned reverse"
Problem: two routers have routes pointing at each other . The two solutions as following: "split horizon with poisoned reverse" "Split horizon" is a scheme for avoiding problems caused by including routes in updates sent to the router from which they were learned. “Split horizon with poisoned reverse“ includes such routes in updates, but sets their metrics to infinity(i.e route=infinity in undates).

67 "triggered updates" “Split horizon with poisoned reverse” will prevent any routing loops that involve only two routers. However, it is still possible to end up with patterns in which three routers are engaged in mutual deception. To get triggered updates, we simply add a rule that whenever a router changes the metric for a route, it is required to send update messages almost immediately, even if it is not yet time for one of the regular update message.

68 Routing Protocol OSPF(open shortest path first)(rfc2328)
OSPF is classified as an Interior Gateway Protocol (IGP). This means that it distributes routing information between routers belonging to a single Autonomous System. The OSPF protocol is based on link-state or SPF technology. Based on shortest path algorithm to compute the required route . Every entity(router) has the complete route information data base isolated from other areas.

69 Routing Protocol OSPF(open shortest path first)(rfc2328)

70 Routing Protocol EGP BGP 自治系统间的协议 距离向量路由协议和链路状态路由协议不适合
支持管理策略的路径向量协议,关注的是可达性 采用TCP可靠协议进行分组的交换 RIP采用UDP,度量采用跳数Hops,端口:520 OSPF直接封装在IP里,度量为带宽

71 Routing Protocol BGP

72


Download ppt "网络互连及设备 第六章."

Similar presentations


Ads by Google