[G0/0/1连接路由];缺点:单点故障和带宽的影响
(配置子接口dot1q封装的单层VLAN ID:dotlq termination vid)
(允许子接口ARP广播功能:arp broadcast enable)
[SWA]vlan batch 10 20
[SWA-GigabitEthernet0/0/2]port link-type access
[SWA-GigabitEthernet0/0/2]port default vlan 10
[SWA-GigabitEthernet0/0/3]port link-type access
[SWA-GigabitEthernet0/0/3]port default vlan 20
[SWA-GigabitEthernet0/0/1]port link-type trunk
[SWA-GigabitEthernet0/0/1]port trunk allow-pass vlan 10 20
[RTA]interface GigabitEthernet0/0/1.1(是路由的接口,和交换机接口保持一致)
[RTA-GigabitEthernet0/0/1.1]dotlq termination vid 10
[RTA-GigabitEthernet0/0/1.1]ip address 192.168.10.254 24
[RTA-GigabitEthernet0/0/1.1]arp broadcast enable
[RTA]interface GigabitEthernet0/0/1.2
[RTA-GigabitEthernet0/0/1.2]dotlq termination vid 20
[RTA-GigabitEthernet0/0/1.2]ip address 192.168.20.254 24
[RTA-GigabitEthernet0/0/1.2]arp broadcast enable