静态路由配置
![](https://img.haomeiwen.com/i10392259/bd57a494ba676f49.png)
R1配置
[R1]interface Ethernet 0/0/0
[R1-Ethernet0/0/0] ip address 192.168.0.254 255.255.255.0
[R1-Ethernet0/0/0] q
[R1] interface Ethernet 0/0/1
[R1-Ethernet0/0/1] ip address 192.168.1.1 255.255.255.0
[R1-Ethernet0/0/1] q
[R1] ip route-static 192.168.2.0 255.255.255.0 192.168.1.2
R2配置
[R2] interface Ethernet 0/0/0
[R2-Ethernet0/0/0] ip address 192.168.2.200 255.255.255.0
[R2-Ethernet0/0/0] q
[R2] interface Ethernet 0/0/1
[R2-Ethernet0/0/1] ip address 192.168.0.2 255.255.255.0
[R2-Ethernet0/0/1] q
[R2] ip route-static 192.168.0.0 255.255.255.0 192.168.1.1
测试
![](https://img.haomeiwen.com/i10392259/93a1381acbc45134.png)
![](https://img.haomeiwen.com/i10392259/b45d3fc97feb2eb8.png)
![](https://img.haomeiwen.com/i10392259/f49c69ec6e90cf40.png)
网友评论