云计算
需求描述
1.需要在三台路由器上配置静态路由,以实现各网段之间的互通
2.若要实现全网互通,必须明确如下两个问题数据包被路由器转发或丢弃,取决于是否能够在路由表中找到数据包的目标地址所对应的条目路由器可以自动生成所有直连网段的路由条目,对于那些非直连网段就需要通过静态路由指定了
3.因此,要想实现全网互通,就必须为每台路由器指定所有非直连网段的路由条目
实验环境
三台路由器r1、r2、 r3两两互连,每台路由器上都配置了loopback地址模拟网络环境
第一步:配置r1路由器
<huawei>system-v //从用户视图进入系统视图[huawei]sysname r1 //设置路由器名称[r1]int g0/0/0 //进入端口[r1-gigabitethernet0/0/0]ip add 12.0.0.1 24[r1-gigabitethernet0/0/0]q //从系统视图返回到用户视图[r1]int g0/0/1[r1-gigabitethernet0/0/1]ip add 13.0.0.1 24[r1-gigabitethernet0/0/1]q[r1]int loo 0 //进入回环网卡接口[r1-loopback0]ip add 1.1.1.1 32[r1-loopback0]q[r1]dis ip int b //查看接口状态interface ip address/mask physical protocolgigabitethernet0/0/0 12.0.0.1/24 up up gigabitethernet0/0/1 13.0.0.1/24 up up loopback0 1.1.1.1/32 up up(s)[r1]ip route-static 3.3.3.3 32 13.0.0.3[r1]ip route-static 3.3.3.3 32 12.0.0.2[r1]ip route-static 2.2.2.2 32 13.0.0.3[r1]ip route-static 2.2.2.2 32 12.0.0.2//配置路由静态路由[r1]display ip routing-table //查看路由表route flags: r - relay, d - download to fib------------------------------------------------------------------------------routing tables: public destinations : 9 routes : 11 destination/mask proto pre cost flags nexthop interface 1.1.1.1/32 direct 0 0 d 127.0.0.1 loopback0 2.2.2.2/32 static 60 0 rd 13.0.0.3 gigabitethernet0/0/1 static 60 0 rd 12.0.0.2 gigabitethernet0/0/0 3.3.3.3/32 static 60 0 rd 13.0.0.3 gigabitethernet0/0/1 static 60 0 rd 12.0.0.2 gigabitethernet0/0/0 12.0.0.0/24 direct 0 0 d 12.0.0.1 gigabitethernet0/0/0 12.0.0.1/32 direct 0 0 d 127.0.0.1 gigabitethernet0/0/0 13.0.0.0/24 direct 0 0 d 13.0.0.1 gigabitethernet0/0/1 13.0.0.1/32 direct 0 0 d 127.0.0.1 gigabitethernet0/0/1 127.0.0.0/8 direct 0 0 d 127.0.0.1 inloopback0 127.0.0.1/32 direct 0 0 d 127.0.0.1 inloopback0第二步:配置r2路由器
<huawei>system-v[huawei]sysname r2[r2]int g0/0/0[r2-gigabitethernet0/0/0]ip add 12.0.0.2 24[r2-gigabitethernet0/0/0]q[r2]int g0/0/2[r2-gigabitethernet0/0/2]ip add 23.0.0.2 24[r2-gigabitethernet0/0/2]q[r2]int loo 0[r2-loopback0]ip add 2.2.2.2 32[r2-loopback0]q[r2]ip route-static 1.1.1.1 32 12.0.0.1[r2]ip route-static 1.1.1.1 32 23.0.0.3[r2]ip route-static 3.3.3.3 32 12.0.0.1[r2]ip route-static 3.3.3.3 32 23.0.0.3[r2]dis ip int b interface ip address/mask physical protocolgigabitethernet0/0/0 12.0.0.2/24 up upgigabitethernet0/0/2 23.0.0.2/24 up up loopback0 2.2.2.2/32 up up(s) [r2]display ip routing-tableroute flags: r - relay, d - download to fib------------------------------------------------------------------------------routing tables: public destinations : 9 routes : 11 destination/mask proto pre cost flags nexthop interface 1.1.1.1/32 static 60 0 rd 12.0.0.1 gigabitethernet0/0/0 static 60 0 rd 23.0.0.3 gigabitethernet0/0/2 2.2.2.2/32 direct 0 0 d 127.0.0.1 loopback0 3.3.3.3/32 static 60 0 rd 12.0.0.1 gigabitethernet0/0/0 static 60 0 rd 23.0.0.3 gigabitethernet0/0/2 12.0.0.0/24 direct 0 0 d 12.0.0.2 gigabitethernet0/0/0 12.0.0.2/32 direct 0 0
行业动态与宠物网站建设独立站岂止于外贸,国内官方私域引流之七脉神剑在中国买cc的域名还要备案吗电脑360文件恢复工具怎么用?教你用360文件恢复工具关于想建立一个视频分享网站如何进行网站备案前置审批文件没有可4g的云服务器一个月多少钱全球43亿个IPv4地址用完了,幸好中国早有准备!网站建设通常有哪些步骤?网站建设步骤及推广方法