HCIA-不同vlan间通信的两种方式

实验拓扑:

5887009d9ff0f14d4081eab5d861dce

实验配置:

终结子接口方式:

R1:

int g0/0/1.2

dot1q termination vid 2

arp broadcast enable

ip address 192.168.2.254 24

int g0/0/1.3

dot1q termination vid 3

arp broadcast en

ip address 192.168.3.254 24

R2:

int g0/0/1

ip address 192.168.2.1 24

q

ip route-static 0.0.0.0 0 192.168.2.254

R3:

int g0/0/1

ip address 192.168.3.1 24

q

ip route-static 0.0.0.0 0 192.168.3.254

S1:

v b 2 3

int g0/0/1

port link-type trunk

port trunk allow-pass vlan 2 3

interface g0/0/2

port default vlan 2

int g0/0/3

port link-type access

port default vlan 3

q

vlanif接口方式:

S1:

int g0/0/1

undo port trunk allow-pass vlan 2 3

undo port link-type

R1:

undo int g0/0/1.2

undo int g0/0/1.3

int Vlanif 2

ip address 192.168.2.254 24

int vlanif 3

ip address 192.168.3.254 24

实验结果:

ed66428646da4f7025235b6c0a0dd43

posted @ 2025-08-03 21:03  快乐小狗小杰  阅读(15)  评论(0)    收藏  举报