0
点赞
收藏
分享

微信扫一扫

单臂路由

author:leadlife

data:2022/8/29

概念:只使用一个物理接口,承载两个 vlan 之间的信息,链路为干道链路,trunk

单臂路由,只可以使用在 百兆以上的 物理以太网接口

0x01 子接口

int f0/0.10  对应 vlan10
int f0/0.20 对应 vlan20

0xEnd 配置命令

1:进入物理接口,并开启 no shutdown
2:通过链路为 干道 trunk 链路,所以配置 dot1Q 封装并加上 vlan ID
3:配置网关,同时开启子接口 no shutdown

详细配置如下:


GW(config)#int f0/0
GW(config-if)#no shutdown

GW(config)#int f0/0.10
GW(config-subif)#encapsulation dot1Q 10
GW(config-subif)#ip address 192.168.1.254 255.255.255.0
GW(config-subif)#no shutdown
GW(config-subif)#exit

GW(config)#int f0/0.20
GW(config-subif)#encapsulation dot1Q 20
GW(config-subif)#ip address 192.168.2.254 255.255.255.0
GW(config-subif)#no shutdown
GW(config-subif)#exit



GW(config)#end

GW#show ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

C 192.168.1.0/24 is directly connected, FastEthernet0/0.10
C 192.168.2.0/24 is directly connected, FastEthernet0/0.20

GW#show ip int b
Interface IP-Address OK? Method Status Protocol
FastEthernet0/0 unassigned YES unset up up
FastEthernet0/0.10 192.168.1.254 YES manual up up
FastEthernet0/0.20 192.168.2.254 YES manual up

0xEnd 单臂路由缺点

我们分析单臂路由的流量

1:流量从 PC 机处,先去找网关

2:流量从 三层GW 返回,寻找 vlan 20

可以看到,流量数据是转了一个圈回来的,占用带宽过多,使得链路负载过大

举报

相关推荐

0 条评论