
本试验主要实验静态路由的三个主要特性
1、单向性
仅为数据提供沿着下一跳的方向进行路由,不提供反向路由。如果要使源节点域目标网络进行双向通信,必须同时配置回程静态路由
2、接力性
如果某条静态路由中间经过的跳数大于1(路由要经过3个或以上路由节点),则必须在除最后一个路由器外的其他路由器上依次配置到达相同目的节点或目的网络的静态路由。(路由器各端口上直连的各个网络都是直连互通的,因此之间默认是直连路由,因而无需另外配置路由。)
3、迭代性
理论上来说,静态路由的下一跳可以是路径中其他路由器中的任意一个接口,只要能保证路由到达下一跳就行了。
具体配置:
<r6>dis cu
[V200R003C00]
#
sysname r6
#
interface GigabitEthernet0/0/1
ip address 10.1.3.254 255.255.255.0
#
ip route-static 10.1.1.0 255.255.255.0 10.1.2.254
ip route-static 10.1.2.0 255.255.255.0 10.1.3.1
ip route-static 172.16.1.0 255.255.255.0 10.1.3.1
ip route-static 172.16.2.0 255.255.255.0 10.1.3.1
ip route-static 192.168.0.0 255.255.0.0 10.1.2.254 #此处聚合性静态路由 以及迭代性示例
#
return
<r6>
------------------
<r4>dis cu
[V200R003C00]
#
sysname r4
#
interface GigabitEthernet0/0/0
ip address 172.16.1.254 255.255.255.0
#
interface GigabitEthernet0/0/1
ip address 10.1.3.1 255.255.255.0
#
interface GigabitEthernet0/0/2
ip address 10.1.2.254 255.255.255.0
#
ip route-static 10.1.1.0 255.255.255.0 10.1.2.1
ip route-static 172.16.2.0 255.255.255.0 172.16.1.1
ip route-static 172.16.10.0 255.255.255.0 172.16.1.1
ip route-static 192.168.0.0 255.
#
return
<r4>
------------------
<s1>dis cu
#
sysname s1
#
vlan batch 2 10 100
#
interface Vlanif2
ip address 172.16.2.254 255.255.255.0
#
interface Vlanif10
ip address 172.16.10.254 255.255.255.0
#
interface Vlanif100
ip address 172.16.1.1 255.255.255.0
#
interface GigabitEthernet0/0/2
port link-type access
port default vlan 2
#
interface GigabitEthernet0/0/23
port link-type access
port default vlan 10
#
interface GigabitEthernet0/0/24
port link-type trunk
port trunk pvid vlan 100
port trunk allow-pass vlan 2 to 4094
#
ip route-static 0.0.0.0 0.0.0.0 172.16.1.254
ip route-static 10.1.2.0 255.255.255.0 172.16.1.254
ip route-static 10.1.3.0 255.255.255.0 172.16.1.254
#
return
<s1>
--------------------------
<r5>dis cu
[V200R003C00]
#
sysname r5
#
interface GigabitEthernet0/0/1
ip address 10.1.1.254 255.255.255.0
#
interface GigabitEthernet0/0/2
ip address 10.1.2.1 255.255.255.0
#
ip route-static 10.1.3.0 255.255.255.0 10.1.2.254
ip route-static 172.16.0.0 255.255.0.0 10.1.2.254
ip route-static 192.168.0.0 255.255.0.0 10.1.1.1
#
return
<r5>
------------------
<r3>dis cu
[V200R003C00]
#
sysname r3
#
interface GigabitEthernet0/0/0
ip address 192.168.1.254 255.255.255.0
#
interface GigabitEthernet0/0/1
ip address 10.1.1.1 255.255.255.0
#
ip route-static 10.1.2.0 255.255.255.0 10.1.1.254
ip route-static 10.1.3.0 255.255.255.0 10.1.1.254
ip route-static 172.16.2.0 255.255.255.0 10.1.1.254
ip route-static 172.16.10.0 255.255.255.0 10.1.1.254
ip route-static 192.168.2.0 255.255.255.0 192.168.1.1
#
return
<r3>
--------------------
<s3>dis cu
#
sysname s3
#
vlan batch 20 100
#
interface Vlanif20
ip address 192.168.2.254 255.255.255.0
#
interface Vlanif100
ip address 192.168.1.1 255.255.255.0
#
interface GigabitEthernet0/0/24
port link-type trunk
port trunk pvid vlan 100
port trunk allow-pass vlan 2 to 4094
#
ip route-static 0.0.0.0 0.0.0.0 192.168.1.254
ip route-static 10.1.1.0 255.255.255.0 192.168.1.254
ip route-static 172.16.0.0 255.255.0.0 10.1.1.1
#
<s3>



本文地址:http://www.023wg.com/lypz/16.html
版权声明:若无注明,本文皆为“Swiers思唯网络博客”原创,转载请保留文章出处。

