ensp路由重分发(路由导入)(实验报告)

ensp路由重分发(路由导入)(实验报告)_第1张图片

假设一个企业总公司在北京,下辖两个分公司,一个在广东,另一个在广西。广东分公司使用 RIPv2 动态路由协议,而广西分公司使用静态路由协议。所有分公司访问公网都需要通过总公司路由器实现,并且对于所有的路由器互联网络都有OSPF协议设定运行。公司希望优化网络流量以增强分公司间互联和其访问公网时的性能,网络管理员可以通过路由重分发来解决这个问题。 

 R1路由器的配置命令

sysname R1
 
interface GigabitEthernet0/0/0
 ip address 10.0.0.1 255.255.255.252
 
interface GigabitEthernet0/0/1
 ip address 10.0.0.5 255.255.255.252
 
interface GigabitEthernet0/0/2
 ip address 172.16.31.1 255.255.255.252
 
ospf 1 router-id 1.1.1.1
 default-route-advertise always
 area 0.0.0.0
  network 10.0.0.1 0.0.0.0
 area 0.0.0.1
  network 10.0.0.5 0.0.0.0
 
ip route-static 0.0.0.0 0.0.0.0 172.16.31.2

sysname R1
 
interface GigabitEthernet0/0/0
 ip address 10.0.0.1 255.255.255.252
 
interface GigabitEthernet0/0/1
 ip address 10.0.0.5 255.255.255.252
 
interface GigabitEthernet0/0/2
 ip address 172.16.31.1 255.255.255.252
 
ospf 1 router-id 1.1.1.1
 default-route-advertise always
 area 0.0.0.0
  network 10.0.0.1 0.0.0.0
 area 0.0.0.1
  network 10.0.0.5 0.0.0.0
 
ip route-static 0.0.0.0 0.0.0.0 172.16.31.2

 R2路由器的配置命令 

sysname R2
interface GigabitEthernet0/0/0
 ip address 10.0.0.2 255.255.255.252
#
interface GigabitEthernet0/0/1
 ip address 192.168.100.1 255.255.255.0
#
ospf 1 router-id 2.2.2.2
 import-route rip 1
 area 0.0.0.0
  network 10.0.0.2 0.0.0.0
#
rip 1
 undo summary
 default-route originate
 version 2
 network 192.168.100.0
 import-route ospf 1

sysname R2
interface GigabitEthernet0/0/0
 ip address 10.0.0.2 255.255.255.252
#
interface GigabitEthernet0/0/1
 ip address 192.168.100.1 255.255.255.0
#
ospf 1 router-id 2.2.2.2
 import-route rip 1
 area 0.0.0.0
  network 10.0.0.2 0.0.0.0
#
rip 1
 undo summary
 default-route originate
 version 2
 network 192.168.100.0
 import-route ospf 1

 R3路由器的配置命令 

sysname R3
interface GigabitEthernet0/0/0
 ip address 10.0.0.9 255.255.255.252
#
interface GigabitEthernet0/0/1
 ip address 10.0.0.6 255.255.255.252
#
interface GigabitEthernet0/0/2
#
interface GigabitEthernet0/0/3
 ip address 192.168.3.10 255.255.255.0
 
ospf 1 router-id 3.3.3.3
 import-route direct
 area 0.0.0.1
  network 10.0.0.6 0.0.0.0

sysname R3
interface GigabitEthernet0/0/0
 ip address 10.0.0.9 255.255.255.252
#
interface GigabitEthernet0/0/1
 ip address 10.0.0.6 255.255.255.252
#
interface GigabitEthernet0/0/2
#
interface GigabitEthernet0/0/3
 ip address 192.168.3.10 255.255.255.0
 
ospf 1 router-id 3.3.3.3
 import-route direct
 area 0.0.0.1
  network 10.0.0.6 0.0.0.0

 R4路由器的配置命令 

sysname R4
 
interface GigabitEthernet0/0/0
 ip address 10.0.0.10 255.255.255.252
 
ip route-static 0.0.0.0 0.0.0.0 10.0.0.9

sysname R4
 
interface GigabitEthernet0/0/0
 ip address 10.0.0.10 255.255.255.252
 
ip route-static 0.0.0.0 0.0.0.0 10.0.0.9

 R5路由器的配置命令 

sysname R5
 
interface GigabitEthernet0/0/0
 ip address 192.168.100.2 255.255.255.0
#
interface GigabitEthernet0/0/1
 ip address 192.168.2.10 255.255.255.0
 
rip 1
 undo summary
 version 2
 network 192.168.100.0
 network 192.168.2.0

sysname R5
 
interface GigabitEthernet0/0/0
 ip address 192.168.100.2 255.255.255.0
#
interface GigabitEthernet0/0/1
 ip address 192.168.2.10 255.255.255.0
 
rip 1
 undo summary
 version 2
 network 192.168.100.0
 network 192.168.2.0

ISP路由器的配置命令

sysname ISP
 
interface GigabitEthernet0/0/0
 ip address 172.16.31.2 255.255.255.252
#
interface GigabitEthernet0/0/1
 ip address 192.168.50.10 255.255.255.0
 
ip route-static 0.0.0.0 0.0.0.0 172.16.31.1

sysname ISP
 
interface GigabitEthernet0/0/0
 ip address 172.16.31.2 255.255.255.252
#
interface GigabitEthernet0/0/1
 ip address 192.168.50.10 255.255.255.0
 
ip route-static 0.0.0.0 0.0.0.0 172.16.31.1

PC1 的配置

 ensp路由重分发(路由导入)(实验报告)_第2张图片

PC2的配置 

ensp路由重分发(路由导入)(实验报告)_第3张图片

PC3的配置

 ensp路由重分发(路由导入)(实验报告)_第4张图片

PC4的配置

ensp路由重分发(路由导入)(实验报告)_第5张图片

PC6的配置

ensp路由重分发(路由导入)(实验报告)_第6张图片

PC7的配置

ensp路由重分发(路由导入)(实验报告)_第7张图片

验证是否互通

PC1pingPC2

ensp路由重分发(路由导入)(实验报告)_第8张图片

 PC1pingPC3

ensp路由重分发(路由导入)(实验报告)_第9张图片

PC1pingPC6

ensp路由重分发(路由导入)(实验报告)_第10张图片

实验报告

实验背景:

本次实验的目的是探究网络路由器在不同协议下的工作原理以及如何进行静态路由和动态路由的配置。

实验内容:

1、建立网络拓扑

使用packet tracer软件利用交换机和路由器来模拟企业办公区内,包含总公司和两个分公司,其中广东分公司使用 RIPv2 动态路由协议,而广西分公司使用静态路由协议。总公司的路由器通过OSPF协议与各分公司的路由器相连,建立互联网性,如图所示。

2、配置路由器

(1)静态路由

为了使广西分公司内部的网络能够访问到广东分公司,需要在广西分公司的路由器R4上配置静态路由。

输入命令:sy → system-view
进入默认路由,将所有流量转发给 连接到ISP的GE0/0/0网口 IP地址为172.16.31.2的路由器。ip route-static 0.0.0.0 0.0.0.0 172.16.31.2

(2)动态路由

为广东分公司的R2配置RIPv2协议,使其与邻居路由器交换路由信息后能够更新自身路由表:

进入路由器的命令行界面:sy → system-view
设置RIPv2路由类型: rip 1
启用相应网段:该路由器与局域网相连的接口:network 10.0.0.0
向邻居路由器交换路由信息:version 2,网络号192.168.100.0
保存并退出配置:q → sa
3、测试网络连接

在各个分公司内部测试互联以及访问公网能力,确认网络是否正常运行。

实验心得:

通过本次实验,我们进一步学习了网络路由器的工作原理和相关的路由协议。对于不同的场景和需求,可以选择不同的路由协议进行合适的配置,如静态路由和动态路由等。

在实践中,我们需要结合具体场景的实际情况进行安排,并充分发挥网络管理员的技巧和专业知识。通过系统的实验操作,我们可以更好地理解路由器在网络中起着重要作用,并明确了如何在实际环境中适应和解决问题。

总之,本次实验是有益的,可以让我们掌握网络路由器的工作原理、掌握如何配置路由器的方法以及对网络拓扑结构和设计原则有更深入的了解。

配置文本

dis cu
#
sysname R3
#
aaa
 authentication-scheme default
 authorization-scheme default
 accounting-scheme default
 domain default
 domain default_admin
 local-user admin password cipher vKw%T{>b<2ECB7Ie7'/)c13#
 local-user admin service-type http
#
firewall zone Local
 priority 16
#
interface Ethernet0/0/0
#
interface Ethernet0/0/1
#
interface Serial0/0/0
 link-protocol ppp
#
interface Serial0/0/1
 link-protocol ppp
#
interface Serial0/0/2
 link-protocol ppp
#
interface Serial0/0/3
 link-protocol ppp
#
interface GigabitEthernet0/0/0
 ip address 10.0.0.9 255.255.255.252
#
interface GigabitEthernet0/0/1
 ip address 10.0.0.6 255.255.255.252
#
interface GigabitEthernet0/0/2
#
interface GigabitEthernet0/0/3
 ip address 192.168.3.10 255.255.255.0
#
wlan
#
interface NULL0
#
ospf 1 router-id 3.3.3.3
 import-route direct
 area 0.0.0.1
  network 10.0.0.6 0.0.0.0
#
user-interface con 0
user-interface vty 0 4
user-interface vty 16 20
#
return
di cu
#
sysname R4
#
aaa
 authentication-scheme default
 authorization-scheme default
 accounting-scheme default
 domain default
 domain default_admin
 local-user admin password cipher /Yo"1Qm*Q-jKUGU-KkpBq1/#
 local-user admin service-type http
#
firewall zone Local
 priority 16
#
interface Ethernet0/0/0
#
interface Ethernet0/0/1
#
interface Serial0/0/0
 link-protocol ppp
#
interface Serial0/0/1
 link-protocol ppp
#
interface Serial0/0/2
 link-protocol ppp
#
interface Serial0/0/3
 link-protocol ppp
#
interface GigabitEthernet0/0/0
 ip address 10.0.0.10 255.255.255.252
#
interface GigabitEthernet0/0/1
 ip address 192.168.3.10 255.255.255.0
#
interface GigabitEthernet0/0/2
#
interface GigabitEthernet0/0/3
#
wlan
#
interface NULL0
#
ip route-static 0.0.0.0 0.0.0.0 10.0.0.9
#
user-interface con 0
user-interface vty 0 4
user-interface vty 16 20
#
return
 
di cu
#
sysname R5
#
aaa
 authentication-scheme default
 authorization-scheme default
 accounting-scheme default
 domain default
 domain default_admin
 local-user admin password cipher kJ,nVGHBd4+/Y@:Y>Lw(316#
 local-user admin service-type http
#
firewall zone Local
 priority 16
#
interface Ethernet0/0/0
#
interface Ethernet0/0/1
#
interface Serial0/0/0
 link-protocol ppp
#
interface Serial0/0/1
 link-protocol ppp
#
interface Serial0/0/2
 link-protocol ppp
#
interface Serial0/0/3
 link-protocol ppp
#
interface GigabitEthernet0/0/0
 ip address 192.168.100.2 255.255.255.0
#
interface GigabitEthernet0/0/1
 ip address 192.168.2.10 255.255.255.0
#
interface GigabitEthernet0/0/2
#
interface GigabitEthernet0/0/3
#
wlan
#
interface NULL0
#
rip 1
 undo summary
 version 2
 network 192.168.100.0
 network 192.168.2.0
#
user-interface con 0
user-interface vty 0 4
user-interface vty 16 20
#
return

 

di cu
#
sysname ISP
#
aaa
 authentication-scheme default
 authorization-scheme default
 accounting-scheme default
 domain default
 domain default_admin
 local-user admin password cipher \<)jWzs+*:+/Y@:Y>Lw(&16#
 local-user admin service-type http
#
firewall zone Local
 priority 16
#
interface Ethernet0/0/0
#
interface Ethernet0/0/1
#
interface Serial0/0/0
 link-protocol ppp
#
interface Serial0/0/1
 link-protocol ppp
#
interface Serial0/0/2
 link-protocol ppp
#
interface Serial0/0/3
 link-protocol ppp
#
interface GigabitEthernet0/0/0
 ip address 172.16.31.2 255.255.255.252
#
interface GigabitEthernet0/0/1
 ip address 192.168.50.10 255.255.255.0
#
interface GigabitEthernet0/0/2
#
interface GigabitEthernet0/0/3
#
wlan
#
interface NULL0
#
ip route-static 0.0.0.0 0.0.0.0 172.16.31.1
#
user-interface con 0
user-interface vty 0 4
user-interface vty 16 20
#
return
di cu
#
sysname R1
#
aaa
 authentication-scheme default
 authorization-scheme default
 accounting-scheme default
 domain default
 domain default_admin
 local-user admin password cipher Lb~h
di cu
#
sysname R2
#
aaa
 authentication-scheme default
 authorization-scheme default
 accounting-scheme default
 domain default
 domain default_admin
 local-user admin password cipher (Gj"HpD|\GjKUGU-KkpB(1/#
 local-user admin service-type http
#
firewall zone Local
 priority 16
#
interface Ethernet0/0/0
#
interface Ethernet0/0/1
#
interface Serial0/0/0
 link-protocol ppp
#
interface Serial0/0/1
 link-protocol ppp
#
interface Serial0/0/2
 link-protocol ppp
#
interface Serial0/0/3
 link-protocol ppp
#
interface GigabitEthernet0/0/0
 ip address 10.0.0.2 255.255.255.252
#
interface GigabitEthernet0/0/1
 ip address 192.168.100.1 255.255.255.0
#
interface GigabitEthernet0/0/2
#
interface GigabitEthernet0/0/3
#
wlan
#
interface NULL0
#
ospf 1 router-id 2.2.2.2
 import-route rip 1
 area 0.0.0.0
  network 10.0.0.2 0.0.0.0
#
rip 1
 undo summary
 default-route originate
 version 2
 network 192.168.100.0
 import-route ospf 1
#
user-interface con 0
user-interface vty 0 4
user-interface vty 16 20
#
return

你可能感兴趣的:(网络,智能路由器)