三、配置静态路由


所属类别:网络技术

文章作者:hongguang

特别推荐:免费发布信息 承包关键词~~抢爆了!HOT!


三、配置静态路由 方 法 一:使用直连的下一路由的接口地址 实验拓扑:1、ip地址表: R1 S2/0 192.168.10.1/24 R2 S2/0 192.168.10.2/24 R2 S3/0 192.168.20.1/24R3 S2/0 192.168.20.2/242、R1的配置:Router>enRouter#conf tEnter configuration commands, one per line. End with CNTL/Z.Router(config)#hostname R1R1(config)#interface serial 2/0//进入S2/0R1(config-if)#ip address 192.168.10.1 255.255.255.0//接口配置ipR1(config-if)#no shutdown//激活接口%LINK-5-CHANGED: Interface Serial2/0, changed state to downR1(config-if)#exitR1(config)#ip route 192.168.20.0 255.255.255.0 192.168.10.2//访问20网段的路由指向R2 S2/0R1(config)#exit%SYS-5-CONFIG_I: Configured from console by consoleR1#writDestination filename [startup-config]?Building configuration...[OK]R1#R2的配置:Router>enRouter#conf tEnter configuration commands, one per line. End with CNTL/Z.Router(config)#hostname R2R2(config)#interface serial 2/0R2(config-if)#ip address 192.168.10.2 255.255.255.0R2(config-if)#no shutdown//激活接口,此时本口与对端口处于up状态%LINK-5-CHANGED: Interface Serial2/0, changed state to upR2(config-if)#clock rate 64000//设置时钟频率为64000R2(config-if)#%LINEPROTO-5-UPDOWN: Line protocol on Interface Serial2/0, changed state to upR2(config-if)#exitR2(config)#interface serial 3/0R2(config-if)#ip address 192.168.20.1 255.255.255.0R2(config-if)#no shutdown%LINK-5-CHANGED: Interface Serial3/0, changed state to downR2(config-if)#clock rate 64000R2(config-if)#exitR2(config)#exit%SYS-5-CONFIG_I: Configured from console by consoleR2#writeDestination filename [startup-config]?Building configuration...[OK]R2# R3的配置:Router>enRouter#conf tEnter configuration commands, one per line. End with CNTL/Z.Router(config)#hostname R3R3(config)#interface serial 2/0R3(config-if)#ip address 192.168.20.2 255.255.255.0R3(config-if)#no shutdown%LINK-5-CHANGED: Interface Serial2/0, changed state to upR3(config-if)#%LINEPROTO-5-UPDOWN: Line protocol on Interface Serial2/0, changed state to upR3(config-if)#exitR3(config)#exit%SYS-5-CONFIG_I: Configured from console by consoleR3#writeDestination filename [startup-config]?Building configuration...[OK]R3#验证配置:R1#ping 192.168.10.1Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.10.1, timeout is 2 seconds:!!!!!Success rate is 100 percent (5/5), round-trip min/avg/max = 68/79/104 msR1#ping 192.168.10.2Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.10.2, timeout is 2 seconds:!!!!!Success rate is 100 percent (5/5), round-trip min/avg/max = 34/39/45 msR1#ping 192.168.20.1Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.20.1, timeout is 2 seconds:!!!!!Success rate is 100 percent (5/5), round-trip min/avg/max = 34/37/42 msR1#ping 192.168.20.2Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.20.2, timeout is 2 seconds:.....Success rate is 0 percent (0/5)R1#//R1 ping 192.168.20.2 不通,原因是R3上没有设置去192.168.1.0/24网段的路由R3的配置:R3(config)#ip route 192.168.10.0 255.255.255.0 192.168.20.1验证配置:R1#ping 192.168.20.2Type escape sequence to abort.Sending 5, 100-byte ICMP Echos to 192.168.20.2, timeout is 2 seconds:!!!!!Success rate is 100 percent (5/5), round-trip min/avg/max = 69/77/88 msR1#不知道写没写清楚,希望大家多提出意见和建议,小弟不胜感激!!!!!本文出自 51CTO.COM技术博客

相关信息

· 首款新概念国产办公软件“空中”面市

· faq2

· 安全:漏洞的形成和防治办法

· AOL Browser网页浏览器抢先预览








....

14423 96137