课堂笔记

2021.11.8 H3C 动态路由协议RIP

相关解释:https://zhuanlan.zhihu.com/p/166598494

RIP路由协议简单点意思就是指让路由自动选择下一条路由而不需要配置静态路由,但是需要划分子网

实验拓扑图
[H3C]sys R1
[R1]int g0/0
[R1-GigabitEthernet0/0]ip add 192.168.1.1 24
[R1-GigabitEthernet0/0]qu
[R1]int g0/1
[R1-GigabitEthernet0/1]ip add 192.168.2.1 24
[R1-GigabitEthernet0/1]qu


[R1]rip
[R1-rip-1]network 192.168.1.0
[R1-rip-1]network 192.168.2.0
[R1-rip-1]display ip routing-table protocol rip

Summary count : 2

RIP Routing table status : <Active>
Summary count : 0

RIP Routing table status : <Inactive>
Summary count : 2

Destination/Mask   Proto   Pre Cost        NextHop         Interface
192.168.1.0/24     RIP     100 0           0.0.0.0         GE0/0
192.168.2.0/24     RIP     100 0           0.0.0.0         GE0/1

[R1]save force
Validating file. Please wait...
Configuration is saved to device successfully.

[H3C]sys R2
[R1]int g0/0
[R1-GigabitEthernet0/0]ip add 192.168.2.2 24
[R1-GigabitEthernet0/0]qu
[R1]int g0/1
[R1-GigabitEthernet0/1]ip add 192.168.3.1 24
[R1-GigabitEthernet0/1]qu
[R2]rip
[R2-rip-1]network 192.168.2.0
[R2-rip-1]network 192.168.3.0
[R2-rip-1]display ip routing-table protocol rip

Summary count : 3

RIP Routing table status : <Active>
Summary count : 1

Destination/Mask   Proto   Pre Cost        NextHop         Interface
192.168.1.0/24     RIP     100 1           192.168.2.1     GE0/0

RIP Routing table status : <Inactive>
Summary count : 2

Destination/Mask   Proto   Pre Cost        NextHop         Interface
192.168.2.0/24     RIP     100 0           0.0.0.0         GE0/0
192.168.3.0/24     RIP     100 0           0.0.0.0         GE0/1
[R1]save force
Validating file. Please wait...
Configuration is saved to device successfully.
[H3C]sys R3
[R3]int g0/0
[R3-GigabitEthernet0/0]ip add 192.168.3.2 24
[R3-GigabitEthernet0/0]qu
[R3]int g0/1
[R3-GigabitEthernet0/1]ip add 192.168.4.1 24
[R3]rip
[R3-rip-1]network 192.168.3.0
[R3-rip-1]network 192.168.4.0
[R3-rip-1]display ip routing-table protocol rip

Summary count : 4

RIP Routing table status : <Active>
Summary count : 2

Destination/Mask   Proto   Pre Cost        NextHop         Interface
192.168.1.0/24     RIP     100 2           192.168.3.1     GE0/0
192.168.2.0/24     RIP     100 1           192.168.3.1     GE0/0

RIP Routing table status : <Inactive>
Summary count : 2

Destination/Mask   Proto   Pre Cost        NextHop         Interface
192.168.3.0/24     RIP     100 0           0.0.0.0         GE0/0
192.168.4.0/24     RIP     100 0           0.0.0.0         GE0/1

[R3-GigabitEthernet0/1]save f
Validating file. Please wait...
Configuration is saved to device successfully.
[H3C]sys SW1
[SW1]vlan 10
[SW1-vlan10]vlan 20
[SW1-vlan20]qu
[SW1]
int vlan 10
[SW1-Vlan-interface10]ip add 192.168.4.2 24
[SW1-Vlan-interface10]qu
[SW1]int vlan 20
[SW1-Vlan-interface20]ip add 192.168.5.1 24
[SW1-Vlan-interface20]qu
[SW1]int g 1/0/1

[SW1-GigabitEthernet1/0/1]port link-type access
[SW1-GigabitEthernet1/0/1]port access vlan 10
[SW1-GigabitEthernet1/0/1]quit
[SW1-GigabitEthernet1/0/1]qu
[SW1]int g 1/0/2

[SW1-GigabitEthernet1/0/2]port link-type access
[SW1-GigabitEthernet1/0/2]port access vlan 20
[SW1-GigabitEthernet1/0/2]qu

[SW1]rip
[SW1-rip-1]network 192.168.4.0
[SW1-rip-1]network 192.168.5.0
[SW1-rip-1]display ip routing-table protocol rip

Summary count : 5

RIP Routing table status : <Active>
Summary count : 3

Destination/Mask   Proto   Pre Cost        NextHop         Interface
192.168.1.0/24     RIP     100 3           192.168.4.1     Vlan10
192.168.2.0/24     RIP     100 2           192.168.4.1     Vlan10
192.168.3.0/24     RIP     100 1           192.168.4.1     Vlan10

RIP Routing table status : <Inactive>
Summary count : 2

Destination/Mask   Proto   Pre Cost        NextHop         Interface
192.168.4.0/24     RIP     100 0           0.0.0.0         Vlan10
192.168.5.0/24     RIP     100 0           0.0.0.0         Vlan20

PC1和PC2相互ping

PC1
PC2
R1上路由追踪PC2
开启路由追踪
ip unreachables enable
ip ttl-expires enable
真动态路由简易拓扑图
路由动态追踪1
怡夏
我爱她,仅此而已
查看“怡夏”的所有文章 →

发表评论

您的电子邮箱地址不会被公开。 必填项已用*标注

相关推荐